Skip to content

Commit e794035

Browse files
authored
Merge pull request #123 from egecansen/api_assured_deprecated
2 parents ae45d01 + 5d34fb1 commit e794035

File tree

6 files changed

+11
-7
lines changed

6 files changed

+11
-7
lines changed

src/main/java/api_assured/ApiUtilities.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
import static utils.reflection.ReflectionUtilities.iterativeConditionalInvocation;
2020

2121
@SuppressWarnings("unused")
22+
@Deprecated(since = "1.7.4")
2223
public abstract class ApiUtilities extends Caller {
2324

2425
public static Printer log = new Printer(ApiUtilities.class);

src/main/java/api_assured/Caller.java

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,11 @@
88
import retrofit2.Call;
99
import retrofit2.Response;
1010
import utils.*;
11-
import utils.reflection.ReflectionUtilities;
12-
1311
import java.io.IOException;
1412
import java.nio.charset.StandardCharsets;
1513
import java.util.Objects;
16-
17-
import static utils.MappingUtilities.Json.*;
14+
import static utils.mapping.MappingUtilities.Json.fromJsonString;
15+
import static utils.mapping.MappingUtilities.Json.getJsonString;
1816
import static utils.reflection.ReflectionUtilities.getPreviousMethodName;
1917
import static utils.StringUtilities.Color.*;
2018
import static utils.reflection.ReflectionUtilities.isOfType;
@@ -29,6 +27,7 @@
2927
* @version 1.4.0 (Documented in 1.4.0, released in an earlier version)
3028
*/
3129
@SuppressWarnings("unused")
30+
@Deprecated(since = "1.7.4")
3231
public abstract class Caller {
3332

3433
/**
@@ -175,7 +174,7 @@ private static <T> Response<T> getResponse(Call<T> call, boolean printBody) thro
175174
* @return A deserialized error object instance of type {@code Model}.
176175
* @throws RuntimeException if there's an issue processing the error content or deserializing it.
177176
*
178-
* @see MappingUtilities.Json#fromJsonString(String, Class)
177+
* @see utils.mapping.MappingUtilities.Json#fromJsonString(String, Class)
179178
*/
180179
@SuppressWarnings("unchecked")
181180
private static <ErrorModel> ErrorModel getErrorObject(Response<?> response, Class<ErrorModel> errorModel) throws JsonProcessingException {
@@ -253,8 +252,8 @@ private static <ResponseModel> Response<ResponseModel> call(
253252
* @return A deserialized error model instance of type {@code ErrorModel} if a match is found.
254253
* @throws RuntimeException if none of the provided error models match the error content of the response.
255254
*
256-
* @see MappingUtilities.Json#fromJsonString(String, Class)
257-
* @see MappingUtilities.Json#getJsonStringFor(Object)
255+
* @see utils.mapping.MappingUtilities.Json#fromJsonString(String, Class)
256+
* @see utils.mapping.MappingUtilities.Json#getJsonStringFor(Object)
258257
* @see #getErrorObject(Response, Class)
259258
*/
260259
@SuppressWarnings("unchecked")

src/main/java/api_assured/ResponsePair.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,5 @@
66
* @param <Response> expected Response-SuccessModel-
77
* @param <ErrorBody> potential error body
88
*/
9+
@Deprecated(since = "1.7.4")
910
public record ResponsePair<Response, ErrorBody>(Response response, ErrorBody errorBody) { }

src/main/java/api_assured/ServiceGenerator.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
* @version 1.4.0 (Documented in 1.4.0, released in version 1.0.0)
3838
*/
3939
@SuppressWarnings({"unused", "UnusedReturnValue"})
40+
@Deprecated(since = "1.7.4")
4041
public class ServiceGenerator {
4142

4243
OkHttpClient client;

src/main/java/api_assured/exceptions/FailedCallException.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
/**
44
* This class represents an exception that is thrown when a call fails.
55
*/
6+
@Deprecated(since = "1.7.4")
67
public class FailedCallException extends RuntimeException {
78

89
/**

src/main/java/api_assured/exceptions/JavaUtilitiesException.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
/**
44
* This class represents an exception that is thrown when an error occurs in JavaUtilities.
55
*/
6+
@Deprecated(since = "1.7.4")
67
public class JavaUtilitiesException extends RuntimeException {
78

89
/**

0 commit comments

Comments
 (0)