Skip to content

Commit

Permalink
use latest swagger (#22394)
Browse files Browse the repository at this point in the history
  • Loading branch information
arifsaikat-microsoft authored Jun 19, 2021
1 parent 3ddc175 commit 651764c
Show file tree
Hide file tree
Showing 19 changed files with 53 additions and 60 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ public CallingServerClientBuilder pipeline(HttpPipeline pipeline) {
* @return The updated {@link CallingServerClientBuilder} object.
* @throws NullPointerException If {@code tokenCredential} is null.
*/
public CallingServerClientBuilder credential(TokenCredential tokenCredential) {
CallingServerClientBuilder credential(TokenCredential tokenCredential) {
this.tokenCredential = Objects.requireNonNull(tokenCredential, "'tokenCredential' cannot be null.");
return this;
}
Expand All @@ -103,7 +103,7 @@ public CallingServerClientBuilder credential(TokenCredential tokenCredential) {
* @return The updated {@link CallingServerClientBuilder} object.
* @throws NullPointerException If {@code keyCredential} is null.
*/
public CallingServerClientBuilder credential(AzureKeyCredential keyCredential) {
CallingServerClientBuilder credential(AzureKeyCredential keyCredential) {
this.azureKeyCredential = Objects.requireNonNull(keyCredential, "'keyCredential' cannot be null.");
return this;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public final class AddParticipantResultEventInternal {
/*
* The status of the operation
*/
@JsonProperty(value = "status")
@JsonProperty(value = "status", required = true)
private OperationStatus status;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public final class CallConnectionStateChangedEventInternal {
/*
* The call connection state.
*/
@JsonProperty(value = "callConnectionState")
@JsonProperty(value = "callConnectionState", required = true)
private CallConnectionState callConnectionState;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ public final class CallParticipantInternal {
/*
* Is participant muted
*/
@JsonProperty(value = "isMuted")
private Boolean isMuted;
@JsonProperty(value = "isMuted", required = true)
private boolean isMuted;

/**
* Get the identifier property: Communication identifier of the participant.
Expand Down Expand Up @@ -73,7 +73,7 @@ public CallParticipantInternal setParticipantId(String participantId) {
*
* @return the isMuted value.
*/
public Boolean isMuted() {
public boolean isMuted() {
return this.isMuted;
}

Expand All @@ -83,7 +83,7 @@ public Boolean isMuted() {
* @param isMuted the isMuted value to set.
* @return the CallParticipantInternal object itself.
*/
public CallParticipantInternal setIsMuted(Boolean isMuted) {
public CallParticipantInternal setIsMuted(boolean isMuted) {
this.isMuted = isMuted;
return this;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ public final class CallRecordingPropertiesInternal {
/*
* The state of the recording
*/
@JsonProperty(value = "recordingState")
@JsonProperty(value = "recordingState", required = true)
private CallRecordingState recordingState;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ public final class CallRecordingStateChangeEventInternal {
/*
* The state of the recording
*/
@JsonProperty(value = "state")
@JsonProperty(value = "state", required = true)
private CallRecordingState state;

/*
* The time of the recording started
*/
@JsonProperty(value = "startDateTime")
@JsonProperty(value = "startDateTime", required = true)
private OffsetDateTime startDateTime;

/*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public final class CancelAllMediaOperationsResultInternal {
/*
* The status of the operation
*/
@JsonProperty(value = "status")
@JsonProperty(value = "status", required = true)
private OperationStatus status;

/*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public final class PlayAudioResultEventInternal {
/*
* The status of the operation
*/
@JsonProperty(value = "status")
@JsonProperty(value = "status", required = true)
private OperationStatus status;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public final class PlayAudioResultInternal {
/*
* The status of the operation
*/
@JsonProperty(value = "status")
@JsonProperty(value = "status", required = true)
private OperationStatus status;

/*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,71 +11,65 @@
@Fluent
public final class ResultInfoInternal {
/*
* Gets or sets the result code
* For synchronous failures, this maps one-to-one with HTTP responses. For
* asynchronous failures or messages, it is contextual.
* The result code associated with the operation.
*/
@JsonProperty(value = "code")
private Integer code;
@JsonProperty(value = "code", required = true)
private int code;

/*
* Gets or sets the result subcode.
* The subcode further classifies a failure. For example.
* The subcode that further classifies the result.
*/
@JsonProperty(value = "subcode")
private Integer subcode;
@JsonProperty(value = "subcode", required = true)
private int subcode;

/*
* Gets or sets the message
* The message is a detail explanation of subcode.
*/
@JsonProperty(value = "message")
private String message;

/**
* Get the code property: Gets or sets the result code For synchronous failures, this maps one-to-one with HTTP
* responses. For asynchronous failures or messages, it is contextual.
* Get the code property: The result code associated with the operation.
*
* @return the code value.
*/
public Integer getCode() {
public int getCode() {
return this.code;
}

/**
* Set the code property: Gets or sets the result code For synchronous failures, this maps one-to-one with HTTP
* responses. For asynchronous failures or messages, it is contextual.
* Set the code property: The result code associated with the operation.
*
* @param code the code value to set.
* @return the ResultInfoInternal object itself.
*/
public ResultInfoInternal setCode(Integer code) {
public ResultInfoInternal setCode(int code) {
this.code = code;
return this;
}

/**
* Get the subcode property: Gets or sets the result subcode. The subcode further classifies a failure. For example.
* Get the subcode property: The subcode that further classifies the result.
*
* @return the subcode value.
*/
public Integer getSubcode() {
public int getSubcode() {
return this.subcode;
}

/**
* Set the subcode property: Gets or sets the result subcode. The subcode further classifies a failure. For example.
* Set the subcode property: The subcode that further classifies the result.
*
* @param subcode the subcode value to set.
* @return the ResultInfoInternal object itself.
*/
public ResultInfoInternal setSubcode(Integer subcode) {
public ResultInfoInternal setSubcode(int subcode) {
this.subcode = subcode;
return this;
}

/**
* Get the message property: Gets or sets the message The message is a detail explanation of subcode.
* Get the message property: The message is a detail explanation of subcode.
*
* @return the message value.
*/
Expand All @@ -84,7 +78,7 @@ public String getMessage() {
}

/**
* Set the message property: Gets or sets the message The message is a detail explanation of subcode.
* Set the message property: The message is a detail explanation of subcode.
*
* @param message the message value to set.
* @return the ResultInfoInternal object itself.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,47 +8,46 @@
import com.azure.core.annotation.Fluent;
import com.fasterxml.jackson.annotation.JsonProperty;

/** Gets or sets the tone info. */
/** The information about the tone. */
@Fluent
public final class ToneInfoInternal {
/*
* Gets or sets the sequence id. This id can be used to determine if the
* same tone
* was played multiple times or if any tones were missed.
* The sequence id which can be used to determine if the same tone was
* played multiple times or if any tones were missed.
*/
@JsonProperty(value = "sequenceId")
private Integer sequenceId;
@JsonProperty(value = "sequenceId", required = true)
private int sequenceId;

/*
* Gets or sets the tone detected.
* The tone value.
*/
@JsonProperty(value = "tone")
@JsonProperty(value = "tone", required = true)
private ToneValue tone;

/**
* Get the sequenceId property: Gets or sets the sequence id. This id can be used to determine if the same tone was
* played multiple times or if any tones were missed.
* Get the sequenceId property: The sequence id which can be used to determine if the same tone was played multiple
* times or if any tones were missed.
*
* @return the sequenceId value.
*/
public Integer getSequenceId() {
public int getSequenceId() {
return this.sequenceId;
}

/**
* Set the sequenceId property: Gets or sets the sequence id. This id can be used to determine if the same tone was
* played multiple times or if any tones were missed.
* Set the sequenceId property: The sequence id which can be used to determine if the same tone was played multiple
* times or if any tones were missed.
*
* @param sequenceId the sequenceId value to set.
* @return the ToneInfoInternal object itself.
*/
public ToneInfoInternal setSequenceId(Integer sequenceId) {
public ToneInfoInternal setSequenceId(int sequenceId) {
this.sequenceId = sequenceId;
return this;
}

/**
* Get the tone property: Gets or sets the tone detected.
* Get the tone property: The tone value.
*
* @return the tone value.
*/
Expand All @@ -57,7 +56,7 @@ public ToneValue getTone() {
}

/**
* Set the tone property: Gets or sets the tone detected.
* Set the tone property: The tone value.
*
* @param tone the tone value to set.
* @return the ToneInfoInternal object itself.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public final class ToneReceivedEventInternal {
/*
* The tone info.
*/
@JsonProperty(value = "toneInfo")
@JsonProperty(value = "toneInfo", required = true)
private ToneInfoInternal toneInfo;

/*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public OperationStatus getStatus() {
* communications related to this operation
* @param status the status value.
*/
public AddParticipantResultEvent(ResultInfo resultInfo, String operationContext, OperationStatus status) {
AddParticipantResultEvent(ResultInfo resultInfo, String operationContext, OperationStatus status) {
this.resultInfo = resultInfo;
this.operationContext = operationContext;
this.status = status;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public CallConnectionState getCallConnectionState() {
* @param callConnectionId the callConnectionId value.
* @param callConnectionState the callConnectionState value.
*/
public CallConnectionStateChangedEvent(
CallConnectionStateChangedEvent(
String serverCallId,
String callConnectionId,
CallConnectionState callConnectionState) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ public String getServerCallId() {
* @param startDateTime the startDateTime value.
* @param serverCallId the serverCallId value.
*/
public CallRecordingStateChangeEvent(
CallRecordingStateChangeEvent(
String recordingId,
CallRecordingState state,
OffsetDateTime startDateTime,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public List<CallParticipant> getParticipants() {
* @param participants The participants
* @throws IllegalArgumentException if any parameter is null or empty.
*/
public ParticipantsUpdatedEvent(String callConnectionId, List<CallParticipant> participants) {
ParticipantsUpdatedEvent(String callConnectionId, List<CallParticipant> participants) {
if (callConnectionId == null || callConnectionId.isEmpty()) {
throw new IllegalArgumentException("object callConnectionId cannot be null or empty");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public OperationStatus getStatus() {
* communications related to this operation
* @param status the status value.
*/
public PlayAudioResultEvent(ResultInfo resultInfo, String operationContext, OperationStatus status) {
PlayAudioResultEvent(ResultInfo resultInfo, String operationContext, OperationStatus status) {
this.resultInfo = resultInfo;
this.operationContext = operationContext;
this.status = status;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public String getCallConnectionId() {
* @param toneInfo the toneInfo value.
* @param callConnectionId the callConnectionId value.
*/
public ToneReceivedEvent(ToneInfo toneInfo, String callConnectionId) {
ToneReceivedEvent(ToneInfo toneInfo, String callConnectionId) {
this.toneInfo = toneInfo;
this.callConnectionId = callConnectionId;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ To update generated files for calling service, run the following command
``` yaml
tag: package-2021-06-15-preview
require:
- https://raw.githubusercontent.com/Azure/azure-rest-api-specs/5ffa6f90f1916423bd09855f1bfe32d2bd78ecab/specification/communication/data-plane/CallingServer/readme.md
- https://github.com/Azure/azure-rest-api-specs/blob/b4b5fa5ee23f8cce9e1ade4a82076b4c34b25651/specification/communication/data-plane/CallingServer/readme.md
java: true
output-folder: ..\
license-header: MICROSOFT_MIT_SMALL
Expand Down

0 comments on commit 651764c

Please sign in to comment.