Uploaded image for project: 'HttpComponents HttpCore'
  1. HttpComponents HttpCore
  2. HTTPCORE-620

Refactor int constants from org.apache.hc.core5.reactor.IOSession into an enum

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 5.0-beta11
    • HttpCore
    • None

    Description

      Refactor int constants fromĀ org.apache.hc.core5.reactor.IOSession into an enum called state:

      • int org.apache.hc.core5.reactor.IOSession.ACTIVE
      • int org.apache.hc.core5.reactor.IOSession.CLOSED
      • int org.apache.hc.core5.reactor.IOSession.CLOSING

      Like:

      public interface IOSession extends ByteChannel, SocketModalCloseable, Identifiable {
      
          public enum Status {
      
              ACTIVE(0),
              CLOSING(1),
              CLOSED(Integer.MAX_VALUE);
      
              private Status(final int rank) {
                  this.rank = rank;
              }
      
              public final int rank;
      
          }
      ...
      

      https://github.com/apache/httpcomponents-core/pull/180

      Attachments

        Issue Links

          Activity

            People

              ggregory Gary D. Gregory
              ggregory Gary D. Gregory
              Votes:
              0 Vote for this issue
              Watchers:
              4 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 - 50m
                  50m