Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-1252157

InputStream class has methods which dont maintain consistency of return types.

    Details

    • Subcomponent:
    • CPU:
      sparc
    • OS:
      solaris_2.4

      Description

      The methods in InputStream for example available() and skip() return different
      types of values. Why? These should be consistent. Both should either return int
      or long. It doesnt make sense calling available() on a huge file on which we might
      want to skip a large number of bytes using a long type.

      This problem of inconsistent types returned by methods in the same class is prevalent
      across all of the classes in java.io.

      Vijay

        Attachments

          Activity

            People

            • Assignee:
              mr Mark Reinhold
              Reporter:
              vssriniv Vijay Srinivasan (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Imported:
                Indexed: