Skip to content

Commit 9dab224

Browse files
committed
Generated client code for getAllSpeakersEmails endpoint
1 parent ae12543 commit 9dab224

File tree

3 files changed

+598
-0
lines changed

3 files changed

+598
-0
lines changed

sessionize-java-client/src/generated/java/software/xdev/sessionize/api/SpeakersApi.java

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
import software.xdev.sessionize.client.Pair;
2121

2222
import software.xdev.sessionize.model.Speaker;
23+
import software.xdev.sessionize.model.SpeakerWithEmail;
2324

2425

2526
import java.util.ArrayList;
@@ -126,4 +127,87 @@ public List<Speaker> getAllSpeakers(String endpointId, Map<String, String> addit
126127
);
127128
}
128129

130+
/**
131+
*
132+
* Undocumented endpoint for retrieving the speaker-emails
133+
* @param endpointId (required)
134+
* @param s Special key that is only available/retrievable for unlocked admins (Contacting Sessionize-Support is required) (required)
135+
* @return List&lt;SpeakerWithEmail&gt;
136+
* @throws ApiException if fails to make API call
137+
*/
138+
public List<SpeakerWithEmail> getAllSpeakersEmails(String endpointId, String s) throws ApiException {
139+
return this.getAllSpeakersEmails(endpointId, s, Collections.emptyMap());
140+
}
141+
142+
143+
/**
144+
*
145+
* Undocumented endpoint for retrieving the speaker-emails
146+
* @param endpointId (required)
147+
* @param s Special key that is only available/retrievable for unlocked admins (Contacting Sessionize-Support is required) (required)
148+
* @param additionalHeaders additionalHeaders for this call
149+
* @return List&lt;SpeakerWithEmail&gt;
150+
* @throws ApiException if fails to make API call
151+
*/
152+
public List<SpeakerWithEmail> getAllSpeakersEmails(String endpointId, String s, Map<String, String> additionalHeaders) throws ApiException {
153+
Object localVarPostBody = null;
154+
155+
// verify the required parameter 'endpointId' is set
156+
if (endpointId == null) {
157+
throw new ApiException(400, "Missing the required parameter 'endpointId' when calling getAllSpeakersEmails");
158+
}
159+
160+
// verify the required parameter 's' is set
161+
if (s == null) {
162+
throw new ApiException(400, "Missing the required parameter 's' when calling getAllSpeakersEmails");
163+
}
164+
165+
// create path and map variables
166+
String localVarPath = "/api/v2/{endpointId}/view/SpeakersEmails"
167+
.replaceAll("\\{" + "endpointId" + "\\}", apiClient.escapeString(endpointId.toString()));
168+
169+
StringJoiner localVarQueryStringJoiner = new StringJoiner("&");
170+
String localVarQueryParameterBaseName;
171+
List<Pair> localVarQueryParams = new ArrayList<Pair>();
172+
List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
173+
Map<String, String> localVarHeaderParams = new HashMap<String, String>();
174+
Map<String, String> localVarCookieParams = new HashMap<String, String>();
175+
Map<String, Object> localVarFormParams = new HashMap<String, Object>();
176+
177+
localVarQueryParams.addAll(apiClient.parameterToPair("s", s));
178+
179+
localVarHeaderParams.putAll(additionalHeaders);
180+
181+
182+
183+
final String[] localVarAccepts = {
184+
"application/json"
185+
};
186+
final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
187+
188+
final String[] localVarContentTypes = {
189+
190+
};
191+
final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
192+
193+
String[] localVarAuthNames = new String[] { };
194+
195+
TypeReference<List<SpeakerWithEmail>> localVarReturnType = new TypeReference<List<SpeakerWithEmail>>() {};
196+
return apiClient.invokeAPI(
197+
localVarPath,
198+
"GET",
199+
localVarQueryParams,
200+
localVarCollectionQueryParams,
201+
localVarQueryStringJoiner.toString(),
202+
localVarPostBody,
203+
localVarHeaderParams,
204+
localVarCookieParams,
205+
localVarFormParams,
206+
localVarAccept,
207+
localVarContentType,
208+
localVarAuthNames,
209+
localVarReturnType
210+
);
211+
}
212+
129213
}
Lines changed: 236 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,236 @@
1+
/*
2+
* Sessionize JSON-REST API
3+
* Sessionize JSON-REST API documentation by XDEV Software
4+
*
5+
* The version of the OpenAPI document: 2.0
6+
*
7+
*
8+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9+
* https://openapi-generator.tech
10+
* Do not edit the class manually.
11+
*/
12+
13+
14+
package software.xdev.sessionize.model;
15+
16+
import java.util.Objects;
17+
import java.util.Arrays;
18+
import com.fasterxml.jackson.annotation.JsonInclude;
19+
import com.fasterxml.jackson.annotation.JsonProperty;
20+
import com.fasterxml.jackson.annotation.JsonCreator;
21+
import com.fasterxml.jackson.annotation.JsonTypeName;
22+
import com.fasterxml.jackson.annotation.JsonValue;
23+
import java.util.UUID;
24+
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
25+
import com.fasterxml.jackson.annotation.JsonTypeName;
26+
import java.io.UnsupportedEncodingException;
27+
import java.net.URLEncoder;
28+
import java.util.StringJoiner;
29+
30+
/**
31+
* BaseSpeakerEssential
32+
*/
33+
@JsonPropertyOrder({
34+
BaseSpeakerEssential.JSON_PROPERTY_ID,
35+
BaseSpeakerEssential.JSON_PROPERTY_FIRST_NAME,
36+
BaseSpeakerEssential.JSON_PROPERTY_LAST_NAME
37+
})
38+
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
39+
public class BaseSpeakerEssential {
40+
public static final String JSON_PROPERTY_ID = "id";
41+
private UUID id;
42+
43+
public static final String JSON_PROPERTY_FIRST_NAME = "firstName";
44+
private String firstName;
45+
46+
public static final String JSON_PROPERTY_LAST_NAME = "lastName";
47+
private String lastName;
48+
49+
public BaseSpeakerEssential() {
50+
}
51+
52+
public BaseSpeakerEssential id(UUID id) {
53+
54+
this.id = id;
55+
return this;
56+
}
57+
58+
/**
59+
* Get id
60+
* @return id
61+
**/
62+
@jakarta.annotation.Nonnull
63+
@JsonProperty(JSON_PROPERTY_ID)
64+
@JsonInclude(value = JsonInclude.Include.ALWAYS)
65+
66+
public UUID getId() {
67+
return id;
68+
}
69+
70+
71+
@JsonProperty(JSON_PROPERTY_ID)
72+
@JsonInclude(value = JsonInclude.Include.ALWAYS)
73+
public void setId(UUID id) {
74+
this.id = id;
75+
}
76+
77+
78+
public BaseSpeakerEssential firstName(String firstName) {
79+
80+
this.firstName = firstName;
81+
return this;
82+
}
83+
84+
/**
85+
* Get firstName
86+
* @return firstName
87+
**/
88+
@jakarta.annotation.Nonnull
89+
@JsonProperty(JSON_PROPERTY_FIRST_NAME)
90+
@JsonInclude(value = JsonInclude.Include.ALWAYS)
91+
92+
public String getFirstName() {
93+
return firstName;
94+
}
95+
96+
97+
@JsonProperty(JSON_PROPERTY_FIRST_NAME)
98+
@JsonInclude(value = JsonInclude.Include.ALWAYS)
99+
public void setFirstName(String firstName) {
100+
this.firstName = firstName;
101+
}
102+
103+
104+
public BaseSpeakerEssential lastName(String lastName) {
105+
106+
this.lastName = lastName;
107+
return this;
108+
}
109+
110+
/**
111+
* Get lastName
112+
* @return lastName
113+
**/
114+
@jakarta.annotation.Nonnull
115+
@JsonProperty(JSON_PROPERTY_LAST_NAME)
116+
@JsonInclude(value = JsonInclude.Include.ALWAYS)
117+
118+
public String getLastName() {
119+
return lastName;
120+
}
121+
122+
123+
@JsonProperty(JSON_PROPERTY_LAST_NAME)
124+
@JsonInclude(value = JsonInclude.Include.ALWAYS)
125+
public void setLastName(String lastName) {
126+
this.lastName = lastName;
127+
}
128+
129+
@Override
130+
public boolean equals(Object o) {
131+
if (this == o) {
132+
return true;
133+
}
134+
if (o == null || getClass() != o.getClass()) {
135+
return false;
136+
}
137+
BaseSpeakerEssential baseSpeakerEssential = (BaseSpeakerEssential) o;
138+
return Objects.equals(this.id, baseSpeakerEssential.id) &&
139+
Objects.equals(this.firstName, baseSpeakerEssential.firstName) &&
140+
Objects.equals(this.lastName, baseSpeakerEssential.lastName);
141+
}
142+
143+
@Override
144+
public int hashCode() {
145+
return Objects.hash(id, firstName, lastName);
146+
}
147+
148+
@Override
149+
public String toString() {
150+
StringBuilder sb = new StringBuilder();
151+
sb.append("class BaseSpeakerEssential {\n");
152+
sb.append(" id: ").append(toIndentedString(id)).append("\n");
153+
sb.append(" firstName: ").append(toIndentedString(firstName)).append("\n");
154+
sb.append(" lastName: ").append(toIndentedString(lastName)).append("\n");
155+
sb.append("}");
156+
return sb.toString();
157+
}
158+
159+
/**
160+
* Convert the given object to string with each line indented by 4 spaces
161+
* (except the first line).
162+
*/
163+
private String toIndentedString(Object o) {
164+
if (o == null) {
165+
return "null";
166+
}
167+
return o.toString().replace("\n", "\n ");
168+
}
169+
170+
/**
171+
* Convert the instance into URL query string.
172+
*
173+
* @return URL query string
174+
*/
175+
public String toUrlQueryString() {
176+
return toUrlQueryString(null);
177+
}
178+
179+
/**
180+
* Convert the instance into URL query string.
181+
*
182+
* @param prefix prefix of the query string
183+
* @return URL query string
184+
*/
185+
public String toUrlQueryString(String prefix) {
186+
String suffix = "";
187+
String containerSuffix = "";
188+
String containerPrefix = "";
189+
if (prefix == null) {
190+
// style=form, explode=true, e.g. /pet?name=cat&type=manx
191+
prefix = "";
192+
} else {
193+
// deepObject style e.g. /pet?id[name]=cat&id[type]=manx
194+
prefix = prefix + "[";
195+
suffix = "]";
196+
containerSuffix = "]";
197+
containerPrefix = "[";
198+
}
199+
200+
StringJoiner joiner = new StringJoiner("&");
201+
202+
// add `id` to the URL query string
203+
if (getId() != null) {
204+
try {
205+
joiner.add(String.format("%sid%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getId()), "UTF-8").replaceAll("\\+", "%20")));
206+
} catch (UnsupportedEncodingException e) {
207+
// Should never happen, UTF-8 is always supported
208+
throw new RuntimeException(e);
209+
}
210+
}
211+
212+
// add `firstName` to the URL query string
213+
if (getFirstName() != null) {
214+
try {
215+
joiner.add(String.format("%sfirstName%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getFirstName()), "UTF-8").replaceAll("\\+", "%20")));
216+
} catch (UnsupportedEncodingException e) {
217+
// Should never happen, UTF-8 is always supported
218+
throw new RuntimeException(e);
219+
}
220+
}
221+
222+
// add `lastName` to the URL query string
223+
if (getLastName() != null) {
224+
try {
225+
joiner.add(String.format("%slastName%s=%s", prefix, suffix, URLEncoder.encode(String.valueOf(getLastName()), "UTF-8").replaceAll("\\+", "%20")));
226+
} catch (UnsupportedEncodingException e) {
227+
// Should never happen, UTF-8 is always supported
228+
throw new RuntimeException(e);
229+
}
230+
}
231+
232+
return joiner.toString();
233+
}
234+
235+
}
236+

0 commit comments

Comments
 (0)