test_class.declarator: KNOWN_CUSTOM_LABEL = AcknowledgementLabel.of("success-ack")
test_class.modifier: private static final
test_class.original_string: private static final AcknowledgementLabel KNOWN_CUSTOM_LABEL = AcknowledgementLabel.of("success-ack");
test_class.type: AcknowledgementLabel
test_class.var_name: KNOWN_CUSTOM_LABEL
test_class.declarator: KNOWN_STATUS = HttpStatusCode.CREATED
test_class.modifier: private static final
test_class.original_string: private static final HttpStatusCode KNOWN_STATUS = HttpStatusCode.CREATED;
test_class.type: HttpStatusCode
test_class.var_name: KNOWN_STATUS
test_class.declarator: KNOWN_HEADERS = DittoHeaders.newBuilder()
              .correlationId("foobar")
              .build()
test_class.modifier: private static final
test_class.original_string: private static final DittoHeaders KNOWN_HEADERS = DittoHeaders.newBuilder()
              .correlationId("foobar")
              .build();
test_class.type: DittoHeaders
test_class.var_name: KNOWN_HEADERS
test_class.declarator: KNOWN_PAYLOAD = JsonObject.newBuilder()
              .set("foo", 42)
              .build()
test_class.modifier: private static final
test_class.original_string: private static final JsonValue KNOWN_PAYLOAD = JsonObject.newBuilder()
              .set("foo", 42)
              .build();
test_class.type: JsonValue
test_class.var_name: KNOWN_PAYLOAD
test_class.declarator: KNOWN_ACK_SUCCESS =
              ThingAcknowledgementFactory.newAcknowledgement(KNOWN_CUSTOM_LABEL,
                      TestConstants.THING_ID,
                      KNOWN_STATUS,
                      KNOWN_HEADERS,
                      KNOWN_PAYLOAD)
test_class.modifier: private static final
test_class.original_string: private static final Acknowledgement KNOWN_ACK_SUCCESS =
              ThingAcknowledgementFactory.newAcknowledgement(KNOWN_CUSTOM_LABEL,
                      TestConstants.THING_ID,
                      KNOWN_STATUS,
                      KNOWN_HEADERS,
                      KNOWN_PAYLOAD);
test_class.type: Acknowledgement
test_class.var_name: KNOWN_ACK_SUCCESS
test_class.declarator: KNOWN_CUSTOM_LABEL_2 = AcknowledgementLabel.of("error-ack")
test_class.modifier: private static final
test_class.original_string: private static final AcknowledgementLabel KNOWN_CUSTOM_LABEL_2 = AcknowledgementLabel.of("error-ack");
test_class.type: AcknowledgementLabel
test_class.var_name: KNOWN_CUSTOM_LABEL_2
test_class.declarator: KNOWN_STATUS_2 = HttpStatusCode.CONFLICT
test_class.modifier: private static final
test_class.original_string: private static final HttpStatusCode KNOWN_STATUS_2 = HttpStatusCode.CONFLICT;
test_class.type: HttpStatusCode
test_class.var_name: KNOWN_STATUS_2
test_class.declarator: KNOWN_HEADERS_2 = DittoHeaders.newBuilder()
              .correlationId("foobar")
              .build()
test_class.modifier: private static final
test_class.original_string: private static final DittoHeaders KNOWN_HEADERS_2 = DittoHeaders.newBuilder()
              .correlationId("foobar")
              .build();
test_class.type: DittoHeaders
test_class.var_name: KNOWN_HEADERS_2
test_class.declarator: KNOWN_PAYLOAD_2 = null
test_class.modifier: private static final
test_class.original_string: private static final JsonValue KNOWN_PAYLOAD_2 = null;
test_class.type: JsonValue
test_class.var_name: KNOWN_PAYLOAD_2
test_class.declarator: KNOWN_ACK_2_ERROR =
              ThingAcknowledgementFactory.newAcknowledgement(KNOWN_CUSTOM_LABEL_2,
                      TestConstants.THING_ID,
                      KNOWN_STATUS_2,
                      KNOWN_HEADERS_2,
                      KNOWN_PAYLOAD_2)
