Skip to content

Commit fb4d55d

Browse files
committed
Get the tests running + rename all the BXML imports
intelliJ is the best
1 parent f38a0a9 commit fb4d55d

File tree

190 files changed

+311
-9962
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

190 files changed

+311
-9962
lines changed

.idea/.gitignore

Lines changed: 0 additions & 8 deletions
This file was deleted.
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
package com.bandwidth.sdk.model;
2+
3+
import static java.util.function.Function.identity;
4+
import static java.util.stream.Collectors.toMap;
5+
6+
import com.fasterxml.jackson.annotation.JsonCreator;
7+
import java.util.Arrays;
8+
import java.util.Map;
9+
import lombok.Getter;
10+
11+
@Getter
12+
public enum DiversionReason {
13+
AWAY("away"),
14+
DEFLECTION("deflection"),
15+
DO_NOT_DISTURB("do-not-disturb"),
16+
FOLLOW_ME("follow-me"),
17+
NO_ANSWER("no-answer"),
18+
OUT_OF_SERVICE("out-of-service"),
19+
TIME_OF_DAY("time-of-day"),
20+
UNAVAILABLE("unavailable"),
21+
UNCONDITIONAL("unconditional"),
22+
UNKNOWN("unknown"),
23+
USER_BUSY("user-busy"),
24+
;
25+
26+
private static final Map<String, DiversionReason> DESERIALIZATION_MAP =
27+
Arrays.stream(values())
28+
.collect(toMap(v -> v.name, identity()));
29+
30+
private final String name;
31+
32+
DiversionReason(String name) {
33+
this.name = name;
34+
}
35+
36+
@JsonCreator
37+
public static DiversionReason resolve(String name) {
38+
return DESERIALIZATION_MAP.get(name.toLowerCase());
39+
}
40+
41+
@Override
42+
public String toString() {
43+
return name;
44+
}
45+
}
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
package com.bandwidth.sdk.model;
2+
3+
import static java.util.function.Function.identity;
4+
import static java.util.stream.Collectors.toMap;
5+
6+
import com.fasterxml.jackson.annotation.JsonCreator;
7+
import java.util.Arrays;
8+
import java.util.Map;
9+
import lombok.Getter;
10+
11+
@Getter
12+
public enum DiversionTreatment {
13+
NONE("none"),
14+
PROPAGATE("propagate"),
15+
STACK("stack"),
16+
;
17+
18+
private static final Map<String, DiversionTreatment> DESERIALIZATION_MAP =
19+
Arrays.stream(values())
20+
.collect(toMap(v -> v.name, identity()));
21+
22+
private final String name;
23+
24+
DiversionTreatment(String name) {
25+
this.name = name;
26+
}
27+
28+
@JsonCreator
29+
public static DiversionTreatment resolve(String name) {
30+
return DESERIALIZATION_MAP.get(name.toLowerCase());
31+
}
32+
33+
@Override
34+
public String toString() {
35+
return name;
36+
}
37+
}

src/main/java/com/bandwidth/sdk/model/bxml/AudioProducer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package org.openapitools.client.model.bxml;
1+
package com.bandwidth.sdk.model.bxml;
22

33
import com.fasterxml.jackson.annotation.JsonSubTypes;
44
import com.fasterxml.jackson.annotation.JsonTypeInfo;

src/main/java/com/bandwidth/sdk/model/bxml/Bridge.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@
66
*
77
*/
88

9-
package org.openapitools.client.model.bxml;
9+
package com.bandwidth.sdk.model.bxml;
1010

11-
import static org.openapitools.client.model.bxml.utils.BxmlConstants.DEFAULT_CALLBACK_METHOD;
11+
import static com.bandwidth.sdk.model.bxml.utils.BxmlConstants.DEFAULT_CALLBACK_METHOD;
1212

1313
import jakarta.xml.bind.annotation.XmlAccessType;
1414
import jakarta.xml.bind.annotation.XmlAccessorType;

src/main/java/com/bandwidth/sdk/model/bxml/Bxml.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
*
44
*/
55

6-
package org.openapitools.client.model.bxml;
6+
package com.bandwidth.sdk.model.bxml;
77

88
import jakarta.xml.bind.JAXBContext;
99
import jakarta.xml.bind.JAXBException;

