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

Use enhanced-for cycle instead of Enumeration in java.security.jgss

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P5 P5
    • 20
    • None
    • security-libs

      java.util.Enumeration is a legacy interface from java 1.0.
      There are a few places with cycles which use it to iterate over collections. We can replace this manual cycle with enchanced-for, which is shorter and easier to read.

      sun.security.jgss.ProviderList#addAllMechsFromProvider
      sun.security.jgss.GSSCredentialImpl#dispose
      sun.security.jgss.GSSCredentialImpl#getRemainingLifetime
      sun.security.jgss.GSSCredentialImpl#getUsage()
      sun.security.jgss.GSSCredentialImpl#getElements

            aturbanov Andrey Turbanov
            aturbanov Andrey Turbanov
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: