Uploaded image for project: 'NetBeans'
  1. NetBeans
  2. NETBEANS-4568

extend inline hints to reader support, use case fluent api ussage such as streams

    XMLWordPrintableJSON

    Details

    • Type: New Feature
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Labels:
      None

      Description

      When you build up a stream with several mapping operations
      it would be nice to see what the intermediate types are, not only when completing,
      but also when reading the code.
      It will be very helpful when exploring an API any when studying th concept.

      example (the addition shown as trailing comment.)
      {{
      return Files.lines( filePath ) // Stream<String>
      .filter( this.lineFilter ) // Stream<String> coan be ommited becasue no type change
      .map( s -> s.split( this.splitString ) ) // Stream<String[]>
      .filter( rowFilter ) // omitted, stream type same
      .map( creator ) // Stream<T>
      ;
      }}

      Other use cases are frameworks with fluent APIs such as AssertJ to name one.
      After having some experience with it, it will be a tremendous boon for code review.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              homberghp Pieter van den Hombergh
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: