Class DrmTodayResponseCode

java.lang.Object
com.castlabs.android.drm.DrmTodayResponseCode

public class DrmTodayResponseCode extends Object
DRMToday response code holder and parser. This class handles the parsing and representation of DRMToday service response codes, which are used to indicate the status or error conditions of DRM operations.
  • Field Details

    • responseCode

      public final int responseCode
      The numeric response code from the DRMToday service. This field contains the parsed integer value of the response code.
    • responseCodeString

      @Nullable public final String responseCodeString
      The original string representation of the response code. This field contains the raw response code as received from the service.
  • Method Details

    • create

      @Nullable public static DrmTodayResponseCode create(@Nullable Map<String,List<String>> responseHeaders)
      Parses response headers and creates corresponding DrmTodayResponseCode. This method extracts the DRMToday response code from HTTP response headers and creates a new instance with the parsed code.
      Parameters:
      responseHeaders - HTTP response headers to be parsed for the error code
      Returns:
      DrmTodayResponseCode or null if the response code is not available