test_class.modifier: private static final
test_class.original_string: private static final Acknowledgement KNOWN_ACK_2_ERROR =
              ThingAcknowledgementFactory.newAcknowledgement(KNOWN_CUSTOM_LABEL_2,
                      TestConstants.THING_ID,
                      KNOWN_STATUS_2,
                      KNOWN_HEADERS_2,
                      KNOWN_PAYLOAD_2);
test_class.type: Acknowledgement
test_class.var_name: KNOWN_ACK_2_ERROR
test_class.declarator: KNOWN_CUSTOM_LABEL_3 = AcknowledgementLabel.of("second-success-ack")
test_class.modifier: private static final
test_class.original_string: private static final AcknowledgementLabel KNOWN_CUSTOM_LABEL_3 = AcknowledgementLabel.of("second-success-ack");
test_class.type: AcknowledgementLabel
test_class.var_name: KNOWN_CUSTOM_LABEL_3
test_class.declarator: KNOWN_STATUS_3 = HttpStatusCode.NO_CONTENT
test_class.modifier: private static final
test_class.original_string: private static final HttpStatusCode KNOWN_STATUS_3 = HttpStatusCode.NO_CONTENT;
test_class.type: HttpStatusCode
test_class.var_name: KNOWN_STATUS_3
test_class.declarator: KNOWN_HEADERS_3 = DittoHeaders.newBuilder()
              .correlationId("foobar")
              .build()
test_class.modifier: private static final
test_class.original_string: private static final DittoHeaders KNOWN_HEADERS_3 = DittoHeaders.newBuilder()
              .correlationId("foobar")
              .build();
test_class.type: DittoHeaders
test_class.var_name: KNOWN_HEADERS_3
test_class.declarator: KNOWN_PAYLOAD_3 = JsonValue.of("Hello world!")
test_class.modifier: private static final
test_class.original_string: private static final JsonValue KNOWN_PAYLOAD_3 = JsonValue.of("Hello world!");
test_class.type: JsonValue
test_class.var_name: KNOWN_PAYLOAD_3
test_class.declarator: KNOWN_ACK_3_SUCCESS = ThingAcknowledgementFactory.newAcknowledgement(
              KNOWN_CUSTOM_LABEL_3,
              TestConstants.THING_ID,
              KNOWN_STATUS_3,
              KNOWN_HEADERS_3,
              KNOWN_PAYLOAD_3)
test_class.modifier: private static final
test_class.original_string: private static final Acknowledgement KNOWN_ACK_3_SUCCESS = ThingAcknowledgementFactory.newAcknowledgement(
              KNOWN_CUSTOM_LABEL_3,
              TestConstants.THING_ID,
              KNOWN_STATUS_3,
              KNOWN_HEADERS_3,
              KNOWN_PAYLOAD_3);
test_class.type: Acknowledgement
test_class.var_name: KNOWN_ACK_3_SUCCESS
test_class.declarator: topicPathMyCustomAck
test_class.modifier: private static
test_class.original_string: private static TopicPath topicPathMyCustomAck;
test_class.type: TopicPath
test_class.var_name: topicPathMyCustomAck
test_class.declarator: underTest
test_class.modifier: private
test_class.original_string: private AcknowledgementsAdapter underTest;
test_class.type: AcknowledgementsAdapter
test_class.var_name: underTest
test_class.file: protocol-adapter/src/test/java/org/eclipse/ditto/protocoladapter/acknowledgements/AcknowledgementsAdapterTest.java
test_class.identifier: AcknowledgementsAdapterTest
test_class.interfaces: implements ProtocolAdapterTest
test_case.body: @Test
      public void acknowledgementsContaining2bothSuccessFromAdaptable() {
  
          final Adaptable adaptable = Adaptable.newBuilder(topicPathMyCustomAck)
                  .withHeaders(KNOWN_HEADERS)
                  .withPayload(Payload.newBuilder(JsonPointer.empty())
                          .withValue(JsonObject.newBuilder()
                                  .set(KNOWN_CUSTOM_LABEL, JsonObject.newBuilder()
                                          .set("status", KNOWN_STATUS.toInt())
                                          .set("payload", KNOWN_PAYLOAD)
                                          .set("headers", KNOWN_HEADERS.toJson())
                                          .build())
                                  .set(KNOWN_CUSTOM_LABEL_3, JsonObject.newBuilder()
                                          .set("status", KNOWN_STATUS_3.toInt())
                                          .set("payload", KNOWN_PAYLOAD_3)
                                          .set("headers", KNOWN_HEADERS_3.toJson())
                                          .build())
                                  .build()
                          )
                          .withStatus(HttpStatusCode.OK)
                          .build())
                  .build();
  
          final Acknowledgements expected = ThingAcknowledgementsFactory.newAcknowledgements(
                  Arrays.asList(KNOWN_ACK_SUCCESS, KNOWN_ACK_3_SUCCESS), KNOWN_HEADERS);
  
          final Acknowledgements actual = underTest.fromAdaptable(adaptable);
  
          assertWithExternalHeadersThat(actual).isEqualTo(expected);
      }
test_case.class_method_signature: AcknowledgementsAdapterTest.acknowledgementsContaining2bothSuccessFromAdaptable()
test_case.full_signature: @Test public void acknowledgementsContaining2bothSuccessFromAdaptable()
test_case.identifier: acknowledgementsContaining2bothSuccessFromAdaptable
test_case.invocations: build withPayload withHeaders newBuilder build withStatus withValue newBuilder empty build set set newBuilder build set set set newBuilder toInt toJson build set set set newBuilder toInt toJson newAcknowledgements asList fromAdaptable isEqualTo assertWithExternalHeadersThat
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void acknowledgementsContaining2bothSuccessFromAdaptable()
focal_class.declarator: headerTranslator
focal_class.modifier: private final
focal_class.original_string: private final HeaderTranslator headerTranslator;
focal_class.type: HeaderTranslator
focal_class.var_name: headerTranslator
focal_class.file: protocol-adapter/src/main/java/org/eclipse/ditto/protocoladapter/acknowledgements/AcknowledgementsAdapter.java
focal_class.identifier: AcknowledgementsAdapter
focal_class.interfaces: implements Adapter<Acknowledgements>
focal_class.class_method_signature: AcknowledgementsAdapter.AcknowledgementsAdapter(final HeaderTranslator headerTranslator)
focal_class.full_signature: private  AcknowledgementsAdapter(final HeaderTranslator headerTranslator)
focal_class.identifier: AcknowledgementsAdapter
focal_class.modifiers: private
focal_class.parameters: (final HeaderTranslator headerTranslator)
focal_class.signature:  AcknowledgementsAdapter(final HeaderTranslator headerTranslator)
focal_class.class_method_signature: AcknowledgementsAdapter.getInstance(final HeaderTranslator headerTranslator)
focal_class.full_signature: static AcknowledgementsAdapter getInstance(final HeaderTranslator headerTranslator)
focal_class.identifier: getInstance
focal_class.modifiers: static
focal_class.parameters: (final HeaderTranslator headerTranslator)
focal_class.return: AcknowledgementsAdapter
focal_class.signature: AcknowledgementsAdapter getInstance(final HeaderTranslator headerTranslator)
focal_class.class_method_signature: AcknowledgementsAdapter.fromAdaptable(final Adaptable adaptable)
focal_class.full_signature: @Override public Acknowledgements fromAdaptable(final Adaptable adaptable)
focal_class.identifier: fromAdaptable
focal_class.modifiers: @Override public
focal_class.parameters: (final Adaptable adaptable)
focal_class.return: Acknowledgements
focal_class.signature: Acknowledgements fromAdaptable(final Adaptable adaptable)
focal_class.class_method_signature: AcknowledgementsAdapter.getThingId(final Adaptable adaptable)
focal_class.full_signature: private static ThingId getThingId(final Adaptable adaptable)
focal_class.identifier: getThingId
focal_class.modifiers: private static
focal_class.parameters: (final Adaptable adaptable)
focal_class.return: ThingId
focal_class.signature: ThingId getThingId(final Adaptable adaptable)
focal_class.class_method_signature: AcknowledgementsAdapter.gatherContainedAcknowledgements(final Adaptable adaptable,
              final ThingId thingId)
