-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathBaseError.java
More file actions
61 lines (54 loc) · 1.51 KB
/
BaseError.java
File metadata and controls
61 lines (54 loc) · 1.51 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
// Code generated by sumup-java/codegen. DO NOT EDIT.
package com.sumup.sdk.models;
public record BaseError(
/**
* A unique identifier for the error instance. This can be used to trace the error back to the
* server logs.
*/
String instance,
/** A human-readable message describing the error that occurred. */
String message) {
/**
* Creates a builder for BaseError.
*
* @return Builder that constructs immutable BaseError instances.
*/
public static Builder builder() {
return new Builder();
}
/** Builder for BaseError instances. */
public static final class Builder {
private String instance;
private String message;
private Builder() {}
/**
* Sets the value for {@code instance}.
*
* @param instance A unique identifier for the error instance. This can be used to trace the
* error back to the server logs.
* @return This builder instance.
*/
public Builder instance(String instance) {
this.instance = instance;
return this;
}
/**
* Sets the value for {@code message}.
*
* @param message A human-readable message describing the error that occurred.
* @return This builder instance.
*/
public Builder message(String message) {
this.message = message;
return this;
}
/**
* Builds an immutable BaseError instance.
*
* @return Immutable BaseError.
*/
public BaseError build() {
return new BaseError(instance, message);
}
}
}