src/main/java/com/bandwidth/sdk/model/bxml/Conference.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@
55
* so your conference names can be whatever you want. If the conference ends and then you later use the same conference name, a new unique ID will be created.
66
*/
77

8-
package org.openapitools.client.model.bxml;
8+
package com.bandwidth.sdk.model.bxml;
99

10-
import static org.openapitools.client.model.bxml.utils.BxmlConstants.DEFAULT_CALLBACK_METHOD;
11-
import static org.openapitools.client.model.bxml.utils.BxmlConstants.DEFAULT_EMPTY_STRING;
10+
import static com.bandwidth.sdk.model.bxml.utils.BxmlConstants.DEFAULT_CALLBACK_METHOD;
11+
import static com.bandwidth.sdk.model.bxml.utils.BxmlConstants.DEFAULT_EMPTY_STRING;
1212

1313

1414
import jakarta.xml.bind.annotation.XmlAccessType;

src/main/java/com/bandwidth/sdk/model/bxml/CustomParam.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* You may specify up to 12 {@code <CustomParam>} elements nested within a {@code <StartTranscription>} tag.
44
*/
55

6-
package org.openapitools.client.model.bxml;
6+
package com.bandwidth.sdk.model.bxml;
77

88

99
import jakarta.xml.bind.annotation.XmlAccessType;

src/main/java/com/bandwidth/sdk/model/bxml/Forward.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@
33
* your application will not have any control over either leg of the call. When either leg hangs up, a Disconnect event will be sent to your Call status webhook URL.
44
*/
55

6-
package org.openapitools.client.model.bxml;
6+
package com.bandwidth.sdk.model.bxml;
77

8-
import static org.openapitools.client.model.bxml.utils.BxmlConstants.DEFAULT_CALL_TIMEOUT;
8+
import static com.bandwidth.sdk.model.bxml.utils.BxmlConstants.DEFAULT_CALL_TIMEOUT;
99

10-
import org.openapitools.client.model.DiversionReason;
11-
import org.openapitools.client.model.DiversionTreatment;
10+
import com.bandwidth.sdk.model.DiversionReason;
11+
import com.bandwidth.sdk.model.DiversionTreatment;
1212
import jakarta.xml.bind.annotation.XmlAccessType;
1313
import jakarta.xml.bind.annotation.XmlAccessorType;
1414
import jakarta.xml.bind.annotation.XmlAttribute;

src/main/java/com/bandwidth/sdk/model/bxml/Gather.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
* The {@code <Gather>} verb is used to collect digits for some period of time.
33
*/
44

5-
package org.openapitools.client.model.bxml;
5+
package com.bandwidth.sdk.model.bxml;
66

7-
import static org.openapitools.client.model.bxml.utils.BxmlConstants.DEFAULT_CALLBACK_METHOD;
8-
import static org.openapitools.client.model.bxml.utils.BxmlConstants.DEFAULT_FIRSTDIGIT_TIMEOUT;
9-
import static org.openapitools.client.model.bxml.utils.BxmlConstants.DEFAULT_INTERDIGIT_TIMEOUT;
10-
import static org.openapitools.client.model.bxml.utils.BxmlConstants.DEFAULT_MAX_DIGITS;
11-
import static org.openapitools.client.model.bxml.utils.BxmlConstants.DEFAULT_REPEAT_COUNT;
7+
import static com.bandwidth.sdk.model.bxml.utils.BxmlConstants.DEFAULT_CALLBACK_METHOD;
8+
import static com.bandwidth.sdk.model.bxml.utils.BxmlConstants.DEFAULT_FIRSTDIGIT_TIMEOUT;
9+
import static com.bandwidth.sdk.model.bxml.utils.BxmlConstants.DEFAULT_INTERDIGIT_TIMEOUT;
10+
import static com.bandwidth.sdk.model.bxml.utils.BxmlConstants.DEFAULT_MAX_DIGITS;
11+
import static com.bandwidth.sdk.model.bxml.utils.BxmlConstants.DEFAULT_REPEAT_COUNT;
1212

1313

1414
import jakarta.xml.bind.annotation.XmlAccessType;

0 commit comments

Comments
 (0)