focal_class.full_signature: private static List<Acknowledgement> gatherContainedAcknowledgements(final Adaptable adaptable,
              final ThingId thingId)
focal_class.identifier: gatherContainedAcknowledgements
focal_class.modifiers: private static
focal_class.parameters: (final Adaptable adaptable,
              final ThingId thingId)
focal_class.return: List<Acknowledgement>
focal_class.signature: List<Acknowledgement> gatherContainedAcknowledgements(final Adaptable adaptable,
              final ThingId thingId)
focal_class.class_method_signature: AcknowledgementsAdapter.buildAcknowledgements(final ThingId thingId, final JsonValue value)
focal_class.full_signature: private static List<Acknowledgement> buildAcknowledgements(final ThingId thingId, final JsonValue value)
focal_class.identifier: buildAcknowledgements
focal_class.modifiers: private static
focal_class.parameters: (final ThingId thingId, final JsonValue value)
focal_class.return: List<Acknowledgement>
focal_class.signature: List<Acknowledgement> buildAcknowledgements(final ThingId thingId, final JsonValue value)
focal_class.class_method_signature: AcknowledgementsAdapter.getStatusCodeOrThrow(final Adaptable adaptable)
focal_class.full_signature: private static HttpStatusCode getStatusCodeOrThrow(final Adaptable adaptable)
focal_class.identifier: getStatusCodeOrThrow
focal_class.modifiers: private static
focal_class.parameters: (final Adaptable adaptable)
focal_class.return: HttpStatusCode
focal_class.signature: HttpStatusCode getStatusCodeOrThrow(final Adaptable adaptable)
focal_class.class_method_signature: AcknowledgementsAdapter.toAdaptable(final Acknowledgements acknowledgements, final TopicPath.Channel channel)
focal_class.full_signature: @Override public Adaptable toAdaptable(final Acknowledgements acknowledgements, final TopicPath.Channel channel)
focal_class.identifier: toAdaptable
focal_class.modifiers: @Override public
focal_class.parameters: (final Acknowledgements acknowledgements, final TopicPath.Channel channel)
focal_class.return: Adaptable
focal_class.signature: Adaptable toAdaptable(final Acknowledgements acknowledgements, final TopicPath.Channel channel)
focal_class.class_method_signature: AcknowledgementsAdapter.getGroups()
focal_class.full_signature: @Override public Set<TopicPath.Group> getGroups()
focal_class.identifier: getGroups
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: Set<TopicPath.Group>
focal_class.signature: Set<TopicPath.Group> getGroups()
focal_class.class_method_signature: AcknowledgementsAdapter.getChannels()
focal_class.full_signature: @Override public Set<TopicPath.Channel> getChannels()
focal_class.identifier: getChannels
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: Set<TopicPath.Channel>
focal_class.signature: Set<TopicPath.Channel> getChannels()
focal_class.class_method_signature: AcknowledgementsAdapter.getCriteria()
focal_class.full_signature: @Override public Set<TopicPath.Criterion> getCriteria()
focal_class.identifier: getCriteria
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: Set<TopicPath.Criterion>
focal_class.signature: Set<TopicPath.Criterion> getCriteria()
focal_class.class_method_signature: AcknowledgementsAdapter.getActions()
focal_class.full_signature: @Override public Set<TopicPath.Action> getActions()
focal_class.identifier: getActions
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: Set<TopicPath.Action>
focal_class.signature: Set<TopicPath.Action> getActions()
focal_class.class_method_signature: AcknowledgementsAdapter.isForResponses()
focal_class.full_signature: @Override public boolean isForResponses()
focal_class.identifier: isForResponses
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: boolean
focal_class.signature: boolean isForResponses()
focal_class.class_method_signature: AcknowledgementsAdapter.requiresSubject()
focal_class.full_signature: @Override public boolean requiresSubject()
focal_class.identifier: requiresSubject
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: boolean
focal_class.signature: boolean requiresSubject()
focal_class.class_method_signature: AcknowledgementsAdapter.getTopicPath(final Acknowledgements acknowledgement, final TopicPath.Channel channel)
focal_class.full_signature: private static TopicPath getTopicPath(final Acknowledgements acknowledgement, final TopicPath.Channel channel)
focal_class.identifier: getTopicPath
focal_class.modifiers: private static
focal_class.parameters: (final Acknowledgements acknowledgement, final TopicPath.Channel channel)
focal_class.return: TopicPath
focal_class.signature: TopicPath getTopicPath(final Acknowledgements acknowledgement, final TopicPath.Channel channel)
focal_class.class_method_signature: AcknowledgementsAdapter.getPayload(final Acknowledgements acknowledgements)
focal_class.full_signature: private static Payload getPayload(final Acknowledgements acknowledgements)
focal_class.identifier: getPayload
focal_class.modifiers: private static
focal_class.parameters: (final Acknowledgements acknowledgements)
focal_class.return: Payload
focal_class.signature: Payload getPayload(final Acknowledgements acknowledgements)
focal_class.class_method_signature: AcknowledgementsAdapter.getPayloadValue(final Acknowledgements acknowledgements)
focal_class.full_signature: private static JsonObject getPayloadValue(final Acknowledgements acknowledgements)
focal_class.identifier: getPayloadValue
focal_class.modifiers: private static
focal_class.parameters: (final Acknowledgements acknowledgements)
focal_class.return: JsonObject
focal_class.signature: JsonObject getPayloadValue(final Acknowledgements acknowledgements)
focal_class.class_method_signature: AcknowledgementsAdapter.toJsonWithoutLabel(final Acknowledgement ack)
focal_class.full_signature: private static JsonObject toJsonWithoutLabel(final Acknowledgement ack)
focal_class.identifier: toJsonWithoutLabel
focal_class.modifiers: private static
focal_class.parameters: (final Acknowledgement ack)
focal_class.return: JsonObject
focal_class.signature: JsonObject toJsonWithoutLabel(final Acknowledgement ack)
focal_class.class_method_signature: AcknowledgementsAdapter.getExternalHeaders(final DittoHeaders acknowledgementHeaders)
focal_class.full_signature: private DittoHeaders getExternalHeaders(final DittoHeaders acknowledgementHeaders)
focal_class.identifier: getExternalHeaders
focal_class.modifiers: private
focal_class.parameters: (final DittoHeaders acknowledgementHeaders)
focal_class.return: DittoHeaders
focal_class.signature: DittoHeaders getExternalHeaders(final DittoHeaders acknowledgementHeaders)
focal_method.body: @Override
      public Acknowledgements fromAdaptable(final Adaptable adaptable) {
          checkNotNull(adaptable, "adaptable");
          final ThingId thingId = getThingId(adaptable);
          return ThingAcknowledgementsFactory.newAcknowledgements(
                  thingId,
                  gatherContainedAcknowledgements(adaptable, thingId),
                  getStatusCodeOrThrow(adaptable),
                  adaptable.getDittoHeaders()
          );
      }
focal_method.class_method_signature: AcknowledgementsAdapter.fromAdaptable(final Adaptable adaptable)
focal_method.full_signature: @Override public Acknowledgements fromAdaptable(final Adaptable adaptable)
focal_method.identifier: fromAdaptable
focal_method.invocations: checkNotNull getThingId newAcknowledgements gatherContainedAcknowledgements getStatusCodeOrThrow getDittoHeaders
focal_method.modifiers: @Override public
focal_method.parameters: (final Adaptable adaptable)
focal_method.return: Acknowledgements
focal_method.signature: Acknowledgements fromAdaptable(final Adaptable adaptable)