Boxed primitive classes need static factories.

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Duplicate
    • Priority: P3
    • None
    • Affects Version/s: 5.0
    • Component/s: specification
    • None
    • generic
    • solaris_8

      From ###@###.###:
      > Boolean has valueOf(boolean), which is a very good thing. But Integer
      > needs valueOf(int), which should at least cache a few well-known values. In
      > retrospect, it's a bug that any of the primitive wrapper classes have public
      > constructors.

      All of the boxed primitive classes should have a static constructor valueOf().
      This will simplify the boxing spec and implementation.

            Assignee:
            Alex Buckley
            Reporter:
            Neal Gafter (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: