DittoRuntimeException extends RuntimeException implements Jsonifiable.WithPredicate<JsonObject, JsonField>, WithDittoHeaders<DittoRuntimeException>,
        WithManifest { public static Builder newBuilder(final String errorCode, final HttpStatusCode statusCode) { return new Builder(errorCode, statusCode); } protected  DittoRuntimeException(final String errorCode,
            final HttpStatusCode statusCode,
            final DittoHeaders dittoHeaders,
            @Nullable final String message,
            @Nullable final String description,
            @Nullable final Throwable cause,
            @Nullable final URI href); DittoRuntimeExceptionBuilder<? extends DittoRuntimeException> getBuilder(); static DittoRuntimeException asDittoRuntimeException(final Throwable throwable,
            final Function<Throwable, DittoRuntimeException> alternativeExceptionBuilder); static Builder newBuilder(final String errorCode, final HttpStatusCode statusCode); static DittoRuntimeExceptionBuilder<? extends DittoRuntimeException> newBuilder(
            final DittoRuntimeException dittoRuntimeException); String getErrorCode(); HttpStatusCode getStatusCode(); @Override DittoHeaders getDittoHeaders(); @Override DittoRuntimeException setDittoHeaders(final DittoHeaders dittoHeaders); @Override JsonSchemaVersion getImplementedSchemaVersion(); Optional<String> getDescription(); Optional<URI> getHref(); @Override String getManifest(); @SuppressWarnings({"squid:MethodCyclomaticComplexity", "squid:S1067", "OverlyComplexMethod"}) @Override boolean equals(@Nullable final Object o); @Override int hashCode(); @Override JsonObject toJson(); @Override JsonObject toJson(final JsonSchemaVersion schemaVersion, final Predicate<JsonField> thePredicate); static T fromJson(final JsonObject jsonObject,
            final DittoHeaders dittoHeaders, final DittoRuntimeExceptionBuilder<T> builder); static T fromMessage(@Nullable final String message,
            final DittoHeaders dittoHeaders, final DittoRuntimeExceptionBuilder<T> builder); static Optional<DittoRuntimeException> fromUnknownErrorJson(final JsonObject jsonObject,
            final DittoHeaders headers); @Override String toString();  }
@Test public void copyAndAlterExistingDittoRuntimeException() { final DittoHeaders dittoHeadersMock = mock(DittoHeaders.class); final DittoRuntimeException withOtherDittoHeaders = DittoRuntimeException.newBuilder(KNOWN_DITTO_RUNTIME_EXCEPTION) .dittoHeaders(dittoHeadersMock) .build(); DittoBaseAssertions.assertThat(withOtherDittoHeaders) .hasErrorCode(KNOWN_ERROR_CODE) .hasStatusCode(KNOWN_STATUS_CODE) .hasDittoHeaders(dittoHeadersMock) .hasDescription(KNOWN_DESCRIPTION) .hasMessage(KNOWN_MESSAGE) .hasCause(KNOWN_CAUSE) .hasNoHref(); }