diff --git a/sdk/logic/mgmt-v2019_05_01/pom.xml b/sdk/logic/mgmt-v2019_05_01/pom.xml new file mode 100644 index 000000000000..805a818c3a3a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/pom.xml @@ -0,0 +1,135 @@ + + + 4.0.0 + com.microsoft.azure.logic.v2019_05_01 + + com.microsoft.azure + azure-arm-parent + 1.1.0 + ../../../pom.management.xml + + azure-mgmt-logic + 1.0.0-beta + jar + Microsoft Azure SDK for Logic Management + This package contains Microsoft Logic Management SDK. + https://github.com/Azure/azure-sdk-for-java + + + The MIT License (MIT) + http://opensource.org/licenses/MIT + repo + + + + scm:git:https://github.com/Azure/azure-sdk-for-java + scm:git:git@github.com:Azure/azure-sdk-for-java.git + HEAD + + + UTF-8 + + + + + microsoft + Microsoft + + + + + com.microsoft.azure + azure-client-runtime + + + com.microsoft.azure + azure-arm-client-runtime + + + junit + junit + test + + + com.microsoft.azure + azure-client-authentication + test + + + com.microsoft.azure + azure-mgmt-resources + test + + + com.microsoft.azure + azure-arm-client-runtime + test-jar + test + + 1.6.5 + + + + + + org.apache.maven.plugins + maven-jar-plugin + + + + true + true + + + + + + org.codehaus.mojo + build-helper-maven-plugin + + + org.apache.maven.plugins + maven-compiler-plugin + 3.1 + + 1.7 + 1.7 + + + com.microsoft.azure.management.apigeneration.LangDefinitionProcessor + + + true + true + + true + true + + + + + org.apache.maven.plugins + maven-javadoc-plugin + 2.8 + + *.implementation.*;*.utils.*;com.microsoft.schemas._2003._10.serialization;*.blob.core.search + + + /** +
* Copyright (c) Microsoft Corporation. All rights reserved. +
* Licensed under the MIT License. See License.txt in the project root for +
* license information. +
*/ + ]]> +
+
+
+
+
+
diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2AcknowledgementConnectionSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2AcknowledgementConnectionSettings.java new file mode 100644 index 000000000000..8daf40e77d70 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2AcknowledgementConnectionSettings.java @@ -0,0 +1,121 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The AS2 agreement acknowledgement connection settings. + */ +public class AS2AcknowledgementConnectionSettings { + /** + * Indicates whether to ignore mismatch in certificate name. + */ + @JsonProperty(value = "ignoreCertificateNameMismatch", required = true) + private boolean ignoreCertificateNameMismatch; + + /** + * Indicates whether to support HTTP status code 'CONTINUE'. + */ + @JsonProperty(value = "supportHttpStatusCodeContinue", required = true) + private boolean supportHttpStatusCodeContinue; + + /** + * Indicates whether to keep the connection alive. + */ + @JsonProperty(value = "keepHttpConnectionAlive", required = true) + private boolean keepHttpConnectionAlive; + + /** + * Indicates whether to unfold the HTTP headers. + */ + @JsonProperty(value = "unfoldHttpHeaders", required = true) + private boolean unfoldHttpHeaders; + + /** + * Get indicates whether to ignore mismatch in certificate name. + * + * @return the ignoreCertificateNameMismatch value + */ + public boolean ignoreCertificateNameMismatch() { + return this.ignoreCertificateNameMismatch; + } + + /** + * Set indicates whether to ignore mismatch in certificate name. + * + * @param ignoreCertificateNameMismatch the ignoreCertificateNameMismatch value to set + * @return the AS2AcknowledgementConnectionSettings object itself. + */ + public AS2AcknowledgementConnectionSettings withIgnoreCertificateNameMismatch(boolean ignoreCertificateNameMismatch) { + this.ignoreCertificateNameMismatch = ignoreCertificateNameMismatch; + return this; + } + + /** + * Get indicates whether to support HTTP status code 'CONTINUE'. + * + * @return the supportHttpStatusCodeContinue value + */ + public boolean supportHttpStatusCodeContinue() { + return this.supportHttpStatusCodeContinue; + } + + /** + * Set indicates whether to support HTTP status code 'CONTINUE'. + * + * @param supportHttpStatusCodeContinue the supportHttpStatusCodeContinue value to set + * @return the AS2AcknowledgementConnectionSettings object itself. + */ + public AS2AcknowledgementConnectionSettings withSupportHttpStatusCodeContinue(boolean supportHttpStatusCodeContinue) { + this.supportHttpStatusCodeContinue = supportHttpStatusCodeContinue; + return this; + } + + /** + * Get indicates whether to keep the connection alive. + * + * @return the keepHttpConnectionAlive value + */ + public boolean keepHttpConnectionAlive() { + return this.keepHttpConnectionAlive; + } + + /** + * Set indicates whether to keep the connection alive. + * + * @param keepHttpConnectionAlive the keepHttpConnectionAlive value to set + * @return the AS2AcknowledgementConnectionSettings object itself. + */ + public AS2AcknowledgementConnectionSettings withKeepHttpConnectionAlive(boolean keepHttpConnectionAlive) { + this.keepHttpConnectionAlive = keepHttpConnectionAlive; + return this; + } + + /** + * Get indicates whether to unfold the HTTP headers. + * + * @return the unfoldHttpHeaders value + */ + public boolean unfoldHttpHeaders() { + return this.unfoldHttpHeaders; + } + + /** + * Set indicates whether to unfold the HTTP headers. + * + * @param unfoldHttpHeaders the unfoldHttpHeaders value to set + * @return the AS2AcknowledgementConnectionSettings object itself. + */ + public AS2AcknowledgementConnectionSettings withUnfoldHttpHeaders(boolean unfoldHttpHeaders) { + this.unfoldHttpHeaders = unfoldHttpHeaders; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2AgreementContent.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2AgreementContent.java new file mode 100644 index 000000000000..8a5670d47eb5 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2AgreementContent.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration account AS2 agreement content. + */ +public class AS2AgreementContent { + /** + * The AS2 one-way receive agreement. + */ + @JsonProperty(value = "receiveAgreement", required = true) + private AS2OneWayAgreement receiveAgreement; + + /** + * The AS2 one-way send agreement. + */ + @JsonProperty(value = "sendAgreement", required = true) + private AS2OneWayAgreement sendAgreement; + + /** + * Get the AS2 one-way receive agreement. + * + * @return the receiveAgreement value + */ + public AS2OneWayAgreement receiveAgreement() { + return this.receiveAgreement; + } + + /** + * Set the AS2 one-way receive agreement. + * + * @param receiveAgreement the receiveAgreement value to set + * @return the AS2AgreementContent object itself. + */ + public AS2AgreementContent withReceiveAgreement(AS2OneWayAgreement receiveAgreement) { + this.receiveAgreement = receiveAgreement; + return this; + } + + /** + * Get the AS2 one-way send agreement. + * + * @return the sendAgreement value + */ + public AS2OneWayAgreement sendAgreement() { + return this.sendAgreement; + } + + /** + * Set the AS2 one-way send agreement. + * + * @param sendAgreement the sendAgreement value to set + * @return the AS2AgreementContent object itself. + */ + public AS2AgreementContent withSendAgreement(AS2OneWayAgreement sendAgreement) { + this.sendAgreement = sendAgreement; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2EnvelopeSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2EnvelopeSettings.java new file mode 100644 index 000000000000..c500723ece08 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2EnvelopeSettings.java @@ -0,0 +1,148 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The AS2 agreement envelope settings. + */ +public class AS2EnvelopeSettings { + /** + * The message content type. + */ + @JsonProperty(value = "messageContentType", required = true) + private String messageContentType; + + /** + * The value indicating whether to transmit file name in mime header. + */ + @JsonProperty(value = "transmitFileNameInMimeHeader", required = true) + private boolean transmitFileNameInMimeHeader; + + /** + * The template for file name. + */ + @JsonProperty(value = "fileNameTemplate", required = true) + private String fileNameTemplate; + + /** + * The value indicating whether to suspend message on file name generation + * error. + */ + @JsonProperty(value = "suspendMessageOnFileNameGenerationError", required = true) + private boolean suspendMessageOnFileNameGenerationError; + + /** + * The value indicating whether to auto generate file name. + */ + @JsonProperty(value = "autogenerateFileName", required = true) + private boolean autogenerateFileName; + + /** + * Get the message content type. + * + * @return the messageContentType value + */ + public String messageContentType() { + return this.messageContentType; + } + + /** + * Set the message content type. + * + * @param messageContentType the messageContentType value to set + * @return the AS2EnvelopeSettings object itself. + */ + public AS2EnvelopeSettings withMessageContentType(String messageContentType) { + this.messageContentType = messageContentType; + return this; + } + + /** + * Get the value indicating whether to transmit file name in mime header. + * + * @return the transmitFileNameInMimeHeader value + */ + public boolean transmitFileNameInMimeHeader() { + return this.transmitFileNameInMimeHeader; + } + + /** + * Set the value indicating whether to transmit file name in mime header. + * + * @param transmitFileNameInMimeHeader the transmitFileNameInMimeHeader value to set + * @return the AS2EnvelopeSettings object itself. + */ + public AS2EnvelopeSettings withTransmitFileNameInMimeHeader(boolean transmitFileNameInMimeHeader) { + this.transmitFileNameInMimeHeader = transmitFileNameInMimeHeader; + return this; + } + + /** + * Get the template for file name. + * + * @return the fileNameTemplate value + */ + public String fileNameTemplate() { + return this.fileNameTemplate; + } + + /** + * Set the template for file name. + * + * @param fileNameTemplate the fileNameTemplate value to set + * @return the AS2EnvelopeSettings object itself. + */ + public AS2EnvelopeSettings withFileNameTemplate(String fileNameTemplate) { + this.fileNameTemplate = fileNameTemplate; + return this; + } + + /** + * Get the value indicating whether to suspend message on file name generation error. + * + * @return the suspendMessageOnFileNameGenerationError value + */ + public boolean suspendMessageOnFileNameGenerationError() { + return this.suspendMessageOnFileNameGenerationError; + } + + /** + * Set the value indicating whether to suspend message on file name generation error. + * + * @param suspendMessageOnFileNameGenerationError the suspendMessageOnFileNameGenerationError value to set + * @return the AS2EnvelopeSettings object itself. + */ + public AS2EnvelopeSettings withSuspendMessageOnFileNameGenerationError(boolean suspendMessageOnFileNameGenerationError) { + this.suspendMessageOnFileNameGenerationError = suspendMessageOnFileNameGenerationError; + return this; + } + + /** + * Get the value indicating whether to auto generate file name. + * + * @return the autogenerateFileName value + */ + public boolean autogenerateFileName() { + return this.autogenerateFileName; + } + + /** + * Set the value indicating whether to auto generate file name. + * + * @param autogenerateFileName the autogenerateFileName value to set + * @return the AS2EnvelopeSettings object itself. + */ + public AS2EnvelopeSettings withAutogenerateFileName(boolean autogenerateFileName) { + this.autogenerateFileName = autogenerateFileName; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2ErrorSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2ErrorSettings.java new file mode 100644 index 000000000000..b9af0fc569f8 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2ErrorSettings.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The AS2 agreement error settings. + */ +public class AS2ErrorSettings { + /** + * The value indicating whether to suspend duplicate message. + */ + @JsonProperty(value = "suspendDuplicateMessage", required = true) + private boolean suspendDuplicateMessage; + + /** + * The value indicating whether to resend message If MDN is not received. + */ + @JsonProperty(value = "resendIfMDNNotReceived", required = true) + private boolean resendIfMDNNotReceived; + + /** + * Get the value indicating whether to suspend duplicate message. + * + * @return the suspendDuplicateMessage value + */ + public boolean suspendDuplicateMessage() { + return this.suspendDuplicateMessage; + } + + /** + * Set the value indicating whether to suspend duplicate message. + * + * @param suspendDuplicateMessage the suspendDuplicateMessage value to set + * @return the AS2ErrorSettings object itself. + */ + public AS2ErrorSettings withSuspendDuplicateMessage(boolean suspendDuplicateMessage) { + this.suspendDuplicateMessage = suspendDuplicateMessage; + return this; + } + + /** + * Get the value indicating whether to resend message If MDN is not received. + * + * @return the resendIfMDNNotReceived value + */ + public boolean resendIfMDNNotReceived() { + return this.resendIfMDNNotReceived; + } + + /** + * Set the value indicating whether to resend message If MDN is not received. + * + * @param resendIfMDNNotReceived the resendIfMDNNotReceived value to set + * @return the AS2ErrorSettings object itself. + */ + public AS2ErrorSettings withResendIfMDNNotReceived(boolean resendIfMDNNotReceived) { + this.resendIfMDNNotReceived = resendIfMDNNotReceived; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2MdnSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2MdnSettings.java new file mode 100644 index 000000000000..de38905ae57e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2MdnSettings.java @@ -0,0 +1,252 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The AS2 agreement mdn settings. + */ +public class AS2MdnSettings { + /** + * The value indicating whether to send or request a MDN. + */ + @JsonProperty(value = "needMDN", required = true) + private boolean needMDN; + + /** + * The value indicating whether the MDN needs to be signed or not. + */ + @JsonProperty(value = "signMDN", required = true) + private boolean signMDN; + + /** + * The value indicating whether to send the asynchronous MDN. + */ + @JsonProperty(value = "sendMDNAsynchronously", required = true) + private boolean sendMDNAsynchronously; + + /** + * The receipt delivery URL. + */ + @JsonProperty(value = "receiptDeliveryUrl") + private String receiptDeliveryUrl; + + /** + * The disposition notification to header value. + */ + @JsonProperty(value = "dispositionNotificationTo") + private String dispositionNotificationTo; + + /** + * The value indicating whether to sign the outbound MDN if optional. + */ + @JsonProperty(value = "signOutboundMDNIfOptional", required = true) + private boolean signOutboundMDNIfOptional; + + /** + * The MDN text. + */ + @JsonProperty(value = "mdnText") + private String mdnText; + + /** + * The value indicating whether to send inbound MDN to message box. + */ + @JsonProperty(value = "sendInboundMDNToMessageBox", required = true) + private boolean sendInboundMDNToMessageBox; + + /** + * The signing or hashing algorithm. Possible values include: + * 'NotSpecified', 'None', 'MD5', 'SHA1', 'SHA2256', 'SHA2384', 'SHA2512'. + */ + @JsonProperty(value = "micHashingAlgorithm", required = true) + private HashingAlgorithm micHashingAlgorithm; + + /** + * Get the value indicating whether to send or request a MDN. + * + * @return the needMDN value + */ + public boolean needMDN() { + return this.needMDN; + } + + /** + * Set the value indicating whether to send or request a MDN. + * + * @param needMDN the needMDN value to set + * @return the AS2MdnSettings object itself. + */ + public AS2MdnSettings withNeedMDN(boolean needMDN) { + this.needMDN = needMDN; + return this; + } + + /** + * Get the value indicating whether the MDN needs to be signed or not. + * + * @return the signMDN value + */ + public boolean signMDN() { + return this.signMDN; + } + + /** + * Set the value indicating whether the MDN needs to be signed or not. + * + * @param signMDN the signMDN value to set + * @return the AS2MdnSettings object itself. + */ + public AS2MdnSettings withSignMDN(boolean signMDN) { + this.signMDN = signMDN; + return this; + } + + /** + * Get the value indicating whether to send the asynchronous MDN. + * + * @return the sendMDNAsynchronously value + */ + public boolean sendMDNAsynchronously() { + return this.sendMDNAsynchronously; + } + + /** + * Set the value indicating whether to send the asynchronous MDN. + * + * @param sendMDNAsynchronously the sendMDNAsynchronously value to set + * @return the AS2MdnSettings object itself. + */ + public AS2MdnSettings withSendMDNAsynchronously(boolean sendMDNAsynchronously) { + this.sendMDNAsynchronously = sendMDNAsynchronously; + return this; + } + + /** + * Get the receipt delivery URL. + * + * @return the receiptDeliveryUrl value + */ + public String receiptDeliveryUrl() { + return this.receiptDeliveryUrl; + } + + /** + * Set the receipt delivery URL. + * + * @param receiptDeliveryUrl the receiptDeliveryUrl value to set + * @return the AS2MdnSettings object itself. + */ + public AS2MdnSettings withReceiptDeliveryUrl(String receiptDeliveryUrl) { + this.receiptDeliveryUrl = receiptDeliveryUrl; + return this; + } + + /** + * Get the disposition notification to header value. + * + * @return the dispositionNotificationTo value + */ + public String dispositionNotificationTo() { + return this.dispositionNotificationTo; + } + + /** + * Set the disposition notification to header value. + * + * @param dispositionNotificationTo the dispositionNotificationTo value to set + * @return the AS2MdnSettings object itself. + */ + public AS2MdnSettings withDispositionNotificationTo(String dispositionNotificationTo) { + this.dispositionNotificationTo = dispositionNotificationTo; + return this; + } + + /** + * Get the value indicating whether to sign the outbound MDN if optional. + * + * @return the signOutboundMDNIfOptional value + */ + public boolean signOutboundMDNIfOptional() { + return this.signOutboundMDNIfOptional; + } + + /** + * Set the value indicating whether to sign the outbound MDN if optional. + * + * @param signOutboundMDNIfOptional the signOutboundMDNIfOptional value to set + * @return the AS2MdnSettings object itself. + */ + public AS2MdnSettings withSignOutboundMDNIfOptional(boolean signOutboundMDNIfOptional) { + this.signOutboundMDNIfOptional = signOutboundMDNIfOptional; + return this; + } + + /** + * Get the MDN text. + * + * @return the mdnText value + */ + public String mdnText() { + return this.mdnText; + } + + /** + * Set the MDN text. + * + * @param mdnText the mdnText value to set + * @return the AS2MdnSettings object itself. + */ + public AS2MdnSettings withMdnText(String mdnText) { + this.mdnText = mdnText; + return this; + } + + /** + * Get the value indicating whether to send inbound MDN to message box. + * + * @return the sendInboundMDNToMessageBox value + */ + public boolean sendInboundMDNToMessageBox() { + return this.sendInboundMDNToMessageBox; + } + + /** + * Set the value indicating whether to send inbound MDN to message box. + * + * @param sendInboundMDNToMessageBox the sendInboundMDNToMessageBox value to set + * @return the AS2MdnSettings object itself. + */ + public AS2MdnSettings withSendInboundMDNToMessageBox(boolean sendInboundMDNToMessageBox) { + this.sendInboundMDNToMessageBox = sendInboundMDNToMessageBox; + return this; + } + + /** + * Get the signing or hashing algorithm. Possible values include: 'NotSpecified', 'None', 'MD5', 'SHA1', 'SHA2256', 'SHA2384', 'SHA2512'. + * + * @return the micHashingAlgorithm value + */ + public HashingAlgorithm micHashingAlgorithm() { + return this.micHashingAlgorithm; + } + + /** + * Set the signing or hashing algorithm. Possible values include: 'NotSpecified', 'None', 'MD5', 'SHA1', 'SHA2256', 'SHA2384', 'SHA2512'. + * + * @param micHashingAlgorithm the micHashingAlgorithm value to set + * @return the AS2MdnSettings object itself. + */ + public AS2MdnSettings withMicHashingAlgorithm(HashingAlgorithm micHashingAlgorithm) { + this.micHashingAlgorithm = micHashingAlgorithm; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2MessageConnectionSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2MessageConnectionSettings.java new file mode 100644 index 000000000000..382843affe12 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2MessageConnectionSettings.java @@ -0,0 +1,121 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The AS2 agreement message connection settings. + */ +public class AS2MessageConnectionSettings { + /** + * The value indicating whether to ignore mismatch in certificate name. + */ + @JsonProperty(value = "ignoreCertificateNameMismatch", required = true) + private boolean ignoreCertificateNameMismatch; + + /** + * The value indicating whether to support HTTP status code 'CONTINUE'. + */ + @JsonProperty(value = "supportHttpStatusCodeContinue", required = true) + private boolean supportHttpStatusCodeContinue; + + /** + * The value indicating whether to keep the connection alive. + */ + @JsonProperty(value = "keepHttpConnectionAlive", required = true) + private boolean keepHttpConnectionAlive; + + /** + * The value indicating whether to unfold the HTTP headers. + */ + @JsonProperty(value = "unfoldHttpHeaders", required = true) + private boolean unfoldHttpHeaders; + + /** + * Get the value indicating whether to ignore mismatch in certificate name. + * + * @return the ignoreCertificateNameMismatch value + */ + public boolean ignoreCertificateNameMismatch() { + return this.ignoreCertificateNameMismatch; + } + + /** + * Set the value indicating whether to ignore mismatch in certificate name. + * + * @param ignoreCertificateNameMismatch the ignoreCertificateNameMismatch value to set + * @return the AS2MessageConnectionSettings object itself. + */ + public AS2MessageConnectionSettings withIgnoreCertificateNameMismatch(boolean ignoreCertificateNameMismatch) { + this.ignoreCertificateNameMismatch = ignoreCertificateNameMismatch; + return this; + } + + /** + * Get the value indicating whether to support HTTP status code 'CONTINUE'. + * + * @return the supportHttpStatusCodeContinue value + */ + public boolean supportHttpStatusCodeContinue() { + return this.supportHttpStatusCodeContinue; + } + + /** + * Set the value indicating whether to support HTTP status code 'CONTINUE'. + * + * @param supportHttpStatusCodeContinue the supportHttpStatusCodeContinue value to set + * @return the AS2MessageConnectionSettings object itself. + */ + public AS2MessageConnectionSettings withSupportHttpStatusCodeContinue(boolean supportHttpStatusCodeContinue) { + this.supportHttpStatusCodeContinue = supportHttpStatusCodeContinue; + return this; + } + + /** + * Get the value indicating whether to keep the connection alive. + * + * @return the keepHttpConnectionAlive value + */ + public boolean keepHttpConnectionAlive() { + return this.keepHttpConnectionAlive; + } + + /** + * Set the value indicating whether to keep the connection alive. + * + * @param keepHttpConnectionAlive the keepHttpConnectionAlive value to set + * @return the AS2MessageConnectionSettings object itself. + */ + public AS2MessageConnectionSettings withKeepHttpConnectionAlive(boolean keepHttpConnectionAlive) { + this.keepHttpConnectionAlive = keepHttpConnectionAlive; + return this; + } + + /** + * Get the value indicating whether to unfold the HTTP headers. + * + * @return the unfoldHttpHeaders value + */ + public boolean unfoldHttpHeaders() { + return this.unfoldHttpHeaders; + } + + /** + * Set the value indicating whether to unfold the HTTP headers. + * + * @param unfoldHttpHeaders the unfoldHttpHeaders value to set + * @return the AS2MessageConnectionSettings object itself. + */ + public AS2MessageConnectionSettings withUnfoldHttpHeaders(boolean unfoldHttpHeaders) { + this.unfoldHttpHeaders = unfoldHttpHeaders; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2OneWayAgreement.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2OneWayAgreement.java new file mode 100644 index 000000000000..93dcd5e9f0a1 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2OneWayAgreement.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration account AS2 one-way agreement. + */ +public class AS2OneWayAgreement { + /** + * The sender business identity. + */ + @JsonProperty(value = "senderBusinessIdentity", required = true) + private BusinessIdentity senderBusinessIdentity; + + /** + * The receiver business identity. + */ + @JsonProperty(value = "receiverBusinessIdentity", required = true) + private BusinessIdentity receiverBusinessIdentity; + + /** + * The AS2 protocol settings. + */ + @JsonProperty(value = "protocolSettings", required = true) + private AS2ProtocolSettings protocolSettings; + + /** + * Get the sender business identity. + * + * @return the senderBusinessIdentity value + */ + public BusinessIdentity senderBusinessIdentity() { + return this.senderBusinessIdentity; + } + + /** + * Set the sender business identity. + * + * @param senderBusinessIdentity the senderBusinessIdentity value to set + * @return the AS2OneWayAgreement object itself. + */ + public AS2OneWayAgreement withSenderBusinessIdentity(BusinessIdentity senderBusinessIdentity) { + this.senderBusinessIdentity = senderBusinessIdentity; + return this; + } + + /** + * Get the receiver business identity. + * + * @return the receiverBusinessIdentity value + */ + public BusinessIdentity receiverBusinessIdentity() { + return this.receiverBusinessIdentity; + } + + /** + * Set the receiver business identity. + * + * @param receiverBusinessIdentity the receiverBusinessIdentity value to set + * @return the AS2OneWayAgreement object itself. + */ + public AS2OneWayAgreement withReceiverBusinessIdentity(BusinessIdentity receiverBusinessIdentity) { + this.receiverBusinessIdentity = receiverBusinessIdentity; + return this; + } + + /** + * Get the AS2 protocol settings. + * + * @return the protocolSettings value + */ + public AS2ProtocolSettings protocolSettings() { + return this.protocolSettings; + } + + /** + * Set the AS2 protocol settings. + * + * @param protocolSettings the protocolSettings value to set + * @return the AS2OneWayAgreement object itself. + */ + public AS2OneWayAgreement withProtocolSettings(AS2ProtocolSettings protocolSettings) { + this.protocolSettings = protocolSettings; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2ProtocolSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2ProtocolSettings.java new file mode 100644 index 000000000000..c29bc833ff9b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2ProtocolSettings.java @@ -0,0 +1,199 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The AS2 agreement protocol settings. + */ +public class AS2ProtocolSettings { + /** + * The message connection settings. + */ + @JsonProperty(value = "messageConnectionSettings", required = true) + private AS2MessageConnectionSettings messageConnectionSettings; + + /** + * The acknowledgement connection settings. + */ + @JsonProperty(value = "acknowledgementConnectionSettings", required = true) + private AS2AcknowledgementConnectionSettings acknowledgementConnectionSettings; + + /** + * The MDN settings. + */ + @JsonProperty(value = "mdnSettings", required = true) + private AS2MdnSettings mdnSettings; + + /** + * The security settings. + */ + @JsonProperty(value = "securitySettings", required = true) + private AS2SecuritySettings securitySettings; + + /** + * The validation settings. + */ + @JsonProperty(value = "validationSettings", required = true) + private AS2ValidationSettings validationSettings; + + /** + * The envelope settings. + */ + @JsonProperty(value = "envelopeSettings", required = true) + private AS2EnvelopeSettings envelopeSettings; + + /** + * The error settings. + */ + @JsonProperty(value = "errorSettings", required = true) + private AS2ErrorSettings errorSettings; + + /** + * Get the message connection settings. + * + * @return the messageConnectionSettings value + */ + public AS2MessageConnectionSettings messageConnectionSettings() { + return this.messageConnectionSettings; + } + + /** + * Set the message connection settings. + * + * @param messageConnectionSettings the messageConnectionSettings value to set + * @return the AS2ProtocolSettings object itself. + */ + public AS2ProtocolSettings withMessageConnectionSettings(AS2MessageConnectionSettings messageConnectionSettings) { + this.messageConnectionSettings = messageConnectionSettings; + return this; + } + + /** + * Get the acknowledgement connection settings. + * + * @return the acknowledgementConnectionSettings value + */ + public AS2AcknowledgementConnectionSettings acknowledgementConnectionSettings() { + return this.acknowledgementConnectionSettings; + } + + /** + * Set the acknowledgement connection settings. + * + * @param acknowledgementConnectionSettings the acknowledgementConnectionSettings value to set + * @return the AS2ProtocolSettings object itself. + */ + public AS2ProtocolSettings withAcknowledgementConnectionSettings(AS2AcknowledgementConnectionSettings acknowledgementConnectionSettings) { + this.acknowledgementConnectionSettings = acknowledgementConnectionSettings; + return this; + } + + /** + * Get the MDN settings. + * + * @return the mdnSettings value + */ + public AS2MdnSettings mdnSettings() { + return this.mdnSettings; + } + + /** + * Set the MDN settings. + * + * @param mdnSettings the mdnSettings value to set + * @return the AS2ProtocolSettings object itself. + */ + public AS2ProtocolSettings withMdnSettings(AS2MdnSettings mdnSettings) { + this.mdnSettings = mdnSettings; + return this; + } + + /** + * Get the security settings. + * + * @return the securitySettings value + */ + public AS2SecuritySettings securitySettings() { + return this.securitySettings; + } + + /** + * Set the security settings. + * + * @param securitySettings the securitySettings value to set + * @return the AS2ProtocolSettings object itself. + */ + public AS2ProtocolSettings withSecuritySettings(AS2SecuritySettings securitySettings) { + this.securitySettings = securitySettings; + return this; + } + + /** + * Get the validation settings. + * + * @return the validationSettings value + */ + public AS2ValidationSettings validationSettings() { + return this.validationSettings; + } + + /** + * Set the validation settings. + * + * @param validationSettings the validationSettings value to set + * @return the AS2ProtocolSettings object itself. + */ + public AS2ProtocolSettings withValidationSettings(AS2ValidationSettings validationSettings) { + this.validationSettings = validationSettings; + return this; + } + + /** + * Get the envelope settings. + * + * @return the envelopeSettings value + */ + public AS2EnvelopeSettings envelopeSettings() { + return this.envelopeSettings; + } + + /** + * Set the envelope settings. + * + * @param envelopeSettings the envelopeSettings value to set + * @return the AS2ProtocolSettings object itself. + */ + public AS2ProtocolSettings withEnvelopeSettings(AS2EnvelopeSettings envelopeSettings) { + this.envelopeSettings = envelopeSettings; + return this; + } + + /** + * Get the error settings. + * + * @return the errorSettings value + */ + public AS2ErrorSettings errorSettings() { + return this.errorSettings; + } + + /** + * Set the error settings. + * + * @param errorSettings the errorSettings value to set + * @return the AS2ProtocolSettings object itself. + */ + public AS2ProtocolSettings withErrorSettings(AS2ErrorSettings errorSettings) { + this.errorSettings = errorSettings; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2SecuritySettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2SecuritySettings.java new file mode 100644 index 000000000000..5a2da47ced6f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2SecuritySettings.java @@ -0,0 +1,280 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The AS2 agreement security settings. + */ +public class AS2SecuritySettings { + /** + * The value indicating whether to send or request a MDN. + */ + @JsonProperty(value = "overrideGroupSigningCertificate", required = true) + private boolean overrideGroupSigningCertificate; + + /** + * The name of the signing certificate. + */ + @JsonProperty(value = "signingCertificateName") + private String signingCertificateName; + + /** + * The name of the encryption certificate. + */ + @JsonProperty(value = "encryptionCertificateName") + private String encryptionCertificateName; + + /** + * The value indicating whether to enable NRR for inbound encoded messages. + */ + @JsonProperty(value = "enableNRRForInboundEncodedMessages", required = true) + private boolean enableNRRForInboundEncodedMessages; + + /** + * The value indicating whether to enable NRR for inbound decoded messages. + */ + @JsonProperty(value = "enableNRRForInboundDecodedMessages", required = true) + private boolean enableNRRForInboundDecodedMessages; + + /** + * The value indicating whether to enable NRR for outbound MDN. + */ + @JsonProperty(value = "enableNRRForOutboundMDN", required = true) + private boolean enableNRRForOutboundMDN; + + /** + * The value indicating whether to enable NRR for outbound encoded + * messages. + */ + @JsonProperty(value = "enableNRRForOutboundEncodedMessages", required = true) + private boolean enableNRRForOutboundEncodedMessages; + + /** + * The value indicating whether to enable NRR for outbound decoded + * messages. + */ + @JsonProperty(value = "enableNRRForOutboundDecodedMessages", required = true) + private boolean enableNRRForOutboundDecodedMessages; + + /** + * The value indicating whether to enable NRR for inbound MDN. + */ + @JsonProperty(value = "enableNRRForInboundMDN", required = true) + private boolean enableNRRForInboundMDN; + + /** + * The Sha2 algorithm format. Valid values are Sha2, ShaHashSize, + * ShaHyphenHashSize, Sha2UnderscoreHashSize. + */ + @JsonProperty(value = "sha2AlgorithmFormat") + private String sha2AlgorithmFormat; + + /** + * Get the value indicating whether to send or request a MDN. + * + * @return the overrideGroupSigningCertificate value + */ + public boolean overrideGroupSigningCertificate() { + return this.overrideGroupSigningCertificate; + } + + /** + * Set the value indicating whether to send or request a MDN. + * + * @param overrideGroupSigningCertificate the overrideGroupSigningCertificate value to set + * @return the AS2SecuritySettings object itself. + */ + public AS2SecuritySettings withOverrideGroupSigningCertificate(boolean overrideGroupSigningCertificate) { + this.overrideGroupSigningCertificate = overrideGroupSigningCertificate; + return this; + } + + /** + * Get the name of the signing certificate. + * + * @return the signingCertificateName value + */ + public String signingCertificateName() { + return this.signingCertificateName; + } + + /** + * Set the name of the signing certificate. + * + * @param signingCertificateName the signingCertificateName value to set + * @return the AS2SecuritySettings object itself. + */ + public AS2SecuritySettings withSigningCertificateName(String signingCertificateName) { + this.signingCertificateName = signingCertificateName; + return this; + } + + /** + * Get the name of the encryption certificate. + * + * @return the encryptionCertificateName value + */ + public String encryptionCertificateName() { + return this.encryptionCertificateName; + } + + /** + * Set the name of the encryption certificate. + * + * @param encryptionCertificateName the encryptionCertificateName value to set + * @return the AS2SecuritySettings object itself. + */ + public AS2SecuritySettings withEncryptionCertificateName(String encryptionCertificateName) { + this.encryptionCertificateName = encryptionCertificateName; + return this; + } + + /** + * Get the value indicating whether to enable NRR for inbound encoded messages. + * + * @return the enableNRRForInboundEncodedMessages value + */ + public boolean enableNRRForInboundEncodedMessages() { + return this.enableNRRForInboundEncodedMessages; + } + + /** + * Set the value indicating whether to enable NRR for inbound encoded messages. + * + * @param enableNRRForInboundEncodedMessages the enableNRRForInboundEncodedMessages value to set + * @return the AS2SecuritySettings object itself. + */ + public AS2SecuritySettings withEnableNRRForInboundEncodedMessages(boolean enableNRRForInboundEncodedMessages) { + this.enableNRRForInboundEncodedMessages = enableNRRForInboundEncodedMessages; + return this; + } + + /** + * Get the value indicating whether to enable NRR for inbound decoded messages. + * + * @return the enableNRRForInboundDecodedMessages value + */ + public boolean enableNRRForInboundDecodedMessages() { + return this.enableNRRForInboundDecodedMessages; + } + + /** + * Set the value indicating whether to enable NRR for inbound decoded messages. + * + * @param enableNRRForInboundDecodedMessages the enableNRRForInboundDecodedMessages value to set + * @return the AS2SecuritySettings object itself. + */ + public AS2SecuritySettings withEnableNRRForInboundDecodedMessages(boolean enableNRRForInboundDecodedMessages) { + this.enableNRRForInboundDecodedMessages = enableNRRForInboundDecodedMessages; + return this; + } + + /** + * Get the value indicating whether to enable NRR for outbound MDN. + * + * @return the enableNRRForOutboundMDN value + */ + public boolean enableNRRForOutboundMDN() { + return this.enableNRRForOutboundMDN; + } + + /** + * Set the value indicating whether to enable NRR for outbound MDN. + * + * @param enableNRRForOutboundMDN the enableNRRForOutboundMDN value to set + * @return the AS2SecuritySettings object itself. + */ + public AS2SecuritySettings withEnableNRRForOutboundMDN(boolean enableNRRForOutboundMDN) { + this.enableNRRForOutboundMDN = enableNRRForOutboundMDN; + return this; + } + + /** + * Get the value indicating whether to enable NRR for outbound encoded messages. + * + * @return the enableNRRForOutboundEncodedMessages value + */ + public boolean enableNRRForOutboundEncodedMessages() { + return this.enableNRRForOutboundEncodedMessages; + } + + /** + * Set the value indicating whether to enable NRR for outbound encoded messages. + * + * @param enableNRRForOutboundEncodedMessages the enableNRRForOutboundEncodedMessages value to set + * @return the AS2SecuritySettings object itself. + */ + public AS2SecuritySettings withEnableNRRForOutboundEncodedMessages(boolean enableNRRForOutboundEncodedMessages) { + this.enableNRRForOutboundEncodedMessages = enableNRRForOutboundEncodedMessages; + return this; + } + + /** + * Get the value indicating whether to enable NRR for outbound decoded messages. + * + * @return the enableNRRForOutboundDecodedMessages value + */ + public boolean enableNRRForOutboundDecodedMessages() { + return this.enableNRRForOutboundDecodedMessages; + } + + /** + * Set the value indicating whether to enable NRR for outbound decoded messages. + * + * @param enableNRRForOutboundDecodedMessages the enableNRRForOutboundDecodedMessages value to set + * @return the AS2SecuritySettings object itself. + */ + public AS2SecuritySettings withEnableNRRForOutboundDecodedMessages(boolean enableNRRForOutboundDecodedMessages) { + this.enableNRRForOutboundDecodedMessages = enableNRRForOutboundDecodedMessages; + return this; + } + + /** + * Get the value indicating whether to enable NRR for inbound MDN. + * + * @return the enableNRRForInboundMDN value + */ + public boolean enableNRRForInboundMDN() { + return this.enableNRRForInboundMDN; + } + + /** + * Set the value indicating whether to enable NRR for inbound MDN. + * + * @param enableNRRForInboundMDN the enableNRRForInboundMDN value to set + * @return the AS2SecuritySettings object itself. + */ + public AS2SecuritySettings withEnableNRRForInboundMDN(boolean enableNRRForInboundMDN) { + this.enableNRRForInboundMDN = enableNRRForInboundMDN; + return this; + } + + /** + * Get the Sha2 algorithm format. Valid values are Sha2, ShaHashSize, ShaHyphenHashSize, Sha2UnderscoreHashSize. + * + * @return the sha2AlgorithmFormat value + */ + public String sha2AlgorithmFormat() { + return this.sha2AlgorithmFormat; + } + + /** + * Set the Sha2 algorithm format. Valid values are Sha2, ShaHashSize, ShaHyphenHashSize, Sha2UnderscoreHashSize. + * + * @param sha2AlgorithmFormat the sha2AlgorithmFormat value to set + * @return the AS2SecuritySettings object itself. + */ + public AS2SecuritySettings withSha2AlgorithmFormat(String sha2AlgorithmFormat) { + this.sha2AlgorithmFormat = sha2AlgorithmFormat; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2ValidationSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2ValidationSettings.java new file mode 100644 index 000000000000..86dafac17bce --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AS2ValidationSettings.java @@ -0,0 +1,282 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The AS2 agreement validation settings. + */ +public class AS2ValidationSettings { + /** + * The value indicating whether to override incoming message properties + * with those in agreement. + */ + @JsonProperty(value = "overrideMessageProperties", required = true) + private boolean overrideMessageProperties; + + /** + * The value indicating whether the message has to be encrypted. + */ + @JsonProperty(value = "encryptMessage", required = true) + private boolean encryptMessage; + + /** + * The value indicating whether the message has to be signed. + */ + @JsonProperty(value = "signMessage", required = true) + private boolean signMessage; + + /** + * The value indicating whether the message has to be compressed. + */ + @JsonProperty(value = "compressMessage", required = true) + private boolean compressMessage; + + /** + * The value indicating whether to check for duplicate message. + */ + @JsonProperty(value = "checkDuplicateMessage", required = true) + private boolean checkDuplicateMessage; + + /** + * The number of days to look back for duplicate interchange. + */ + @JsonProperty(value = "interchangeDuplicatesValidityDays", required = true) + private int interchangeDuplicatesValidityDays; + + /** + * The value indicating whether to check for certificate revocation list on + * send. + */ + @JsonProperty(value = "checkCertificateRevocationListOnSend", required = true) + private boolean checkCertificateRevocationListOnSend; + + /** + * The value indicating whether to check for certificate revocation list on + * receive. + */ + @JsonProperty(value = "checkCertificateRevocationListOnReceive", required = true) + private boolean checkCertificateRevocationListOnReceive; + + /** + * The encryption algorithm. Possible values include: 'NotSpecified', + * 'None', 'DES3', 'RC2', 'AES128', 'AES192', 'AES256'. + */ + @JsonProperty(value = "encryptionAlgorithm", required = true) + private EncryptionAlgorithm encryptionAlgorithm; + + /** + * The signing algorithm. Possible values include: 'NotSpecified', + * 'Default', 'SHA1', 'SHA2256', 'SHA2384', 'SHA2512'. + */ + @JsonProperty(value = "signingAlgorithm") + private SigningAlgorithm signingAlgorithm; + + /** + * Get the value indicating whether to override incoming message properties with those in agreement. + * + * @return the overrideMessageProperties value + */ + public boolean overrideMessageProperties() { + return this.overrideMessageProperties; + } + + /** + * Set the value indicating whether to override incoming message properties with those in agreement. + * + * @param overrideMessageProperties the overrideMessageProperties value to set + * @return the AS2ValidationSettings object itself. + */ + public AS2ValidationSettings withOverrideMessageProperties(boolean overrideMessageProperties) { + this.overrideMessageProperties = overrideMessageProperties; + return this; + } + + /** + * Get the value indicating whether the message has to be encrypted. + * + * @return the encryptMessage value + */ + public boolean encryptMessage() { + return this.encryptMessage; + } + + /** + * Set the value indicating whether the message has to be encrypted. + * + * @param encryptMessage the encryptMessage value to set + * @return the AS2ValidationSettings object itself. + */ + public AS2ValidationSettings withEncryptMessage(boolean encryptMessage) { + this.encryptMessage = encryptMessage; + return this; + } + + /** + * Get the value indicating whether the message has to be signed. + * + * @return the signMessage value + */ + public boolean signMessage() { + return this.signMessage; + } + + /** + * Set the value indicating whether the message has to be signed. + * + * @param signMessage the signMessage value to set + * @return the AS2ValidationSettings object itself. + */ + public AS2ValidationSettings withSignMessage(boolean signMessage) { + this.signMessage = signMessage; + return this; + } + + /** + * Get the value indicating whether the message has to be compressed. + * + * @return the compressMessage value + */ + public boolean compressMessage() { + return this.compressMessage; + } + + /** + * Set the value indicating whether the message has to be compressed. + * + * @param compressMessage the compressMessage value to set + * @return the AS2ValidationSettings object itself. + */ + public AS2ValidationSettings withCompressMessage(boolean compressMessage) { + this.compressMessage = compressMessage; + return this; + } + + /** + * Get the value indicating whether to check for duplicate message. + * + * @return the checkDuplicateMessage value + */ + public boolean checkDuplicateMessage() { + return this.checkDuplicateMessage; + } + + /** + * Set the value indicating whether to check for duplicate message. + * + * @param checkDuplicateMessage the checkDuplicateMessage value to set + * @return the AS2ValidationSettings object itself. + */ + public AS2ValidationSettings withCheckDuplicateMessage(boolean checkDuplicateMessage) { + this.checkDuplicateMessage = checkDuplicateMessage; + return this; + } + + /** + * Get the number of days to look back for duplicate interchange. + * + * @return the interchangeDuplicatesValidityDays value + */ + public int interchangeDuplicatesValidityDays() { + return this.interchangeDuplicatesValidityDays; + } + + /** + * Set the number of days to look back for duplicate interchange. + * + * @param interchangeDuplicatesValidityDays the interchangeDuplicatesValidityDays value to set + * @return the AS2ValidationSettings object itself. + */ + public AS2ValidationSettings withInterchangeDuplicatesValidityDays(int interchangeDuplicatesValidityDays) { + this.interchangeDuplicatesValidityDays = interchangeDuplicatesValidityDays; + return this; + } + + /** + * Get the value indicating whether to check for certificate revocation list on send. + * + * @return the checkCertificateRevocationListOnSend value + */ + public boolean checkCertificateRevocationListOnSend() { + return this.checkCertificateRevocationListOnSend; + } + + /** + * Set the value indicating whether to check for certificate revocation list on send. + * + * @param checkCertificateRevocationListOnSend the checkCertificateRevocationListOnSend value to set + * @return the AS2ValidationSettings object itself. + */ + public AS2ValidationSettings withCheckCertificateRevocationListOnSend(boolean checkCertificateRevocationListOnSend) { + this.checkCertificateRevocationListOnSend = checkCertificateRevocationListOnSend; + return this; + } + + /** + * Get the value indicating whether to check for certificate revocation list on receive. + * + * @return the checkCertificateRevocationListOnReceive value + */ + public boolean checkCertificateRevocationListOnReceive() { + return this.checkCertificateRevocationListOnReceive; + } + + /** + * Set the value indicating whether to check for certificate revocation list on receive. + * + * @param checkCertificateRevocationListOnReceive the checkCertificateRevocationListOnReceive value to set + * @return the AS2ValidationSettings object itself. + */ + public AS2ValidationSettings withCheckCertificateRevocationListOnReceive(boolean checkCertificateRevocationListOnReceive) { + this.checkCertificateRevocationListOnReceive = checkCertificateRevocationListOnReceive; + return this; + } + + /** + * Get the encryption algorithm. Possible values include: 'NotSpecified', 'None', 'DES3', 'RC2', 'AES128', 'AES192', 'AES256'. + * + * @return the encryptionAlgorithm value + */ + public EncryptionAlgorithm encryptionAlgorithm() { + return this.encryptionAlgorithm; + } + + /** + * Set the encryption algorithm. Possible values include: 'NotSpecified', 'None', 'DES3', 'RC2', 'AES128', 'AES192', 'AES256'. + * + * @param encryptionAlgorithm the encryptionAlgorithm value to set + * @return the AS2ValidationSettings object itself. + */ + public AS2ValidationSettings withEncryptionAlgorithm(EncryptionAlgorithm encryptionAlgorithm) { + this.encryptionAlgorithm = encryptionAlgorithm; + return this; + } + + /** + * Get the signing algorithm. Possible values include: 'NotSpecified', 'Default', 'SHA1', 'SHA2256', 'SHA2384', 'SHA2512'. + * + * @return the signingAlgorithm value + */ + public SigningAlgorithm signingAlgorithm() { + return this.signingAlgorithm; + } + + /** + * Set the signing algorithm. Possible values include: 'NotSpecified', 'Default', 'SHA1', 'SHA2256', 'SHA2384', 'SHA2512'. + * + * @param signingAlgorithm the signingAlgorithm value to set + * @return the AS2ValidationSettings object itself. + */ + public AS2ValidationSettings withSigningAlgorithm(SigningAlgorithm signingAlgorithm) { + this.signingAlgorithm = signingAlgorithm; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ActionRunWorkflowRequestHistory.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ActionRunWorkflowRequestHistory.java new file mode 100644 index 000000000000..c9be8c5d062c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ActionRunWorkflowRequestHistory.java @@ -0,0 +1,53 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.RequestHistoryInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import java.util.Map; + +/** + * Type representing ActionRunWorkflowRequestHistory. + */ +public interface ActionRunWorkflowRequestHistory extends HasInner, Indexable, Refreshable, HasManager { + /** + * @return the id value. + */ + String id(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the properties value. + */ + RequestHistoryProperties properties(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the type value. + */ + String type(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ActionRunWorkflowWorkflowRunActionRepetitionDefinition.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ActionRunWorkflowWorkflowRunActionRepetitionDefinition.java new file mode 100644 index 000000000000..9bd2a9fa216c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ActionRunWorkflowWorkflowRunActionRepetitionDefinition.java @@ -0,0 +1,125 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowRunActionRepetitionDefinitionInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import org.joda.time.DateTime; +import java.util.List; +import java.util.Map; + +/** + * Type representing ActionRunWorkflowWorkflowRunActionRepetitionDefinition. + */ +public interface ActionRunWorkflowWorkflowRunActionRepetitionDefinition extends HasInner, Indexable, Refreshable, HasManager { + /** + * @return the code value. + */ + String code(); + + /** + * @return the correlation value. + */ + RunActionCorrelation correlation(); + + /** + * @return the endTime value. + */ + DateTime endTime(); + + /** + * @return the error value. + */ + Object error(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the inputs value. + */ + Object inputs(); + + /** + * @return the inputsLink value. + */ + ContentLink inputsLink(); + + /** + * @return the iterationCount value. + */ + Integer iterationCount(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the outputs value. + */ + Object outputs(); + + /** + * @return the outputsLink value. + */ + ContentLink outputsLink(); + + /** + * @return the repetitionIndexes value. + */ + List repetitionIndexes(); + + /** + * @return the retryHistory value. + */ + List retryHistory(); + + /** + * @return the startTime value. + */ + DateTime startTime(); + + /** + * @return the status value. + */ + WorkflowStatus status(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the trackedProperties value. + */ + Object trackedProperties(); + + /** + * @return the trackingId value. + */ + String trackingId(); + + /** + * @return the type value. + */ + String type(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel.java new file mode 100644 index 000000000000..9838e9974f09 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel.java @@ -0,0 +1,125 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowRunActionRepetitionDefinitionInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import org.joda.time.DateTime; +import java.util.List; +import java.util.Map; + +/** + * Type representing ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel. + */ +public interface ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel extends HasInner, Indexable, Refreshable, HasManager { + /** + * @return the code value. + */ + String code(); + + /** + * @return the correlation value. + */ + RunActionCorrelation correlation(); + + /** + * @return the endTime value. + */ + DateTime endTime(); + + /** + * @return the error value. + */ + Object error(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the inputs value. + */ + Object inputs(); + + /** + * @return the inputsLink value. + */ + ContentLink inputsLink(); + + /** + * @return the iterationCount value. + */ + Integer iterationCount(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the outputs value. + */ + Object outputs(); + + /** + * @return the outputsLink value. + */ + ContentLink outputsLink(); + + /** + * @return the repetitionIndexes value. + */ + List repetitionIndexes(); + + /** + * @return the retryHistory value. + */ + List retryHistory(); + + /** + * @return the startTime value. + */ + DateTime startTime(); + + /** + * @return the status value. + */ + WorkflowStatus status(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the trackedProperties value. + */ + Object trackedProperties(); + + /** + * @return the trackingId value. + */ + String trackingId(); + + /** + * @return the type value. + */ + String type(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AgreementContent.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AgreementContent.java new file mode 100644 index 000000000000..64974e595297 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AgreementContent.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration account agreement content. + */ +public class AgreementContent { + /** + * The AS2 agreement content. + */ + @JsonProperty(value = "aS2") + private AS2AgreementContent aS2; + + /** + * The X12 agreement content. + */ + @JsonProperty(value = "x12") + private X12AgreementContent x12; + + /** + * The EDIFACT agreement content. + */ + @JsonProperty(value = "edifact") + private EdifactAgreementContent edifact; + + /** + * Get the AS2 agreement content. + * + * @return the aS2 value + */ + public AS2AgreementContent aS2() { + return this.aS2; + } + + /** + * Set the AS2 agreement content. + * + * @param aS2 the aS2 value to set + * @return the AgreementContent object itself. + */ + public AgreementContent withAS2(AS2AgreementContent aS2) { + this.aS2 = aS2; + return this; + } + + /** + * Get the X12 agreement content. + * + * @return the x12 value + */ + public X12AgreementContent x12() { + return this.x12; + } + + /** + * Set the X12 agreement content. + * + * @param x12 the x12 value to set + * @return the AgreementContent object itself. + */ + public AgreementContent withX12(X12AgreementContent x12) { + this.x12 = x12; + return this; + } + + /** + * Get the EDIFACT agreement content. + * + * @return the edifact value + */ + public EdifactAgreementContent edifact() { + return this.edifact; + } + + /** + * Set the EDIFACT agreement content. + * + * @param edifact the edifact value to set + * @return the AgreementContent object itself. + */ + public AgreementContent withEdifact(EdifactAgreementContent edifact) { + this.edifact = edifact; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AgreementType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AgreementType.java new file mode 100644 index 000000000000..bf3227cded35 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AgreementType.java @@ -0,0 +1,59 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +/** + * Defines values for AgreementType. + */ +public enum AgreementType { + /** Enum value NotSpecified. */ + NOT_SPECIFIED("NotSpecified"), + + /** Enum value AS2. */ + AS2("AS2"), + + /** Enum value X12. */ + X12("X12"), + + /** Enum value Edifact. */ + EDIFACT("Edifact"); + + /** The actual serialized value for a AgreementType instance. */ + private String value; + + AgreementType(String value) { + this.value = value; + } + + /** + * Parses a serialized value to a AgreementType instance. + * + * @param value the serialized value to parse. + * @return the parsed AgreementType object, or null if unable to parse. + */ + @JsonCreator + public static AgreementType fromString(String value) { + AgreementType[] items = AgreementType.values(); + for (AgreementType item : items) { + if (item.toString().equalsIgnoreCase(value)) { + return item; + } + } + return null; + } + + @JsonValue + @Override + public String toString() { + return this.value; + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiDeploymentParameterMetadata.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiDeploymentParameterMetadata.java new file mode 100644 index 000000000000..e6a45e534ebf --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiDeploymentParameterMetadata.java @@ -0,0 +1,148 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The API deployment parameter metadata. + */ +public class ApiDeploymentParameterMetadata { + /** + * The type. + */ + @JsonProperty(value = "type") + private String type; + + /** + * Indicates whether its required. + */ + @JsonProperty(value = "isRequired") + private Boolean isRequired; + + /** + * The display name. + */ + @JsonProperty(value = "displayName") + private String displayName; + + /** + * The description. + */ + @JsonProperty(value = "description") + private String description; + + /** + * The visibility. Possible values include: 'NotSpecified', 'Default', + * 'Internal'. + */ + @JsonProperty(value = "visibility") + private ApiDeploymentParameterVisibility visibility; + + /** + * Get the type. + * + * @return the type value + */ + public String type() { + return this.type; + } + + /** + * Set the type. + * + * @param type the type value to set + * @return the ApiDeploymentParameterMetadata object itself. + */ + public ApiDeploymentParameterMetadata withType(String type) { + this.type = type; + return this; + } + + /** + * Get indicates whether its required. + * + * @return the isRequired value + */ + public Boolean isRequired() { + return this.isRequired; + } + + /** + * Set indicates whether its required. + * + * @param isRequired the isRequired value to set + * @return the ApiDeploymentParameterMetadata object itself. + */ + public ApiDeploymentParameterMetadata withIsRequired(Boolean isRequired) { + this.isRequired = isRequired; + return this; + } + + /** + * Get the display name. + * + * @return the displayName value + */ + public String displayName() { + return this.displayName; + } + + /** + * Set the display name. + * + * @param displayName the displayName value to set + * @return the ApiDeploymentParameterMetadata object itself. + */ + public ApiDeploymentParameterMetadata withDisplayName(String displayName) { + this.displayName = displayName; + return this; + } + + /** + * Get the description. + * + * @return the description value + */ + public String description() { + return this.description; + } + + /** + * Set the description. + * + * @param description the description value to set + * @return the ApiDeploymentParameterMetadata object itself. + */ + public ApiDeploymentParameterMetadata withDescription(String description) { + this.description = description; + return this; + } + + /** + * Get the visibility. Possible values include: 'NotSpecified', 'Default', 'Internal'. + * + * @return the visibility value + */ + public ApiDeploymentParameterVisibility visibility() { + return this.visibility; + } + + /** + * Set the visibility. Possible values include: 'NotSpecified', 'Default', 'Internal'. + * + * @param visibility the visibility value to set + * @return the ApiDeploymentParameterMetadata object itself. + */ + public ApiDeploymentParameterMetadata withVisibility(ApiDeploymentParameterVisibility visibility) { + this.visibility = visibility; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiDeploymentParameterMetadataSet.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiDeploymentParameterMetadataSet.java new file mode 100644 index 000000000000..1b76f2e62db7 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiDeploymentParameterMetadataSet.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The API deployment parameters metadata. + */ +public class ApiDeploymentParameterMetadataSet { + /** + * The package content link parameter. + */ + @JsonProperty(value = "packageContentLink") + private ApiDeploymentParameterMetadata packageContentLink; + + /** + * The package content link parameter. + */ + @JsonProperty(value = "redisCacheConnectionString") + private ApiDeploymentParameterMetadata redisCacheConnectionString; + + /** + * Get the package content link parameter. + * + * @return the packageContentLink value + */ + public ApiDeploymentParameterMetadata packageContentLink() { + return this.packageContentLink; + } + + /** + * Set the package content link parameter. + * + * @param packageContentLink the packageContentLink value to set + * @return the ApiDeploymentParameterMetadataSet object itself. + */ + public ApiDeploymentParameterMetadataSet withPackageContentLink(ApiDeploymentParameterMetadata packageContentLink) { + this.packageContentLink = packageContentLink; + return this; + } + + /** + * Get the package content link parameter. + * + * @return the redisCacheConnectionString value + */ + public ApiDeploymentParameterMetadata redisCacheConnectionString() { + return this.redisCacheConnectionString; + } + + /** + * Set the package content link parameter. + * + * @param redisCacheConnectionString the redisCacheConnectionString value to set + * @return the ApiDeploymentParameterMetadataSet object itself. + */ + public ApiDeploymentParameterMetadataSet withRedisCacheConnectionString(ApiDeploymentParameterMetadata redisCacheConnectionString) { + this.redisCacheConnectionString = redisCacheConnectionString; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiDeploymentParameterVisibility.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiDeploymentParameterVisibility.java new file mode 100644 index 000000000000..330cd25d6788 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiDeploymentParameterVisibility.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for ApiDeploymentParameterVisibility. + */ +public final class ApiDeploymentParameterVisibility extends ExpandableStringEnum { + /** Static value NotSpecified for ApiDeploymentParameterVisibility. */ + public static final ApiDeploymentParameterVisibility NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Default for ApiDeploymentParameterVisibility. */ + public static final ApiDeploymentParameterVisibility DEFAULT = fromString("Default"); + + /** Static value Internal for ApiDeploymentParameterVisibility. */ + public static final ApiDeploymentParameterVisibility INTERNAL = fromString("Internal"); + + /** + * Creates or finds a ApiDeploymentParameterVisibility from its string representation. + * @param name a name to look for + * @return the corresponding ApiDeploymentParameterVisibility + */ + @JsonCreator + public static ApiDeploymentParameterVisibility fromString(String name) { + return fromString(name, ApiDeploymentParameterVisibility.class); + } + + /** + * @return known ApiDeploymentParameterVisibility values + */ + public static Collection values() { + return values(ApiDeploymentParameterVisibility.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiOperation.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiOperation.java new file mode 100644 index 000000000000..9e826949d1f1 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiOperation.java @@ -0,0 +1,51 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.ApiOperationInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import java.util.Map; + +/** + * Type representing ApiOperation. + */ +public interface ApiOperation extends HasInner, HasManager { + /** + * @return the id value. + */ + String id(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the properties value. + */ + ApiOperationPropertiesDefinition properties(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the type value. + */ + String type(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiOperationAnnotation.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiOperationAnnotation.java new file mode 100644 index 000000000000..8e81c24b806f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiOperationAnnotation.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Api Operation Annotation. + */ +public class ApiOperationAnnotation { + /** + * Possible values include: 'NotSpecified', 'Preview', 'Production'. + */ + @JsonProperty(value = "status") + private StatusAnnotation status; + + /** + * The family. + */ + @JsonProperty(value = "family") + private String family; + + /** + * The revision. + */ + @JsonProperty(value = "revision") + private Integer revision; + + /** + * Get possible values include: 'NotSpecified', 'Preview', 'Production'. + * + * @return the status value + */ + public StatusAnnotation status() { + return this.status; + } + + /** + * Set possible values include: 'NotSpecified', 'Preview', 'Production'. + * + * @param status the status value to set + * @return the ApiOperationAnnotation object itself. + */ + public ApiOperationAnnotation withStatus(StatusAnnotation status) { + this.status = status; + return this; + } + + /** + * Get the family. + * + * @return the family value + */ + public String family() { + return this.family; + } + + /** + * Set the family. + * + * @param family the family value to set + * @return the ApiOperationAnnotation object itself. + */ + public ApiOperationAnnotation withFamily(String family) { + this.family = family; + return this; + } + + /** + * Get the revision. + * + * @return the revision value + */ + public Integer revision() { + return this.revision; + } + + /** + * Set the revision. + * + * @param revision the revision value to set + * @return the ApiOperationAnnotation object itself. + */ + public ApiOperationAnnotation withRevision(Integer revision) { + this.revision = revision; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiOperationPropertiesDefinition.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiOperationPropertiesDefinition.java new file mode 100644 index 000000000000..fdd364491dd6 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiOperationPropertiesDefinition.java @@ -0,0 +1,330 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The api operations properties. + */ +public class ApiOperationPropertiesDefinition { + /** + * The summary of the api operation. + */ + @JsonProperty(value = "summary") + private String summary; + + /** + * The description of the api operation. + */ + @JsonProperty(value = "description") + private String description; + + /** + * The visibility of the api operation. + */ + @JsonProperty(value = "visibility") + private String visibility; + + /** + * The trigger type of api operation. + */ + @JsonProperty(value = "trigger") + private String trigger; + + /** + * The trigger hint for the api operation. + */ + @JsonProperty(value = "triggerHint") + private String triggerHint; + + /** + * Indicates whether the api operation is pageable. + */ + @JsonProperty(value = "pageable") + private Boolean pageable; + + /** + * The annotation of api operation. + */ + @JsonProperty(value = "annotation") + private ApiOperationAnnotation annotation; + + /** + * The api reference. + */ + @JsonProperty(value = "api") + private ApiReference api; + + /** + * The operation inputs definition schema. + */ + @JsonProperty(value = "inputsDefinition") + private SwaggerSchema inputsDefinition; + + /** + * The operation responses definition schemas. + */ + @JsonProperty(value = "responsesDefinition") + private Map responsesDefinition; + + /** + * Indicates whether the API operation is webhook or not. + */ + @JsonProperty(value = "isWebhook") + private Boolean isWebhook; + + /** + * Indicates whether the API operation is notification or not. + */ + @JsonProperty(value = "isNotification") + private Boolean isNotification; + + /** + * Get the summary of the api operation. + * + * @return the summary value + */ + public String summary() { + return this.summary; + } + + /** + * Set the summary of the api operation. + * + * @param summary the summary value to set + * @return the ApiOperationPropertiesDefinition object itself. + */ + public ApiOperationPropertiesDefinition withSummary(String summary) { + this.summary = summary; + return this; + } + + /** + * Get the description of the api operation. + * + * @return the description value + */ + public String description() { + return this.description; + } + + /** + * Set the description of the api operation. + * + * @param description the description value to set + * @return the ApiOperationPropertiesDefinition object itself. + */ + public ApiOperationPropertiesDefinition withDescription(String description) { + this.description = description; + return this; + } + + /** + * Get the visibility of the api operation. + * + * @return the visibility value + */ + public String visibility() { + return this.visibility; + } + + /** + * Set the visibility of the api operation. + * + * @param visibility the visibility value to set + * @return the ApiOperationPropertiesDefinition object itself. + */ + public ApiOperationPropertiesDefinition withVisibility(String visibility) { + this.visibility = visibility; + return this; + } + + /** + * Get the trigger type of api operation. + * + * @return the trigger value + */ + public String trigger() { + return this.trigger; + } + + /** + * Set the trigger type of api operation. + * + * @param trigger the trigger value to set + * @return the ApiOperationPropertiesDefinition object itself. + */ + public ApiOperationPropertiesDefinition withTrigger(String trigger) { + this.trigger = trigger; + return this; + } + + /** + * Get the trigger hint for the api operation. + * + * @return the triggerHint value + */ + public String triggerHint() { + return this.triggerHint; + } + + /** + * Set the trigger hint for the api operation. + * + * @param triggerHint the triggerHint value to set + * @return the ApiOperationPropertiesDefinition object itself. + */ + public ApiOperationPropertiesDefinition withTriggerHint(String triggerHint) { + this.triggerHint = triggerHint; + return this; + } + + /** + * Get indicates whether the api operation is pageable. + * + * @return the pageable value + */ + public Boolean pageable() { + return this.pageable; + } + + /** + * Set indicates whether the api operation is pageable. + * + * @param pageable the pageable value to set + * @return the ApiOperationPropertiesDefinition object itself. + */ + public ApiOperationPropertiesDefinition withPageable(Boolean pageable) { + this.pageable = pageable; + return this; + } + + /** + * Get the annotation of api operation. + * + * @return the annotation value + */ + public ApiOperationAnnotation annotation() { + return this.annotation; + } + + /** + * Set the annotation of api operation. + * + * @param annotation the annotation value to set + * @return the ApiOperationPropertiesDefinition object itself. + */ + public ApiOperationPropertiesDefinition withAnnotation(ApiOperationAnnotation annotation) { + this.annotation = annotation; + return this; + } + + /** + * Get the api reference. + * + * @return the api value + */ + public ApiReference api() { + return this.api; + } + + /** + * Set the api reference. + * + * @param api the api value to set + * @return the ApiOperationPropertiesDefinition object itself. + */ + public ApiOperationPropertiesDefinition withApi(ApiReference api) { + this.api = api; + return this; + } + + /** + * Get the operation inputs definition schema. + * + * @return the inputsDefinition value + */ + public SwaggerSchema inputsDefinition() { + return this.inputsDefinition; + } + + /** + * Set the operation inputs definition schema. + * + * @param inputsDefinition the inputsDefinition value to set + * @return the ApiOperationPropertiesDefinition object itself. + */ + public ApiOperationPropertiesDefinition withInputsDefinition(SwaggerSchema inputsDefinition) { + this.inputsDefinition = inputsDefinition; + return this; + } + + /** + * Get the operation responses definition schemas. + * + * @return the responsesDefinition value + */ + public Map responsesDefinition() { + return this.responsesDefinition; + } + + /** + * Set the operation responses definition schemas. + * + * @param responsesDefinition the responsesDefinition value to set + * @return the ApiOperationPropertiesDefinition object itself. + */ + public ApiOperationPropertiesDefinition withResponsesDefinition(Map responsesDefinition) { + this.responsesDefinition = responsesDefinition; + return this; + } + + /** + * Get indicates whether the API operation is webhook or not. + * + * @return the isWebhook value + */ + public Boolean isWebhook() { + return this.isWebhook; + } + + /** + * Set indicates whether the API operation is webhook or not. + * + * @param isWebhook the isWebhook value to set + * @return the ApiOperationPropertiesDefinition object itself. + */ + public ApiOperationPropertiesDefinition withIsWebhook(Boolean isWebhook) { + this.isWebhook = isWebhook; + return this; + } + + /** + * Get indicates whether the API operation is notification or not. + * + * @return the isNotification value + */ + public Boolean isNotification() { + return this.isNotification; + } + + /** + * Set indicates whether the API operation is notification or not. + * + * @param isNotification the isNotification value to set + * @return the ApiOperationPropertiesDefinition object itself. + */ + public ApiOperationPropertiesDefinition withIsNotification(Boolean isNotification) { + this.isNotification = isNotification; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiReference.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiReference.java new file mode 100644 index 000000000000..8bc2211c4d5a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiReference.java @@ -0,0 +1,200 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Api reference. + */ +public class ApiReference extends ResourceReference { + /** + * The display name of the api. + */ + @JsonProperty(value = "displayName") + private String displayName; + + /** + * The description of the api. + */ + @JsonProperty(value = "description") + private String description; + + /** + * The icon uri of the api. + */ + @JsonProperty(value = "iconUri") + private String iconUri; + + /** + * The swagger of the api. + */ + @JsonProperty(value = "swagger") + private Object swagger; + + /** + * The brand color of the api. + */ + @JsonProperty(value = "brandColor") + private String brandColor; + + /** + * The tier. Possible values include: 'NotSpecified', 'Enterprise', + * 'Standard', 'Premium'. + */ + @JsonProperty(value = "category") + private ApiTier category; + + /** + * The integration service environment reference. + */ + @JsonProperty(value = "integrationServiceEnvironment") + private ResourceReference integrationServiceEnvironment; + + /** + * Get the display name of the api. + * + * @return the displayName value + */ + public String displayName() { + return this.displayName; + } + + /** + * Set the display name of the api. + * + * @param displayName the displayName value to set + * @return the ApiReference object itself. + */ + public ApiReference withDisplayName(String displayName) { + this.displayName = displayName; + return this; + } + + /** + * Get the description of the api. + * + * @return the description value + */ + public String description() { + return this.description; + } + + /** + * Set the description of the api. + * + * @param description the description value to set + * @return the ApiReference object itself. + */ + public ApiReference withDescription(String description) { + this.description = description; + return this; + } + + /** + * Get the icon uri of the api. + * + * @return the iconUri value + */ + public String iconUri() { + return this.iconUri; + } + + /** + * Set the icon uri of the api. + * + * @param iconUri the iconUri value to set + * @return the ApiReference object itself. + */ + public ApiReference withIconUri(String iconUri) { + this.iconUri = iconUri; + return this; + } + + /** + * Get the swagger of the api. + * + * @return the swagger value + */ + public Object swagger() { + return this.swagger; + } + + /** + * Set the swagger of the api. + * + * @param swagger the swagger value to set + * @return the ApiReference object itself. + */ + public ApiReference withSwagger(Object swagger) { + this.swagger = swagger; + return this; + } + + /** + * Get the brand color of the api. + * + * @return the brandColor value + */ + public String brandColor() { + return this.brandColor; + } + + /** + * Set the brand color of the api. + * + * @param brandColor the brandColor value to set + * @return the ApiReference object itself. + */ + public ApiReference withBrandColor(String brandColor) { + this.brandColor = brandColor; + return this; + } + + /** + * Get the tier. Possible values include: 'NotSpecified', 'Enterprise', 'Standard', 'Premium'. + * + * @return the category value + */ + public ApiTier category() { + return this.category; + } + + /** + * Set the tier. Possible values include: 'NotSpecified', 'Enterprise', 'Standard', 'Premium'. + * + * @param category the category value to set + * @return the ApiReference object itself. + */ + public ApiReference withCategory(ApiTier category) { + this.category = category; + return this; + } + + /** + * Get the integration service environment reference. + * + * @return the integrationServiceEnvironment value + */ + public ResourceReference integrationServiceEnvironment() { + return this.integrationServiceEnvironment; + } + + /** + * Set the integration service environment reference. + * + * @param integrationServiceEnvironment the integrationServiceEnvironment value to set + * @return the ApiReference object itself. + */ + public ApiReference withIntegrationServiceEnvironment(ResourceReference integrationServiceEnvironment) { + this.integrationServiceEnvironment = integrationServiceEnvironment; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceBackendService.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceBackendService.java new file mode 100644 index 000000000000..34cb401c8acd --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceBackendService.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The API backend service. + */ +public class ApiResourceBackendService { + /** + * The service URL. + */ + @JsonProperty(value = "serviceUrl") + private String serviceUrl; + + /** + * Get the service URL. + * + * @return the serviceUrl value + */ + public String serviceUrl() { + return this.serviceUrl; + } + + /** + * Set the service URL. + * + * @param serviceUrl the serviceUrl value to set + * @return the ApiResourceBackendService object itself. + */ + public ApiResourceBackendService withServiceUrl(String serviceUrl) { + this.serviceUrl = serviceUrl; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceDefinitions.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceDefinitions.java new file mode 100644 index 000000000000..dc1100999995 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceDefinitions.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Api resource definition. + */ +public class ApiResourceDefinitions { + /** + * The original swagger url. + */ + @JsonProperty(value = "originalSwaggerUrl") + private String originalSwaggerUrl; + + /** + * The modified swagger url. + */ + @JsonProperty(value = "modifiedSwaggerUrl") + private String modifiedSwaggerUrl; + + /** + * Get the original swagger url. + * + * @return the originalSwaggerUrl value + */ + public String originalSwaggerUrl() { + return this.originalSwaggerUrl; + } + + /** + * Set the original swagger url. + * + * @param originalSwaggerUrl the originalSwaggerUrl value to set + * @return the ApiResourceDefinitions object itself. + */ + public ApiResourceDefinitions withOriginalSwaggerUrl(String originalSwaggerUrl) { + this.originalSwaggerUrl = originalSwaggerUrl; + return this; + } + + /** + * Get the modified swagger url. + * + * @return the modifiedSwaggerUrl value + */ + public String modifiedSwaggerUrl() { + return this.modifiedSwaggerUrl; + } + + /** + * Set the modified swagger url. + * + * @param modifiedSwaggerUrl the modifiedSwaggerUrl value to set + * @return the ApiResourceDefinitions object itself. + */ + public ApiResourceDefinitions withModifiedSwaggerUrl(String modifiedSwaggerUrl) { + this.modifiedSwaggerUrl = modifiedSwaggerUrl; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceGeneralInformation.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceGeneralInformation.java new file mode 100644 index 000000000000..7581cdb5ab31 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceGeneralInformation.java @@ -0,0 +1,174 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The API general information. + */ +public class ApiResourceGeneralInformation { + /** + * The icon url. + */ + @JsonProperty(value = "iconUrl") + private String iconUrl; + + /** + * The display name. + */ + @JsonProperty(value = "displayName") + private String displayName; + + /** + * The description. + */ + @JsonProperty(value = "description") + private String description; + + /** + * The terms of use url. + */ + @JsonProperty(value = "termsOfUseUrl") + private String termsOfUseUrl; + + /** + * The release tag. + */ + @JsonProperty(value = "releaseTag") + private String releaseTag; + + /** + * The tier. Possible values include: 'NotSpecified', 'Enterprise', + * 'Standard', 'Premium'. + */ + @JsonProperty(value = "tier") + private ApiTier tier; + + /** + * Get the icon url. + * + * @return the iconUrl value + */ + public String iconUrl() { + return this.iconUrl; + } + + /** + * Set the icon url. + * + * @param iconUrl the iconUrl value to set + * @return the ApiResourceGeneralInformation object itself. + */ + public ApiResourceGeneralInformation withIconUrl(String iconUrl) { + this.iconUrl = iconUrl; + return this; + } + + /** + * Get the display name. + * + * @return the displayName value + */ + public String displayName() { + return this.displayName; + } + + /** + * Set the display name. + * + * @param displayName the displayName value to set + * @return the ApiResourceGeneralInformation object itself. + */ + public ApiResourceGeneralInformation withDisplayName(String displayName) { + this.displayName = displayName; + return this; + } + + /** + * Get the description. + * + * @return the description value + */ + public String description() { + return this.description; + } + + /** + * Set the description. + * + * @param description the description value to set + * @return the ApiResourceGeneralInformation object itself. + */ + public ApiResourceGeneralInformation withDescription(String description) { + this.description = description; + return this; + } + + /** + * Get the terms of use url. + * + * @return the termsOfUseUrl value + */ + public String termsOfUseUrl() { + return this.termsOfUseUrl; + } + + /** + * Set the terms of use url. + * + * @param termsOfUseUrl the termsOfUseUrl value to set + * @return the ApiResourceGeneralInformation object itself. + */ + public ApiResourceGeneralInformation withTermsOfUseUrl(String termsOfUseUrl) { + this.termsOfUseUrl = termsOfUseUrl; + return this; + } + + /** + * Get the release tag. + * + * @return the releaseTag value + */ + public String releaseTag() { + return this.releaseTag; + } + + /** + * Set the release tag. + * + * @param releaseTag the releaseTag value to set + * @return the ApiResourceGeneralInformation object itself. + */ + public ApiResourceGeneralInformation withReleaseTag(String releaseTag) { + this.releaseTag = releaseTag; + return this; + } + + /** + * Get the tier. Possible values include: 'NotSpecified', 'Enterprise', 'Standard', 'Premium'. + * + * @return the tier value + */ + public ApiTier tier() { + return this.tier; + } + + /** + * Set the tier. Possible values include: 'NotSpecified', 'Enterprise', 'Standard', 'Premium'. + * + * @param tier the tier value to set + * @return the ApiResourceGeneralInformation object itself. + */ + public ApiResourceGeneralInformation withTier(ApiTier tier) { + this.tier = tier; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceMetadata.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceMetadata.java new file mode 100644 index 000000000000..d55ad933dc88 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceMetadata.java @@ -0,0 +1,283 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The api resource metadata. + */ +public class ApiResourceMetadata { + /** + * The source. + */ + @JsonProperty(value = "source") + private String source; + + /** + * The brand color. + */ + @JsonProperty(value = "brandColor") + private String brandColor; + + /** + * The hide key. + */ + @JsonProperty(value = "hideKey") + private String hideKey; + + /** + * The tags. + */ + @JsonProperty(value = "tags") + private Map tags; + + /** + * The api type. Possible values include: 'NotSpecified', 'Rest', 'Soap'. + */ + @JsonProperty(value = "ApiType") + private ApiType apiType; + + /** + * The WSDL service. + */ + @JsonProperty(value = "wsdlService") + private WsdlService wsdlService; + + /** + * The WSDL import method. Possible values include: 'NotSpecified', + * 'SoapToRest', 'SoapPassThrough'. + */ + @JsonProperty(value = "wsdlImportMethod") + private WsdlImportMethod wsdlImportMethod; + + /** + * The connection type. + */ + @JsonProperty(value = "connectionType") + private String connectionType; + + /** + * The provisioning state. Possible values include: 'NotSpecified', + * 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', + * 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', + * 'Registering', 'Registered', 'Unregistering', 'Unregistered', + * 'Completed', 'Renewing', 'Pending', 'Waiting', 'InProgress'. + */ + @JsonProperty(value = "provisioningState") + private WorkflowProvisioningState provisioningState; + + /** + * The connector deployment parameters metadata. + */ + @JsonProperty(value = "deploymentParameters") + private ApiDeploymentParameterMetadataSet deploymentParameters; + + /** + * Get the source. + * + * @return the source value + */ + public String source() { + return this.source; + } + + /** + * Set the source. + * + * @param source the source value to set + * @return the ApiResourceMetadata object itself. + */ + public ApiResourceMetadata withSource(String source) { + this.source = source; + return this; + } + + /** + * Get the brand color. + * + * @return the brandColor value + */ + public String brandColor() { + return this.brandColor; + } + + /** + * Set the brand color. + * + * @param brandColor the brandColor value to set + * @return the ApiResourceMetadata object itself. + */ + public ApiResourceMetadata withBrandColor(String brandColor) { + this.brandColor = brandColor; + return this; + } + + /** + * Get the hide key. + * + * @return the hideKey value + */ + public String hideKey() { + return this.hideKey; + } + + /** + * Set the hide key. + * + * @param hideKey the hideKey value to set + * @return the ApiResourceMetadata object itself. + */ + public ApiResourceMetadata withHideKey(String hideKey) { + this.hideKey = hideKey; + return this; + } + + /** + * Get the tags. + * + * @return the tags value + */ + public Map tags() { + return this.tags; + } + + /** + * Set the tags. + * + * @param tags the tags value to set + * @return the ApiResourceMetadata object itself. + */ + public ApiResourceMetadata withTags(Map tags) { + this.tags = tags; + return this; + } + + /** + * Get the api type. Possible values include: 'NotSpecified', 'Rest', 'Soap'. + * + * @return the apiType value + */ + public ApiType apiType() { + return this.apiType; + } + + /** + * Set the api type. Possible values include: 'NotSpecified', 'Rest', 'Soap'. + * + * @param apiType the apiType value to set + * @return the ApiResourceMetadata object itself. + */ + public ApiResourceMetadata withApiType(ApiType apiType) { + this.apiType = apiType; + return this; + } + + /** + * Get the WSDL service. + * + * @return the wsdlService value + */ + public WsdlService wsdlService() { + return this.wsdlService; + } + + /** + * Set the WSDL service. + * + * @param wsdlService the wsdlService value to set + * @return the ApiResourceMetadata object itself. + */ + public ApiResourceMetadata withWsdlService(WsdlService wsdlService) { + this.wsdlService = wsdlService; + return this; + } + + /** + * Get the WSDL import method. Possible values include: 'NotSpecified', 'SoapToRest', 'SoapPassThrough'. + * + * @return the wsdlImportMethod value + */ + public WsdlImportMethod wsdlImportMethod() { + return this.wsdlImportMethod; + } + + /** + * Set the WSDL import method. Possible values include: 'NotSpecified', 'SoapToRest', 'SoapPassThrough'. + * + * @param wsdlImportMethod the wsdlImportMethod value to set + * @return the ApiResourceMetadata object itself. + */ + public ApiResourceMetadata withWsdlImportMethod(WsdlImportMethod wsdlImportMethod) { + this.wsdlImportMethod = wsdlImportMethod; + return this; + } + + /** + * Get the connection type. + * + * @return the connectionType value + */ + public String connectionType() { + return this.connectionType; + } + + /** + * Set the connection type. + * + * @param connectionType the connectionType value to set + * @return the ApiResourceMetadata object itself. + */ + public ApiResourceMetadata withConnectionType(String connectionType) { + this.connectionType = connectionType; + return this; + } + + /** + * Get the provisioning state. Possible values include: 'NotSpecified', 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', 'Registering', 'Registered', 'Unregistering', 'Unregistered', 'Completed', 'Renewing', 'Pending', 'Waiting', 'InProgress'. + * + * @return the provisioningState value + */ + public WorkflowProvisioningState provisioningState() { + return this.provisioningState; + } + + /** + * Set the provisioning state. Possible values include: 'NotSpecified', 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', 'Registering', 'Registered', 'Unregistering', 'Unregistered', 'Completed', 'Renewing', 'Pending', 'Waiting', 'InProgress'. + * + * @param provisioningState the provisioningState value to set + * @return the ApiResourceMetadata object itself. + */ + public ApiResourceMetadata withProvisioningState(WorkflowProvisioningState provisioningState) { + this.provisioningState = provisioningState; + return this; + } + + /** + * Get the connector deployment parameters metadata. + * + * @return the deploymentParameters value + */ + public ApiDeploymentParameterMetadataSet deploymentParameters() { + return this.deploymentParameters; + } + + /** + * Set the connector deployment parameters metadata. + * + * @param deploymentParameters the deploymentParameters value to set + * @return the ApiResourceMetadata object itself. + */ + public ApiResourceMetadata withDeploymentParameters(ApiDeploymentParameterMetadataSet deploymentParameters) { + this.deploymentParameters = deploymentParameters; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourcePolicies.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourcePolicies.java new file mode 100644 index 000000000000..d0e9cdf810a9 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourcePolicies.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The API resource policies. + */ +public class ApiResourcePolicies { + /** + * The API level only policies XML as embedded content. + */ + @JsonProperty(value = "content") + private String content; + + /** + * The content link to the policies. + */ + @JsonProperty(value = "contentLink") + private String contentLink; + + /** + * Get the API level only policies XML as embedded content. + * + * @return the content value + */ + public String content() { + return this.content; + } + + /** + * Set the API level only policies XML as embedded content. + * + * @param content the content value to set + * @return the ApiResourcePolicies object itself. + */ + public ApiResourcePolicies withContent(String content) { + this.content = content; + return this; + } + + /** + * Get the content link to the policies. + * + * @return the contentLink value + */ + public String contentLink() { + return this.contentLink; + } + + /** + * Set the content link to the policies. + * + * @param contentLink the contentLink value to set + * @return the ApiResourcePolicies object itself. + */ + public ApiResourcePolicies withContentLink(String contentLink) { + this.contentLink = contentLink; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceProperties.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceProperties.java new file mode 100644 index 000000000000..af84df84603e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiResourceProperties.java @@ -0,0 +1,362 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Map; +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The API resource properties. + */ +public class ApiResourceProperties { + /** + * The name. + */ + @JsonProperty(value = "name") + private String name; + + /** + * The connection parameters. + */ + @JsonProperty(value = "connectionParameters") + private Map connectionParameters; + + /** + * The metadata. + */ + @JsonProperty(value = "metadata") + private ApiResourceMetadata metadata; + + /** + * The runtime urls. + */ + @JsonProperty(value = "runtimeUrls") + private List runtimeUrls; + + /** + * The api general information. + */ + @JsonProperty(value = "generalInformation") + private ApiResourceGeneralInformation generalInformation; + + /** + * The capabilities. + */ + @JsonProperty(value = "capabilities") + private List capabilities; + + /** + * The backend service. + */ + @JsonProperty(value = "backendService") + private ApiResourceBackendService backendService; + + /** + * The policies for the API. + */ + @JsonProperty(value = "policies") + private ApiResourcePolicies policies; + + /** + * The API definition. + */ + @JsonProperty(value = "apiDefinitionUrl") + private String apiDefinitionUrl; + + /** + * The api definitions. + */ + @JsonProperty(value = "apiDefinitions") + private ApiResourceDefinitions apiDefinitions; + + /** + * The integration service environment reference. + */ + @JsonProperty(value = "integrationServiceEnvironment") + private ResourceReference integrationServiceEnvironment; + + /** + * The provisioning state. Possible values include: 'NotSpecified', + * 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', + * 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', + * 'Registering', 'Registered', 'Unregistering', 'Unregistered', + * 'Completed', 'Renewing', 'Pending', 'Waiting', 'InProgress'. + */ + @JsonProperty(value = "provisioningState") + private WorkflowProvisioningState provisioningState; + + /** + * The category. Possible values include: 'NotSpecified', 'Enterprise', + * 'Standard', 'Premium'. + */ + @JsonProperty(value = "category") + private ApiTier category; + + /** + * Get the name. + * + * @return the name value + */ + public String name() { + return this.name; + } + + /** + * Set the name. + * + * @param name the name value to set + * @return the ApiResourceProperties object itself. + */ + public ApiResourceProperties withName(String name) { + this.name = name; + return this; + } + + /** + * Get the connection parameters. + * + * @return the connectionParameters value + */ + public Map connectionParameters() { + return this.connectionParameters; + } + + /** + * Set the connection parameters. + * + * @param connectionParameters the connectionParameters value to set + * @return the ApiResourceProperties object itself. + */ + public ApiResourceProperties withConnectionParameters(Map connectionParameters) { + this.connectionParameters = connectionParameters; + return this; + } + + /** + * Get the metadata. + * + * @return the metadata value + */ + public ApiResourceMetadata metadata() { + return this.metadata; + } + + /** + * Set the metadata. + * + * @param metadata the metadata value to set + * @return the ApiResourceProperties object itself. + */ + public ApiResourceProperties withMetadata(ApiResourceMetadata metadata) { + this.metadata = metadata; + return this; + } + + /** + * Get the runtime urls. + * + * @return the runtimeUrls value + */ + public List runtimeUrls() { + return this.runtimeUrls; + } + + /** + * Set the runtime urls. + * + * @param runtimeUrls the runtimeUrls value to set + * @return the ApiResourceProperties object itself. + */ + public ApiResourceProperties withRuntimeUrls(List runtimeUrls) { + this.runtimeUrls = runtimeUrls; + return this; + } + + /** + * Get the api general information. + * + * @return the generalInformation value + */ + public ApiResourceGeneralInformation generalInformation() { + return this.generalInformation; + } + + /** + * Set the api general information. + * + * @param generalInformation the generalInformation value to set + * @return the ApiResourceProperties object itself. + */ + public ApiResourceProperties withGeneralInformation(ApiResourceGeneralInformation generalInformation) { + this.generalInformation = generalInformation; + return this; + } + + /** + * Get the capabilities. + * + * @return the capabilities value + */ + public List capabilities() { + return this.capabilities; + } + + /** + * Set the capabilities. + * + * @param capabilities the capabilities value to set + * @return the ApiResourceProperties object itself. + */ + public ApiResourceProperties withCapabilities(List capabilities) { + this.capabilities = capabilities; + return this; + } + + /** + * Get the backend service. + * + * @return the backendService value + */ + public ApiResourceBackendService backendService() { + return this.backendService; + } + + /** + * Set the backend service. + * + * @param backendService the backendService value to set + * @return the ApiResourceProperties object itself. + */ + public ApiResourceProperties withBackendService(ApiResourceBackendService backendService) { + this.backendService = backendService; + return this; + } + + /** + * Get the policies for the API. + * + * @return the policies value + */ + public ApiResourcePolicies policies() { + return this.policies; + } + + /** + * Set the policies for the API. + * + * @param policies the policies value to set + * @return the ApiResourceProperties object itself. + */ + public ApiResourceProperties withPolicies(ApiResourcePolicies policies) { + this.policies = policies; + return this; + } + + /** + * Get the API definition. + * + * @return the apiDefinitionUrl value + */ + public String apiDefinitionUrl() { + return this.apiDefinitionUrl; + } + + /** + * Set the API definition. + * + * @param apiDefinitionUrl the apiDefinitionUrl value to set + * @return the ApiResourceProperties object itself. + */ + public ApiResourceProperties withApiDefinitionUrl(String apiDefinitionUrl) { + this.apiDefinitionUrl = apiDefinitionUrl; + return this; + } + + /** + * Get the api definitions. + * + * @return the apiDefinitions value + */ + public ApiResourceDefinitions apiDefinitions() { + return this.apiDefinitions; + } + + /** + * Set the api definitions. + * + * @param apiDefinitions the apiDefinitions value to set + * @return the ApiResourceProperties object itself. + */ + public ApiResourceProperties withApiDefinitions(ApiResourceDefinitions apiDefinitions) { + this.apiDefinitions = apiDefinitions; + return this; + } + + /** + * Get the integration service environment reference. + * + * @return the integrationServiceEnvironment value + */ + public ResourceReference integrationServiceEnvironment() { + return this.integrationServiceEnvironment; + } + + /** + * Set the integration service environment reference. + * + * @param integrationServiceEnvironment the integrationServiceEnvironment value to set + * @return the ApiResourceProperties object itself. + */ + public ApiResourceProperties withIntegrationServiceEnvironment(ResourceReference integrationServiceEnvironment) { + this.integrationServiceEnvironment = integrationServiceEnvironment; + return this; + } + + /** + * Get the provisioning state. Possible values include: 'NotSpecified', 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', 'Registering', 'Registered', 'Unregistering', 'Unregistered', 'Completed', 'Renewing', 'Pending', 'Waiting', 'InProgress'. + * + * @return the provisioningState value + */ + public WorkflowProvisioningState provisioningState() { + return this.provisioningState; + } + + /** + * Set the provisioning state. Possible values include: 'NotSpecified', 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', 'Registering', 'Registered', 'Unregistering', 'Unregistered', 'Completed', 'Renewing', 'Pending', 'Waiting', 'InProgress'. + * + * @param provisioningState the provisioningState value to set + * @return the ApiResourceProperties object itself. + */ + public ApiResourceProperties withProvisioningState(WorkflowProvisioningState provisioningState) { + this.provisioningState = provisioningState; + return this; + } + + /** + * Get the category. Possible values include: 'NotSpecified', 'Enterprise', 'Standard', 'Premium'. + * + * @return the category value + */ + public ApiTier category() { + return this.category; + } + + /** + * Set the category. Possible values include: 'NotSpecified', 'Enterprise', 'Standard', 'Premium'. + * + * @param category the category value to set + * @return the ApiResourceProperties object itself. + */ + public ApiResourceProperties withCategory(ApiTier category) { + this.category = category; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiTier.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiTier.java new file mode 100644 index 000000000000..47cc6aa1c2e7 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiTier.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for ApiTier. + */ +public final class ApiTier extends ExpandableStringEnum { + /** Static value NotSpecified for ApiTier. */ + public static final ApiTier NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Enterprise for ApiTier. */ + public static final ApiTier ENTERPRISE = fromString("Enterprise"); + + /** Static value Standard for ApiTier. */ + public static final ApiTier STANDARD = fromString("Standard"); + + /** Static value Premium for ApiTier. */ + public static final ApiTier PREMIUM = fromString("Premium"); + + /** + * Creates or finds a ApiTier from its string representation. + * @param name a name to look for + * @return the corresponding ApiTier + */ + @JsonCreator + public static ApiTier fromString(String name) { + return fromString(name, ApiTier.class); + } + + /** + * @return known ApiTier values + */ + public static Collection values() { + return values(ApiTier.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiType.java new file mode 100644 index 000000000000..950117aab547 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ApiType.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for ApiType. + */ +public final class ApiType extends ExpandableStringEnum { + /** Static value NotSpecified for ApiType. */ + public static final ApiType NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Rest for ApiType. */ + public static final ApiType REST = fromString("Rest"); + + /** Static value Soap for ApiType. */ + public static final ApiType SOAP = fromString("Soap"); + + /** + * Creates or finds a ApiType from its string representation. + * @param name a name to look for + * @return the corresponding ApiType + */ + @JsonCreator + public static ApiType fromString(String name) { + return fromString(name, ApiType.class); + } + + /** + * @return known ApiType values + */ + public static Collection values() { + return values(ApiType.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ArtifactContentPropertiesDefinition.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ArtifactContentPropertiesDefinition.java new file mode 100644 index 000000000000..78b707f7cf83 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ArtifactContentPropertiesDefinition.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The artifact content properties definition. + */ +public class ArtifactContentPropertiesDefinition extends ArtifactProperties { + /** + * The content property. + */ + @JsonProperty(value = "content") + private Object content; + + /** + * The content type. + */ + @JsonProperty(value = "contentType") + private String contentType; + + /** + * The content link. + */ + @JsonProperty(value = "contentLink") + private ContentLink contentLink; + + /** + * Get the content value. + * + * @return the content value + */ + public Object content() { + return this.content; + } + + /** + * Set the content value. + * + * @param content the content value to set + * @return the ArtifactContentPropertiesDefinition object itself. + */ + public ArtifactContentPropertiesDefinition withContent(Object content) { + this.content = content; + return this; + } + + /** + * Get the content type. + * + * @return the contentType value + */ + public String contentType() { + return this.contentType; + } + + /** + * Set the content type. + * + * @param contentType the contentType value to set + * @return the ArtifactContentPropertiesDefinition object itself. + */ + public ArtifactContentPropertiesDefinition withContentType(String contentType) { + this.contentType = contentType; + return this; + } + + /** + * Get the content link. + * + * @return the contentLink value + */ + public ContentLink contentLink() { + return this.contentLink; + } + + /** + * Set the content link. + * + * @param contentLink the contentLink value to set + * @return the ArtifactContentPropertiesDefinition object itself. + */ + public ArtifactContentPropertiesDefinition withContentLink(ContentLink contentLink) { + this.contentLink = contentLink; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ArtifactProperties.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ArtifactProperties.java new file mode 100644 index 000000000000..8da62581eb93 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ArtifactProperties.java @@ -0,0 +1,96 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import org.joda.time.DateTime; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The artifact properties definition. + */ +public class ArtifactProperties { + /** + * The artifact creation time. + */ + @JsonProperty(value = "createdTime") + private DateTime createdTime; + + /** + * The artifact changed time. + */ + @JsonProperty(value = "changedTime") + private DateTime changedTime; + + /** + * The metadata property. + */ + @JsonProperty(value = "metadata") + private Object metadata; + + /** + * Get the artifact creation time. + * + * @return the createdTime value + */ + public DateTime createdTime() { + return this.createdTime; + } + + /** + * Set the artifact creation time. + * + * @param createdTime the createdTime value to set + * @return the ArtifactProperties object itself. + */ + public ArtifactProperties withCreatedTime(DateTime createdTime) { + this.createdTime = createdTime; + return this; + } + + /** + * Get the artifact changed time. + * + * @return the changedTime value + */ + public DateTime changedTime() { + return this.changedTime; + } + + /** + * Set the artifact changed time. + * + * @param changedTime the changedTime value to set + * @return the ArtifactProperties object itself. + */ + public ArtifactProperties withChangedTime(DateTime changedTime) { + this.changedTime = changedTime; + return this; + } + + /** + * Get the metadata value. + * + * @return the metadata value + */ + public Object metadata() { + return this.metadata; + } + + /** + * Set the metadata value. + * + * @param metadata the metadata value to set + * @return the ArtifactProperties object itself. + */ + public ArtifactProperties withMetadata(Object metadata) { + this.metadata = metadata; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AssemblyDefinition.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AssemblyDefinition.java new file mode 100644 index 000000000000..b6d325afc4b2 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AssemblyDefinition.java @@ -0,0 +1,164 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.AssemblyDefinitionInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.model.Updatable; +import com.microsoft.azure.arm.model.Appliable; +import com.microsoft.azure.arm.model.Creatable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import java.util.Map; + +/** + * Type representing AssemblyDefinition. + */ +public interface AssemblyDefinition extends HasInner, Indexable, Refreshable, Updatable, HasManager { + /** + * @return the id value. + */ + String id(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the properties value. + */ + AssemblyProperties properties(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the type value. + */ + String type(); + + /** + * The entirety of the AssemblyDefinition definition. + */ + interface Definition extends DefinitionStages.Blank, DefinitionStages.WithIntegrationAccount, DefinitionStages.WithProperties, DefinitionStages.WithCreate { + } + + /** + * Grouping of AssemblyDefinition definition stages. + */ + interface DefinitionStages { + /** + * The first stage of a AssemblyDefinition definition. + */ + interface Blank extends WithIntegrationAccount { + } + + /** + * The stage of the assemblydefinition definition allowing to specify IntegrationAccount. + */ + interface WithIntegrationAccount { + /** + * Specifies resourceGroupName, integrationAccountName. + * @param resourceGroupName The resource group name + * @param integrationAccountName The integration account name + * @return the next definition stage + */ + WithProperties withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the assemblydefinition definition allowing to specify Properties. + */ + interface WithProperties { + /** + * Specifies properties. + * @param properties The assembly properties + * @return the next definition stage + */ + WithCreate withProperties(AssemblyProperties properties); + } + + /** + * The stage of the assemblydefinition definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next definition stage + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the assemblydefinition definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next definition stage + */ + WithCreate withTags(Map tags); + } + + /** + * The stage of the definition which contains all the minimum required inputs for + * the resource to be created (via {@link WithCreate#create()}), but also allows + * for any other optional settings to be specified. + */ + interface WithCreate extends Creatable, DefinitionStages.WithLocation, DefinitionStages.WithTags { + } + } + /** + * The template for a AssemblyDefinition update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable, UpdateStages.WithLocation, UpdateStages.WithTags { + } + + /** + * Grouping of AssemblyDefinition update stages. + */ + interface UpdateStages { + /** + * The stage of the assemblydefinition update allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next update stage + */ + Update withLocation(String location); + } + + /** + * The stage of the assemblydefinition update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next update stage + */ + Update withTags(Map tags); + } + + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AssemblyProperties.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AssemblyProperties.java new file mode 100644 index 000000000000..25331bd69b27 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AssemblyProperties.java @@ -0,0 +1,121 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The assembly properties definition. + */ +public class AssemblyProperties extends ArtifactContentPropertiesDefinition { + /** + * The assembly name. + */ + @JsonProperty(value = "assemblyName", required = true) + private String assemblyName; + + /** + * The assembly version. + */ + @JsonProperty(value = "assemblyVersion") + private String assemblyVersion; + + /** + * The assembly culture. + */ + @JsonProperty(value = "assemblyCulture") + private String assemblyCulture; + + /** + * The assembly public key token. + */ + @JsonProperty(value = "assemblyPublicKeyToken") + private String assemblyPublicKeyToken; + + /** + * Get the assembly name. + * + * @return the assemblyName value + */ + public String assemblyName() { + return this.assemblyName; + } + + /** + * Set the assembly name. + * + * @param assemblyName the assemblyName value to set + * @return the AssemblyProperties object itself. + */ + public AssemblyProperties withAssemblyName(String assemblyName) { + this.assemblyName = assemblyName; + return this; + } + + /** + * Get the assembly version. + * + * @return the assemblyVersion value + */ + public String assemblyVersion() { + return this.assemblyVersion; + } + + /** + * Set the assembly version. + * + * @param assemblyVersion the assemblyVersion value to set + * @return the AssemblyProperties object itself. + */ + public AssemblyProperties withAssemblyVersion(String assemblyVersion) { + this.assemblyVersion = assemblyVersion; + return this; + } + + /** + * Get the assembly culture. + * + * @return the assemblyCulture value + */ + public String assemblyCulture() { + return this.assemblyCulture; + } + + /** + * Set the assembly culture. + * + * @param assemblyCulture the assemblyCulture value to set + * @return the AssemblyProperties object itself. + */ + public AssemblyProperties withAssemblyCulture(String assemblyCulture) { + this.assemblyCulture = assemblyCulture; + return this; + } + + /** + * Get the assembly public key token. + * + * @return the assemblyPublicKeyToken value + */ + public String assemblyPublicKeyToken() { + return this.assemblyPublicKeyToken; + } + + /** + * Set the assembly public key token. + * + * @param assemblyPublicKeyToken the assemblyPublicKeyToken value to set + * @return the AssemblyProperties object itself. + */ + public AssemblyProperties withAssemblyPublicKeyToken(String assemblyPublicKeyToken) { + this.assemblyPublicKeyToken = assemblyPublicKeyToken; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AzureAsyncOperationState.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AzureAsyncOperationState.java new file mode 100644 index 000000000000..9fadd2420d9a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AzureAsyncOperationState.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for AzureAsyncOperationState. + */ +public final class AzureAsyncOperationState extends ExpandableStringEnum { + /** Static value Failed for AzureAsyncOperationState. */ + public static final AzureAsyncOperationState FAILED = fromString("Failed"); + + /** Static value Succeeded for AzureAsyncOperationState. */ + public static final AzureAsyncOperationState SUCCEEDED = fromString("Succeeded"); + + /** Static value Pending for AzureAsyncOperationState. */ + public static final AzureAsyncOperationState PENDING = fromString("Pending"); + + /** Static value Canceled for AzureAsyncOperationState. */ + public static final AzureAsyncOperationState CANCELED = fromString("Canceled"); + + /** + * Creates or finds a AzureAsyncOperationState from its string representation. + * @param name a name to look for + * @return the corresponding AzureAsyncOperationState + */ + @JsonCreator + public static AzureAsyncOperationState fromString(String name) { + return fromString(name, AzureAsyncOperationState.class); + } + + /** + * @return known AzureAsyncOperationState values + */ + public static Collection values() { + return values(AzureAsyncOperationState.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AzureResourceErrorInfo.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AzureResourceErrorInfo.java new file mode 100644 index 000000000000..34d60a3ed8a9 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/AzureResourceErrorInfo.java @@ -0,0 +1,70 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The azure resource error info. + */ +public class AzureResourceErrorInfo extends ErrorInfo { + /** + * The error message. + */ + @JsonProperty(value = "message", required = true) + private String message; + + /** + * The error details. + */ + @JsonProperty(value = "details") + private List details; + + /** + * Get the error message. + * + * @return the message value + */ + public String message() { + return this.message; + } + + /** + * Set the error message. + * + * @param message the message value to set + * @return the AzureResourceErrorInfo object itself. + */ + public AzureResourceErrorInfo withMessage(String message) { + this.message = message; + return this; + } + + /** + * Get the error details. + * + * @return the details value + */ + public List details() { + return this.details; + } + + /** + * Set the error details. + * + * @param details the details value to set + * @return the AzureResourceErrorInfo object itself. + */ + public AzureResourceErrorInfo withDetails(List details) { + this.details = details; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/B2BPartnerContent.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/B2BPartnerContent.java new file mode 100644 index 000000000000..05b606efbca2 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/B2BPartnerContent.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The B2B partner content. + */ +public class B2BPartnerContent { + /** + * The list of partner business identities. + */ + @JsonProperty(value = "businessIdentities") + private List businessIdentities; + + /** + * Get the list of partner business identities. + * + * @return the businessIdentities value + */ + public List businessIdentities() { + return this.businessIdentities; + } + + /** + * Set the list of partner business identities. + * + * @param businessIdentities the businessIdentities value to set + * @return the B2BPartnerContent object itself. + */ + public B2BPartnerContent withBusinessIdentities(List businessIdentities) { + this.businessIdentities = businessIdentities; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/BatchConfiguration.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/BatchConfiguration.java new file mode 100644 index 000000000000..5009c1f59811 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/BatchConfiguration.java @@ -0,0 +1,164 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.BatchConfigurationInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.model.Updatable; +import com.microsoft.azure.arm.model.Appliable; +import com.microsoft.azure.arm.model.Creatable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import java.util.Map; + +/** + * Type representing BatchConfiguration. + */ +public interface BatchConfiguration extends HasInner, Indexable, Refreshable, Updatable, HasManager { + /** + * @return the id value. + */ + String id(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the properties value. + */ + BatchConfigurationProperties properties(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the type value. + */ + String type(); + + /** + * The entirety of the BatchConfiguration definition. + */ + interface Definition extends DefinitionStages.Blank, DefinitionStages.WithIntegrationAccount, DefinitionStages.WithProperties, DefinitionStages.WithCreate { + } + + /** + * Grouping of BatchConfiguration definition stages. + */ + interface DefinitionStages { + /** + * The first stage of a BatchConfiguration definition. + */ + interface Blank extends WithIntegrationAccount { + } + + /** + * The stage of the batchconfiguration definition allowing to specify IntegrationAccount. + */ + interface WithIntegrationAccount { + /** + * Specifies resourceGroupName, integrationAccountName. + * @param resourceGroupName The resource group name + * @param integrationAccountName The integration account name + * @return the next definition stage + */ + WithProperties withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the batchconfiguration definition allowing to specify Properties. + */ + interface WithProperties { + /** + * Specifies properties. + * @param properties The batch configuration properties + * @return the next definition stage + */ + WithCreate withProperties(BatchConfigurationProperties properties); + } + + /** + * The stage of the batchconfiguration definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next definition stage + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the batchconfiguration definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next definition stage + */ + WithCreate withTags(Map tags); + } + + /** + * The stage of the definition which contains all the minimum required inputs for + * the resource to be created (via {@link WithCreate#create()}), but also allows + * for any other optional settings to be specified. + */ + interface WithCreate extends Creatable, DefinitionStages.WithLocation, DefinitionStages.WithTags { + } + } + /** + * The template for a BatchConfiguration update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable, UpdateStages.WithLocation, UpdateStages.WithTags { + } + + /** + * Grouping of BatchConfiguration update stages. + */ + interface UpdateStages { + /** + * The stage of the batchconfiguration update allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next update stage + */ + Update withLocation(String location); + } + + /** + * The stage of the batchconfiguration update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next update stage + */ + Update withTags(Map tags); + } + + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/BatchConfigurationProperties.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/BatchConfigurationProperties.java new file mode 100644 index 000000000000..c88a8638411d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/BatchConfigurationProperties.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The batch configuration properties definition. + */ +public class BatchConfigurationProperties extends ArtifactProperties { + /** + * The name of the batch group. + */ + @JsonProperty(value = "batchGroupName", required = true) + private String batchGroupName; + + /** + * The batch release criteria. + */ + @JsonProperty(value = "releaseCriteria", required = true) + private BatchReleaseCriteria releaseCriteria; + + /** + * Get the name of the batch group. + * + * @return the batchGroupName value + */ + public String batchGroupName() { + return this.batchGroupName; + } + + /** + * Set the name of the batch group. + * + * @param batchGroupName the batchGroupName value to set + * @return the BatchConfigurationProperties object itself. + */ + public BatchConfigurationProperties withBatchGroupName(String batchGroupName) { + this.batchGroupName = batchGroupName; + return this; + } + + /** + * Get the batch release criteria. + * + * @return the releaseCriteria value + */ + public BatchReleaseCriteria releaseCriteria() { + return this.releaseCriteria; + } + + /** + * Set the batch release criteria. + * + * @param releaseCriteria the releaseCriteria value to set + * @return the BatchConfigurationProperties object itself. + */ + public BatchConfigurationProperties withReleaseCriteria(BatchReleaseCriteria releaseCriteria) { + this.releaseCriteria = releaseCriteria; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/BatchReleaseCriteria.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/BatchReleaseCriteria.java new file mode 100644 index 000000000000..7ac561f07cf4 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/BatchReleaseCriteria.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The batch release criteria. + */ +public class BatchReleaseCriteria { + /** + * The message count. + */ + @JsonProperty(value = "messageCount") + private Integer messageCount; + + /** + * The batch size in bytes. + */ + @JsonProperty(value = "batchSize") + private Integer batchSize; + + /** + * The recurrence. + */ + @JsonProperty(value = "recurrence") + private WorkflowTriggerRecurrence recurrence; + + /** + * Get the message count. + * + * @return the messageCount value + */ + public Integer messageCount() { + return this.messageCount; + } + + /** + * Set the message count. + * + * @param messageCount the messageCount value to set + * @return the BatchReleaseCriteria object itself. + */ + public BatchReleaseCriteria withMessageCount(Integer messageCount) { + this.messageCount = messageCount; + return this; + } + + /** + * Get the batch size in bytes. + * + * @return the batchSize value + */ + public Integer batchSize() { + return this.batchSize; + } + + /** + * Set the batch size in bytes. + * + * @param batchSize the batchSize value to set + * @return the BatchReleaseCriteria object itself. + */ + public BatchReleaseCriteria withBatchSize(Integer batchSize) { + this.batchSize = batchSize; + return this; + } + + /** + * Get the recurrence. + * + * @return the recurrence value + */ + public WorkflowTriggerRecurrence recurrence() { + return this.recurrence; + } + + /** + * Set the recurrence. + * + * @param recurrence the recurrence value to set + * @return the BatchReleaseCriteria object itself. + */ + public BatchReleaseCriteria withRecurrence(WorkflowTriggerRecurrence recurrence) { + this.recurrence = recurrence; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/BusinessIdentity.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/BusinessIdentity.java new file mode 100644 index 000000000000..8a50b2f3a271 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/BusinessIdentity.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration account partner's business identity. + */ +public class BusinessIdentity { + /** + * The business identity qualifier e.g. as2identity, ZZ, ZZZ, 31, 32. + */ + @JsonProperty(value = "qualifier", required = true) + private String qualifier; + + /** + * The user defined business identity value. + */ + @JsonProperty(value = "value", required = true) + private String value; + + /** + * Get the business identity qualifier e.g. as2identity, ZZ, ZZZ, 31, 32. + * + * @return the qualifier value + */ + public String qualifier() { + return this.qualifier; + } + + /** + * Set the business identity qualifier e.g. as2identity, ZZ, ZZZ, 31, 32. + * + * @param qualifier the qualifier value to set + * @return the BusinessIdentity object itself. + */ + public BusinessIdentity withQualifier(String qualifier) { + this.qualifier = qualifier; + return this; + } + + /** + * Get the user defined business identity value. + * + * @return the value value + */ + public String value() { + return this.value; + } + + /** + * Set the user defined business identity value. + * + * @param value the value value to set + * @return the BusinessIdentity object itself. + */ + public BusinessIdentity withValue(String value) { + this.value = value; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/CallbackUrl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/CallbackUrl.java new file mode 100644 index 000000000000..958ea72237f0 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/CallbackUrl.java @@ -0,0 +1,25 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.CallbackUrlInner; + +/** + * Type representing CallbackUrl. + */ +public interface CallbackUrl extends HasInner, HasManager { + /** + * @return the value value. + */ + String value(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ContentHash.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ContentHash.java new file mode 100644 index 000000000000..810c9567dc82 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ContentHash.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The content hash. + */ +public class ContentHash { + /** + * The algorithm of the content hash. + */ + @JsonProperty(value = "algorithm") + private String algorithm; + + /** + * The value of the content hash. + */ + @JsonProperty(value = "value") + private String value; + + /** + * Get the algorithm of the content hash. + * + * @return the algorithm value + */ + public String algorithm() { + return this.algorithm; + } + + /** + * Set the algorithm of the content hash. + * + * @param algorithm the algorithm value to set + * @return the ContentHash object itself. + */ + public ContentHash withAlgorithm(String algorithm) { + this.algorithm = algorithm; + return this; + } + + /** + * Get the value of the content hash. + * + * @return the value value + */ + public String value() { + return this.value; + } + + /** + * Set the value of the content hash. + * + * @param value the value value to set + * @return the ContentHash object itself. + */ + public ContentHash withValue(String value) { + this.value = value; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ContentLink.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ContentLink.java new file mode 100644 index 000000000000..64b03b66cff9 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ContentLink.java @@ -0,0 +1,147 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The content link. + */ +public class ContentLink { + /** + * The content link URI. + */ + @JsonProperty(value = "uri") + private String uri; + + /** + * The content version. + */ + @JsonProperty(value = "contentVersion") + private String contentVersion; + + /** + * The content size. + */ + @JsonProperty(value = "contentSize") + private Long contentSize; + + /** + * The content hash. + */ + @JsonProperty(value = "contentHash") + private ContentHash contentHash; + + /** + * The metadata. + */ + @JsonProperty(value = "metadata") + private Object metadata; + + /** + * Get the content link URI. + * + * @return the uri value + */ + public String uri() { + return this.uri; + } + + /** + * Set the content link URI. + * + * @param uri the uri value to set + * @return the ContentLink object itself. + */ + public ContentLink withUri(String uri) { + this.uri = uri; + return this; + } + + /** + * Get the content version. + * + * @return the contentVersion value + */ + public String contentVersion() { + return this.contentVersion; + } + + /** + * Set the content version. + * + * @param contentVersion the contentVersion value to set + * @return the ContentLink object itself. + */ + public ContentLink withContentVersion(String contentVersion) { + this.contentVersion = contentVersion; + return this; + } + + /** + * Get the content size. + * + * @return the contentSize value + */ + public Long contentSize() { + return this.contentSize; + } + + /** + * Set the content size. + * + * @param contentSize the contentSize value to set + * @return the ContentLink object itself. + */ + public ContentLink withContentSize(Long contentSize) { + this.contentSize = contentSize; + return this; + } + + /** + * Get the content hash. + * + * @return the contentHash value + */ + public ContentHash contentHash() { + return this.contentHash; + } + + /** + * Set the content hash. + * + * @param contentHash the contentHash value to set + * @return the ContentLink object itself. + */ + public ContentLink withContentHash(ContentHash contentHash) { + this.contentHash = contentHash; + return this; + } + + /** + * Get the metadata. + * + * @return the metadata value + */ + public Object metadata() { + return this.metadata; + } + + /** + * Set the metadata. + * + * @param metadata the metadata value to set + * @return the ContentLink object itself. + */ + public ContentLink withMetadata(Object metadata) { + this.metadata = metadata; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Correlation.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Correlation.java new file mode 100644 index 000000000000..62fd4c12cb5d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Correlation.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The correlation property. + */ +public class Correlation { + /** + * The client tracking id. + */ + @JsonProperty(value = "clientTrackingId") + private String clientTrackingId; + + /** + * Get the client tracking id. + * + * @return the clientTrackingId value + */ + public String clientTrackingId() { + return this.clientTrackingId; + } + + /** + * Set the client tracking id. + * + * @param clientTrackingId the clientTrackingId value to set + * @return the Correlation object itself. + */ + public Correlation withClientTrackingId(String clientTrackingId) { + this.clientTrackingId = clientTrackingId; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/DayOfWeek.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/DayOfWeek.java new file mode 100644 index 000000000000..fc90196f28c0 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/DayOfWeek.java @@ -0,0 +1,68 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +/** + * Defines values for DayOfWeek. + */ +public enum DayOfWeek { + /** Enum value Sunday. */ + SUNDAY("Sunday"), + + /** Enum value Monday. */ + MONDAY("Monday"), + + /** Enum value Tuesday. */ + TUESDAY("Tuesday"), + + /** Enum value Wednesday. */ + WEDNESDAY("Wednesday"), + + /** Enum value Thursday. */ + THURSDAY("Thursday"), + + /** Enum value Friday. */ + FRIDAY("Friday"), + + /** Enum value Saturday. */ + SATURDAY("Saturday"); + + /** The actual serialized value for a DayOfWeek instance. */ + private String value; + + DayOfWeek(String value) { + this.value = value; + } + + /** + * Parses a serialized value to a DayOfWeek instance. + * + * @param value the serialized value to parse. + * @return the parsed DayOfWeek object, or null if unable to parse. + */ + @JsonCreator + public static DayOfWeek fromString(String value) { + DayOfWeek[] items = DayOfWeek.values(); + for (DayOfWeek item : items) { + if (item.toString().equalsIgnoreCase(value)) { + return item; + } + } + return null; + } + + @JsonValue + @Override + public String toString() { + return this.value; + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/DaysOfWeek.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/DaysOfWeek.java new file mode 100644 index 000000000000..e69a8ac2c49f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/DaysOfWeek.java @@ -0,0 +1,68 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +/** + * Defines values for DaysOfWeek. + */ +public enum DaysOfWeek { + /** Enum value Sunday. */ + SUNDAY("Sunday"), + + /** Enum value Monday. */ + MONDAY("Monday"), + + /** Enum value Tuesday. */ + TUESDAY("Tuesday"), + + /** Enum value Wednesday. */ + WEDNESDAY("Wednesday"), + + /** Enum value Thursday. */ + THURSDAY("Thursday"), + + /** Enum value Friday. */ + FRIDAY("Friday"), + + /** Enum value Saturday. */ + SATURDAY("Saturday"); + + /** The actual serialized value for a DaysOfWeek instance. */ + private String value; + + DaysOfWeek(String value) { + this.value = value; + } + + /** + * Parses a serialized value to a DaysOfWeek instance. + * + * @param value the serialized value to parse. + * @return the parsed DaysOfWeek object, or null if unable to parse. + */ + @JsonCreator + public static DaysOfWeek fromString(String value) { + DaysOfWeek[] items = DaysOfWeek.values(); + for (DaysOfWeek item : items) { + if (item.toString().equalsIgnoreCase(value)) { + return item; + } + } + return null; + } + + @JsonValue + @Override + public String toString() { + return this.value; + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactAcknowledgementSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactAcknowledgementSettings.java new file mode 100644 index 000000000000..12e1147db3e2 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactAcknowledgementSettings.java @@ -0,0 +1,303 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact agreement acknowledgement settings. + */ +public class EdifactAcknowledgementSettings { + /** + * The value indicating whether technical acknowledgement is needed. + */ + @JsonProperty(value = "needTechnicalAcknowledgement", required = true) + private boolean needTechnicalAcknowledgement; + + /** + * The value indicating whether to batch the technical acknowledgements. + */ + @JsonProperty(value = "batchTechnicalAcknowledgements", required = true) + private boolean batchTechnicalAcknowledgements; + + /** + * The value indicating whether functional acknowledgement is needed. + */ + @JsonProperty(value = "needFunctionalAcknowledgement", required = true) + private boolean needFunctionalAcknowledgement; + + /** + * The value indicating whether to batch functional acknowledgements. + */ + @JsonProperty(value = "batchFunctionalAcknowledgements", required = true) + private boolean batchFunctionalAcknowledgements; + + /** + * The value indicating whether a loop is needed for valid messages. + */ + @JsonProperty(value = "needLoopForValidMessages", required = true) + private boolean needLoopForValidMessages; + + /** + * The value indicating whether to send synchronous acknowledgement. + */ + @JsonProperty(value = "sendSynchronousAcknowledgement", required = true) + private boolean sendSynchronousAcknowledgement; + + /** + * The acknowledgement control number prefix. + */ + @JsonProperty(value = "acknowledgementControlNumberPrefix") + private String acknowledgementControlNumberPrefix; + + /** + * The acknowledgement control number suffix. + */ + @JsonProperty(value = "acknowledgementControlNumberSuffix") + private String acknowledgementControlNumberSuffix; + + /** + * The acknowledgement control number lower bound. + */ + @JsonProperty(value = "acknowledgementControlNumberLowerBound", required = true) + private int acknowledgementControlNumberLowerBound; + + /** + * The acknowledgement control number upper bound. + */ + @JsonProperty(value = "acknowledgementControlNumberUpperBound", required = true) + private int acknowledgementControlNumberUpperBound; + + /** + * The value indicating whether to rollover acknowledgement control number. + */ + @JsonProperty(value = "rolloverAcknowledgementControlNumber", required = true) + private boolean rolloverAcknowledgementControlNumber; + + /** + * Get the value indicating whether technical acknowledgement is needed. + * + * @return the needTechnicalAcknowledgement value + */ + public boolean needTechnicalAcknowledgement() { + return this.needTechnicalAcknowledgement; + } + + /** + * Set the value indicating whether technical acknowledgement is needed. + * + * @param needTechnicalAcknowledgement the needTechnicalAcknowledgement value to set + * @return the EdifactAcknowledgementSettings object itself. + */ + public EdifactAcknowledgementSettings withNeedTechnicalAcknowledgement(boolean needTechnicalAcknowledgement) { + this.needTechnicalAcknowledgement = needTechnicalAcknowledgement; + return this; + } + + /** + * Get the value indicating whether to batch the technical acknowledgements. + * + * @return the batchTechnicalAcknowledgements value + */ + public boolean batchTechnicalAcknowledgements() { + return this.batchTechnicalAcknowledgements; + } + + /** + * Set the value indicating whether to batch the technical acknowledgements. + * + * @param batchTechnicalAcknowledgements the batchTechnicalAcknowledgements value to set + * @return the EdifactAcknowledgementSettings object itself. + */ + public EdifactAcknowledgementSettings withBatchTechnicalAcknowledgements(boolean batchTechnicalAcknowledgements) { + this.batchTechnicalAcknowledgements = batchTechnicalAcknowledgements; + return this; + } + + /** + * Get the value indicating whether functional acknowledgement is needed. + * + * @return the needFunctionalAcknowledgement value + */ + public boolean needFunctionalAcknowledgement() { + return this.needFunctionalAcknowledgement; + } + + /** + * Set the value indicating whether functional acknowledgement is needed. + * + * @param needFunctionalAcknowledgement the needFunctionalAcknowledgement value to set + * @return the EdifactAcknowledgementSettings object itself. + */ + public EdifactAcknowledgementSettings withNeedFunctionalAcknowledgement(boolean needFunctionalAcknowledgement) { + this.needFunctionalAcknowledgement = needFunctionalAcknowledgement; + return this; + } + + /** + * Get the value indicating whether to batch functional acknowledgements. + * + * @return the batchFunctionalAcknowledgements value + */ + public boolean batchFunctionalAcknowledgements() { + return this.batchFunctionalAcknowledgements; + } + + /** + * Set the value indicating whether to batch functional acknowledgements. + * + * @param batchFunctionalAcknowledgements the batchFunctionalAcknowledgements value to set + * @return the EdifactAcknowledgementSettings object itself. + */ + public EdifactAcknowledgementSettings withBatchFunctionalAcknowledgements(boolean batchFunctionalAcknowledgements) { + this.batchFunctionalAcknowledgements = batchFunctionalAcknowledgements; + return this; + } + + /** + * Get the value indicating whether a loop is needed for valid messages. + * + * @return the needLoopForValidMessages value + */ + public boolean needLoopForValidMessages() { + return this.needLoopForValidMessages; + } + + /** + * Set the value indicating whether a loop is needed for valid messages. + * + * @param needLoopForValidMessages the needLoopForValidMessages value to set + * @return the EdifactAcknowledgementSettings object itself. + */ + public EdifactAcknowledgementSettings withNeedLoopForValidMessages(boolean needLoopForValidMessages) { + this.needLoopForValidMessages = needLoopForValidMessages; + return this; + } + + /** + * Get the value indicating whether to send synchronous acknowledgement. + * + * @return the sendSynchronousAcknowledgement value + */ + public boolean sendSynchronousAcknowledgement() { + return this.sendSynchronousAcknowledgement; + } + + /** + * Set the value indicating whether to send synchronous acknowledgement. + * + * @param sendSynchronousAcknowledgement the sendSynchronousAcknowledgement value to set + * @return the EdifactAcknowledgementSettings object itself. + */ + public EdifactAcknowledgementSettings withSendSynchronousAcknowledgement(boolean sendSynchronousAcknowledgement) { + this.sendSynchronousAcknowledgement = sendSynchronousAcknowledgement; + return this; + } + + /** + * Get the acknowledgement control number prefix. + * + * @return the acknowledgementControlNumberPrefix value + */ + public String acknowledgementControlNumberPrefix() { + return this.acknowledgementControlNumberPrefix; + } + + /** + * Set the acknowledgement control number prefix. + * + * @param acknowledgementControlNumberPrefix the acknowledgementControlNumberPrefix value to set + * @return the EdifactAcknowledgementSettings object itself. + */ + public EdifactAcknowledgementSettings withAcknowledgementControlNumberPrefix(String acknowledgementControlNumberPrefix) { + this.acknowledgementControlNumberPrefix = acknowledgementControlNumberPrefix; + return this; + } + + /** + * Get the acknowledgement control number suffix. + * + * @return the acknowledgementControlNumberSuffix value + */ + public String acknowledgementControlNumberSuffix() { + return this.acknowledgementControlNumberSuffix; + } + + /** + * Set the acknowledgement control number suffix. + * + * @param acknowledgementControlNumberSuffix the acknowledgementControlNumberSuffix value to set + * @return the EdifactAcknowledgementSettings object itself. + */ + public EdifactAcknowledgementSettings withAcknowledgementControlNumberSuffix(String acknowledgementControlNumberSuffix) { + this.acknowledgementControlNumberSuffix = acknowledgementControlNumberSuffix; + return this; + } + + /** + * Get the acknowledgement control number lower bound. + * + * @return the acknowledgementControlNumberLowerBound value + */ + public int acknowledgementControlNumberLowerBound() { + return this.acknowledgementControlNumberLowerBound; + } + + /** + * Set the acknowledgement control number lower bound. + * + * @param acknowledgementControlNumberLowerBound the acknowledgementControlNumberLowerBound value to set + * @return the EdifactAcknowledgementSettings object itself. + */ + public EdifactAcknowledgementSettings withAcknowledgementControlNumberLowerBound(int acknowledgementControlNumberLowerBound) { + this.acknowledgementControlNumberLowerBound = acknowledgementControlNumberLowerBound; + return this; + } + + /** + * Get the acknowledgement control number upper bound. + * + * @return the acknowledgementControlNumberUpperBound value + */ + public int acknowledgementControlNumberUpperBound() { + return this.acknowledgementControlNumberUpperBound; + } + + /** + * Set the acknowledgement control number upper bound. + * + * @param acknowledgementControlNumberUpperBound the acknowledgementControlNumberUpperBound value to set + * @return the EdifactAcknowledgementSettings object itself. + */ + public EdifactAcknowledgementSettings withAcknowledgementControlNumberUpperBound(int acknowledgementControlNumberUpperBound) { + this.acknowledgementControlNumberUpperBound = acknowledgementControlNumberUpperBound; + return this; + } + + /** + * Get the value indicating whether to rollover acknowledgement control number. + * + * @return the rolloverAcknowledgementControlNumber value + */ + public boolean rolloverAcknowledgementControlNumber() { + return this.rolloverAcknowledgementControlNumber; + } + + /** + * Set the value indicating whether to rollover acknowledgement control number. + * + * @param rolloverAcknowledgementControlNumber the rolloverAcknowledgementControlNumber value to set + * @return the EdifactAcknowledgementSettings object itself. + */ + public EdifactAcknowledgementSettings withRolloverAcknowledgementControlNumber(boolean rolloverAcknowledgementControlNumber) { + this.rolloverAcknowledgementControlNumber = rolloverAcknowledgementControlNumber; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactAgreementContent.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactAgreementContent.java new file mode 100644 index 000000000000..ec396d7c02c0 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactAgreementContent.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact agreement content. + */ +public class EdifactAgreementContent { + /** + * The EDIFACT one-way receive agreement. + */ + @JsonProperty(value = "receiveAgreement", required = true) + private EdifactOneWayAgreement receiveAgreement; + + /** + * The EDIFACT one-way send agreement. + */ + @JsonProperty(value = "sendAgreement", required = true) + private EdifactOneWayAgreement sendAgreement; + + /** + * Get the EDIFACT one-way receive agreement. + * + * @return the receiveAgreement value + */ + public EdifactOneWayAgreement receiveAgreement() { + return this.receiveAgreement; + } + + /** + * Set the EDIFACT one-way receive agreement. + * + * @param receiveAgreement the receiveAgreement value to set + * @return the EdifactAgreementContent object itself. + */ + public EdifactAgreementContent withReceiveAgreement(EdifactOneWayAgreement receiveAgreement) { + this.receiveAgreement = receiveAgreement; + return this; + } + + /** + * Get the EDIFACT one-way send agreement. + * + * @return the sendAgreement value + */ + public EdifactOneWayAgreement sendAgreement() { + return this.sendAgreement; + } + + /** + * Set the EDIFACT one-way send agreement. + * + * @param sendAgreement the sendAgreement value to set + * @return the EdifactAgreementContent object itself. + */ + public EdifactAgreementContent withSendAgreement(EdifactOneWayAgreement sendAgreement) { + this.sendAgreement = sendAgreement; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactCharacterSet.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactCharacterSet.java new file mode 100644 index 000000000000..07548563c335 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactCharacterSet.java @@ -0,0 +1,80 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for EdifactCharacterSet. + */ +public final class EdifactCharacterSet extends ExpandableStringEnum { + /** Static value NotSpecified for EdifactCharacterSet. */ + public static final EdifactCharacterSet NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value UNOB for EdifactCharacterSet. */ + public static final EdifactCharacterSet UNOB = fromString("UNOB"); + + /** Static value UNOA for EdifactCharacterSet. */ + public static final EdifactCharacterSet UNOA = fromString("UNOA"); + + /** Static value UNOC for EdifactCharacterSet. */ + public static final EdifactCharacterSet UNOC = fromString("UNOC"); + + /** Static value UNOD for EdifactCharacterSet. */ + public static final EdifactCharacterSet UNOD = fromString("UNOD"); + + /** Static value UNOE for EdifactCharacterSet. */ + public static final EdifactCharacterSet UNOE = fromString("UNOE"); + + /** Static value UNOF for EdifactCharacterSet. */ + public static final EdifactCharacterSet UNOF = fromString("UNOF"); + + /** Static value UNOG for EdifactCharacterSet. */ + public static final EdifactCharacterSet UNOG = fromString("UNOG"); + + /** Static value UNOH for EdifactCharacterSet. */ + public static final EdifactCharacterSet UNOH = fromString("UNOH"); + + /** Static value UNOI for EdifactCharacterSet. */ + public static final EdifactCharacterSet UNOI = fromString("UNOI"); + + /** Static value UNOJ for EdifactCharacterSet. */ + public static final EdifactCharacterSet UNOJ = fromString("UNOJ"); + + /** Static value UNOK for EdifactCharacterSet. */ + public static final EdifactCharacterSet UNOK = fromString("UNOK"); + + /** Static value UNOX for EdifactCharacterSet. */ + public static final EdifactCharacterSet UNOX = fromString("UNOX"); + + /** Static value UNOY for EdifactCharacterSet. */ + public static final EdifactCharacterSet UNOY = fromString("UNOY"); + + /** Static value KECA for EdifactCharacterSet. */ + public static final EdifactCharacterSet KECA = fromString("KECA"); + + /** + * Creates or finds a EdifactCharacterSet from its string representation. + * @param name a name to look for + * @return the corresponding EdifactCharacterSet + */ + @JsonCreator + public static EdifactCharacterSet fromString(String name) { + return fromString(name, EdifactCharacterSet.class); + } + + /** + * @return known EdifactCharacterSet values + */ + public static Collection values() { + return values(EdifactCharacterSet.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactDecimalIndicator.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactDecimalIndicator.java new file mode 100644 index 000000000000..9cd737141701 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactDecimalIndicator.java @@ -0,0 +1,56 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +/** + * Defines values for EdifactDecimalIndicator. + */ +public enum EdifactDecimalIndicator { + /** Enum value NotSpecified. */ + NOT_SPECIFIED("NotSpecified"), + + /** Enum value Comma. */ + COMMA("Comma"), + + /** Enum value Decimal. */ + DECIMAL("Decimal"); + + /** The actual serialized value for a EdifactDecimalIndicator instance. */ + private String value; + + EdifactDecimalIndicator(String value) { + this.value = value; + } + + /** + * Parses a serialized value to a EdifactDecimalIndicator instance. + * + * @param value the serialized value to parse. + * @return the parsed EdifactDecimalIndicator object, or null if unable to parse. + */ + @JsonCreator + public static EdifactDecimalIndicator fromString(String value) { + EdifactDecimalIndicator[] items = EdifactDecimalIndicator.values(); + for (EdifactDecimalIndicator item : items) { + if (item.toString().equalsIgnoreCase(value)) { + return item; + } + } + return null; + } + + @JsonValue + @Override + public String toString() { + return this.value; + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactDelimiterOverride.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactDelimiterOverride.java new file mode 100644 index 000000000000..35a2e36ee57d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactDelimiterOverride.java @@ -0,0 +1,331 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact delimiter override settings. + */ +public class EdifactDelimiterOverride { + /** + * The message id. + */ + @JsonProperty(value = "messageId") + private String messageId; + + /** + * The message version. + */ + @JsonProperty(value = "messageVersion") + private String messageVersion; + + /** + * The message release. + */ + @JsonProperty(value = "messageRelease") + private String messageRelease; + + /** + * The data element separator. + */ + @JsonProperty(value = "dataElementSeparator", required = true) + private int dataElementSeparator; + + /** + * The component separator. + */ + @JsonProperty(value = "componentSeparator", required = true) + private int componentSeparator; + + /** + * The segment terminator. + */ + @JsonProperty(value = "segmentTerminator", required = true) + private int segmentTerminator; + + /** + * The repetition separator. + */ + @JsonProperty(value = "repetitionSeparator", required = true) + private int repetitionSeparator; + + /** + * The segment terminator suffix. Possible values include: 'NotSpecified', + * 'None', 'CR', 'LF', 'CRLF'. + */ + @JsonProperty(value = "segmentTerminatorSuffix", required = true) + private SegmentTerminatorSuffix segmentTerminatorSuffix; + + /** + * The decimal point indicator. Possible values include: 'NotSpecified', + * 'Comma', 'Decimal'. + */ + @JsonProperty(value = "decimalPointIndicator", required = true) + private EdifactDecimalIndicator decimalPointIndicator; + + /** + * The release indicator. + */ + @JsonProperty(value = "releaseIndicator", required = true) + private int releaseIndicator; + + /** + * The message association assigned code. + */ + @JsonProperty(value = "messageAssociationAssignedCode") + private String messageAssociationAssignedCode; + + /** + * The target namespace on which this delimiter settings has to be applied. + */ + @JsonProperty(value = "targetNamespace") + private String targetNamespace; + + /** + * Get the message id. + * + * @return the messageId value + */ + public String messageId() { + return this.messageId; + } + + /** + * Set the message id. + * + * @param messageId the messageId value to set + * @return the EdifactDelimiterOverride object itself. + */ + public EdifactDelimiterOverride withMessageId(String messageId) { + this.messageId = messageId; + return this; + } + + /** + * Get the message version. + * + * @return the messageVersion value + */ + public String messageVersion() { + return this.messageVersion; + } + + /** + * Set the message version. + * + * @param messageVersion the messageVersion value to set + * @return the EdifactDelimiterOverride object itself. + */ + public EdifactDelimiterOverride withMessageVersion(String messageVersion) { + this.messageVersion = messageVersion; + return this; + } + + /** + * Get the message release. + * + * @return the messageRelease value + */ + public String messageRelease() { + return this.messageRelease; + } + + /** + * Set the message release. + * + * @param messageRelease the messageRelease value to set + * @return the EdifactDelimiterOverride object itself. + */ + public EdifactDelimiterOverride withMessageRelease(String messageRelease) { + this.messageRelease = messageRelease; + return this; + } + + /** + * Get the data element separator. + * + * @return the dataElementSeparator value + */ + public int dataElementSeparator() { + return this.dataElementSeparator; + } + + /** + * Set the data element separator. + * + * @param dataElementSeparator the dataElementSeparator value to set + * @return the EdifactDelimiterOverride object itself. + */ + public EdifactDelimiterOverride withDataElementSeparator(int dataElementSeparator) { + this.dataElementSeparator = dataElementSeparator; + return this; + } + + /** + * Get the component separator. + * + * @return the componentSeparator value + */ + public int componentSeparator() { + return this.componentSeparator; + } + + /** + * Set the component separator. + * + * @param componentSeparator the componentSeparator value to set + * @return the EdifactDelimiterOverride object itself. + */ + public EdifactDelimiterOverride withComponentSeparator(int componentSeparator) { + this.componentSeparator = componentSeparator; + return this; + } + + /** + * Get the segment terminator. + * + * @return the segmentTerminator value + */ + public int segmentTerminator() { + return this.segmentTerminator; + } + + /** + * Set the segment terminator. + * + * @param segmentTerminator the segmentTerminator value to set + * @return the EdifactDelimiterOverride object itself. + */ + public EdifactDelimiterOverride withSegmentTerminator(int segmentTerminator) { + this.segmentTerminator = segmentTerminator; + return this; + } + + /** + * Get the repetition separator. + * + * @return the repetitionSeparator value + */ + public int repetitionSeparator() { + return this.repetitionSeparator; + } + + /** + * Set the repetition separator. + * + * @param repetitionSeparator the repetitionSeparator value to set + * @return the EdifactDelimiterOverride object itself. + */ + public EdifactDelimiterOverride withRepetitionSeparator(int repetitionSeparator) { + this.repetitionSeparator = repetitionSeparator; + return this; + } + + /** + * Get the segment terminator suffix. Possible values include: 'NotSpecified', 'None', 'CR', 'LF', 'CRLF'. + * + * @return the segmentTerminatorSuffix value + */ + public SegmentTerminatorSuffix segmentTerminatorSuffix() { + return this.segmentTerminatorSuffix; + } + + /** + * Set the segment terminator suffix. Possible values include: 'NotSpecified', 'None', 'CR', 'LF', 'CRLF'. + * + * @param segmentTerminatorSuffix the segmentTerminatorSuffix value to set + * @return the EdifactDelimiterOverride object itself. + */ + public EdifactDelimiterOverride withSegmentTerminatorSuffix(SegmentTerminatorSuffix segmentTerminatorSuffix) { + this.segmentTerminatorSuffix = segmentTerminatorSuffix; + return this; + } + + /** + * Get the decimal point indicator. Possible values include: 'NotSpecified', 'Comma', 'Decimal'. + * + * @return the decimalPointIndicator value + */ + public EdifactDecimalIndicator decimalPointIndicator() { + return this.decimalPointIndicator; + } + + /** + * Set the decimal point indicator. Possible values include: 'NotSpecified', 'Comma', 'Decimal'. + * + * @param decimalPointIndicator the decimalPointIndicator value to set + * @return the EdifactDelimiterOverride object itself. + */ + public EdifactDelimiterOverride withDecimalPointIndicator(EdifactDecimalIndicator decimalPointIndicator) { + this.decimalPointIndicator = decimalPointIndicator; + return this; + } + + /** + * Get the release indicator. + * + * @return the releaseIndicator value + */ + public int releaseIndicator() { + return this.releaseIndicator; + } + + /** + * Set the release indicator. + * + * @param releaseIndicator the releaseIndicator value to set + * @return the EdifactDelimiterOverride object itself. + */ + public EdifactDelimiterOverride withReleaseIndicator(int releaseIndicator) { + this.releaseIndicator = releaseIndicator; + return this; + } + + /** + * Get the message association assigned code. + * + * @return the messageAssociationAssignedCode value + */ + public String messageAssociationAssignedCode() { + return this.messageAssociationAssignedCode; + } + + /** + * Set the message association assigned code. + * + * @param messageAssociationAssignedCode the messageAssociationAssignedCode value to set + * @return the EdifactDelimiterOverride object itself. + */ + public EdifactDelimiterOverride withMessageAssociationAssignedCode(String messageAssociationAssignedCode) { + this.messageAssociationAssignedCode = messageAssociationAssignedCode; + return this; + } + + /** + * Get the target namespace on which this delimiter settings has to be applied. + * + * @return the targetNamespace value + */ + public String targetNamespace() { + return this.targetNamespace; + } + + /** + * Set the target namespace on which this delimiter settings has to be applied. + * + * @param targetNamespace the targetNamespace value to set + * @return the EdifactDelimiterOverride object itself. + */ + public EdifactDelimiterOverride withTargetNamespace(String targetNamespace) { + this.targetNamespace = targetNamespace; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactEnvelopeOverride.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactEnvelopeOverride.java new file mode 100644 index 000000000000..6c9f30ac0967 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactEnvelopeOverride.java @@ -0,0 +1,408 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact envelope override settings. + */ +public class EdifactEnvelopeOverride { + /** + * The message id on which this envelope settings has to be applied. + */ + @JsonProperty(value = "messageId") + private String messageId; + + /** + * The message version on which this envelope settings has to be applied. + */ + @JsonProperty(value = "messageVersion") + private String messageVersion; + + /** + * The message release version on which this envelope settings has to be + * applied. + */ + @JsonProperty(value = "messageRelease") + private String messageRelease; + + /** + * The message association assigned code. + */ + @JsonProperty(value = "messageAssociationAssignedCode") + private String messageAssociationAssignedCode; + + /** + * The target namespace on which this envelope settings has to be applied. + */ + @JsonProperty(value = "targetNamespace") + private String targetNamespace; + + /** + * The functional group id. + */ + @JsonProperty(value = "functionalGroupId") + private String functionalGroupId; + + /** + * The sender application qualifier. + */ + @JsonProperty(value = "senderApplicationQualifier") + private String senderApplicationQualifier; + + /** + * The sender application id. + */ + @JsonProperty(value = "senderApplicationId") + private String senderApplicationId; + + /** + * The receiver application qualifier. + */ + @JsonProperty(value = "receiverApplicationQualifier") + private String receiverApplicationQualifier; + + /** + * The receiver application id. + */ + @JsonProperty(value = "receiverApplicationId") + private String receiverApplicationId; + + /** + * The controlling agency code. + */ + @JsonProperty(value = "controllingAgencyCode") + private String controllingAgencyCode; + + /** + * The group header message version. + */ + @JsonProperty(value = "groupHeaderMessageVersion") + private String groupHeaderMessageVersion; + + /** + * The group header message release. + */ + @JsonProperty(value = "groupHeaderMessageRelease") + private String groupHeaderMessageRelease; + + /** + * The association assigned code. + */ + @JsonProperty(value = "associationAssignedCode") + private String associationAssignedCode; + + /** + * The application password. + */ + @JsonProperty(value = "applicationPassword") + private String applicationPassword; + + /** + * Get the message id on which this envelope settings has to be applied. + * + * @return the messageId value + */ + public String messageId() { + return this.messageId; + } + + /** + * Set the message id on which this envelope settings has to be applied. + * + * @param messageId the messageId value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withMessageId(String messageId) { + this.messageId = messageId; + return this; + } + + /** + * Get the message version on which this envelope settings has to be applied. + * + * @return the messageVersion value + */ + public String messageVersion() { + return this.messageVersion; + } + + /** + * Set the message version on which this envelope settings has to be applied. + * + * @param messageVersion the messageVersion value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withMessageVersion(String messageVersion) { + this.messageVersion = messageVersion; + return this; + } + + /** + * Get the message release version on which this envelope settings has to be applied. + * + * @return the messageRelease value + */ + public String messageRelease() { + return this.messageRelease; + } + + /** + * Set the message release version on which this envelope settings has to be applied. + * + * @param messageRelease the messageRelease value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withMessageRelease(String messageRelease) { + this.messageRelease = messageRelease; + return this; + } + + /** + * Get the message association assigned code. + * + * @return the messageAssociationAssignedCode value + */ + public String messageAssociationAssignedCode() { + return this.messageAssociationAssignedCode; + } + + /** + * Set the message association assigned code. + * + * @param messageAssociationAssignedCode the messageAssociationAssignedCode value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withMessageAssociationAssignedCode(String messageAssociationAssignedCode) { + this.messageAssociationAssignedCode = messageAssociationAssignedCode; + return this; + } + + /** + * Get the target namespace on which this envelope settings has to be applied. + * + * @return the targetNamespace value + */ + public String targetNamespace() { + return this.targetNamespace; + } + + /** + * Set the target namespace on which this envelope settings has to be applied. + * + * @param targetNamespace the targetNamespace value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withTargetNamespace(String targetNamespace) { + this.targetNamespace = targetNamespace; + return this; + } + + /** + * Get the functional group id. + * + * @return the functionalGroupId value + */ + public String functionalGroupId() { + return this.functionalGroupId; + } + + /** + * Set the functional group id. + * + * @param functionalGroupId the functionalGroupId value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withFunctionalGroupId(String functionalGroupId) { + this.functionalGroupId = functionalGroupId; + return this; + } + + /** + * Get the sender application qualifier. + * + * @return the senderApplicationQualifier value + */ + public String senderApplicationQualifier() { + return this.senderApplicationQualifier; + } + + /** + * Set the sender application qualifier. + * + * @param senderApplicationQualifier the senderApplicationQualifier value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withSenderApplicationQualifier(String senderApplicationQualifier) { + this.senderApplicationQualifier = senderApplicationQualifier; + return this; + } + + /** + * Get the sender application id. + * + * @return the senderApplicationId value + */ + public String senderApplicationId() { + return this.senderApplicationId; + } + + /** + * Set the sender application id. + * + * @param senderApplicationId the senderApplicationId value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withSenderApplicationId(String senderApplicationId) { + this.senderApplicationId = senderApplicationId; + return this; + } + + /** + * Get the receiver application qualifier. + * + * @return the receiverApplicationQualifier value + */ + public String receiverApplicationQualifier() { + return this.receiverApplicationQualifier; + } + + /** + * Set the receiver application qualifier. + * + * @param receiverApplicationQualifier the receiverApplicationQualifier value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withReceiverApplicationQualifier(String receiverApplicationQualifier) { + this.receiverApplicationQualifier = receiverApplicationQualifier; + return this; + } + + /** + * Get the receiver application id. + * + * @return the receiverApplicationId value + */ + public String receiverApplicationId() { + return this.receiverApplicationId; + } + + /** + * Set the receiver application id. + * + * @param receiverApplicationId the receiverApplicationId value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withReceiverApplicationId(String receiverApplicationId) { + this.receiverApplicationId = receiverApplicationId; + return this; + } + + /** + * Get the controlling agency code. + * + * @return the controllingAgencyCode value + */ + public String controllingAgencyCode() { + return this.controllingAgencyCode; + } + + /** + * Set the controlling agency code. + * + * @param controllingAgencyCode the controllingAgencyCode value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withControllingAgencyCode(String controllingAgencyCode) { + this.controllingAgencyCode = controllingAgencyCode; + return this; + } + + /** + * Get the group header message version. + * + * @return the groupHeaderMessageVersion value + */ + public String groupHeaderMessageVersion() { + return this.groupHeaderMessageVersion; + } + + /** + * Set the group header message version. + * + * @param groupHeaderMessageVersion the groupHeaderMessageVersion value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withGroupHeaderMessageVersion(String groupHeaderMessageVersion) { + this.groupHeaderMessageVersion = groupHeaderMessageVersion; + return this; + } + + /** + * Get the group header message release. + * + * @return the groupHeaderMessageRelease value + */ + public String groupHeaderMessageRelease() { + return this.groupHeaderMessageRelease; + } + + /** + * Set the group header message release. + * + * @param groupHeaderMessageRelease the groupHeaderMessageRelease value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withGroupHeaderMessageRelease(String groupHeaderMessageRelease) { + this.groupHeaderMessageRelease = groupHeaderMessageRelease; + return this; + } + + /** + * Get the association assigned code. + * + * @return the associationAssignedCode value + */ + public String associationAssignedCode() { + return this.associationAssignedCode; + } + + /** + * Set the association assigned code. + * + * @param associationAssignedCode the associationAssignedCode value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withAssociationAssignedCode(String associationAssignedCode) { + this.associationAssignedCode = associationAssignedCode; + return this; + } + + /** + * Get the application password. + * + * @return the applicationPassword value + */ + public String applicationPassword() { + return this.applicationPassword; + } + + /** + * Set the application password. + * + * @param applicationPassword the applicationPassword value to set + * @return the EdifactEnvelopeOverride object itself. + */ + public EdifactEnvelopeOverride withApplicationPassword(String applicationPassword) { + this.applicationPassword = applicationPassword; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactEnvelopeSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactEnvelopeSettings.java new file mode 100644 index 000000000000..c1f28cc68d65 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactEnvelopeSettings.java @@ -0,0 +1,1084 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact agreement envelope settings. + */ +public class EdifactEnvelopeSettings { + /** + * The group association assigned code. + */ + @JsonProperty(value = "groupAssociationAssignedCode") + private String groupAssociationAssignedCode; + + /** + * The communication agreement id. + */ + @JsonProperty(value = "communicationAgreementId") + private String communicationAgreementId; + + /** + * The value indicating whether to apply delimiter string advice. + */ + @JsonProperty(value = "applyDelimiterStringAdvice", required = true) + private boolean applyDelimiterStringAdvice; + + /** + * The value indicating whether to create grouping segments. + */ + @JsonProperty(value = "createGroupingSegments", required = true) + private boolean createGroupingSegments; + + /** + * The value indicating whether to enable default group headers. + */ + @JsonProperty(value = "enableDefaultGroupHeaders", required = true) + private boolean enableDefaultGroupHeaders; + + /** + * The recipient reference password value. + */ + @JsonProperty(value = "recipientReferencePasswordValue") + private String recipientReferencePasswordValue; + + /** + * The recipient reference password qualifier. + */ + @JsonProperty(value = "recipientReferencePasswordQualifier") + private String recipientReferencePasswordQualifier; + + /** + * The application reference id. + */ + @JsonProperty(value = "applicationReferenceId") + private String applicationReferenceId; + + /** + * The processing priority code. + */ + @JsonProperty(value = "processingPriorityCode") + private String processingPriorityCode; + + /** + * The interchange control number lower bound. + */ + @JsonProperty(value = "interchangeControlNumberLowerBound", required = true) + private long interchangeControlNumberLowerBound; + + /** + * The interchange control number upper bound. + */ + @JsonProperty(value = "interchangeControlNumberUpperBound", required = true) + private long interchangeControlNumberUpperBound; + + /** + * The value indicating whether to rollover interchange control number. + */ + @JsonProperty(value = "rolloverInterchangeControlNumber", required = true) + private boolean rolloverInterchangeControlNumber; + + /** + * The interchange control number prefix. + */ + @JsonProperty(value = "interchangeControlNumberPrefix") + private String interchangeControlNumberPrefix; + + /** + * The interchange control number suffix. + */ + @JsonProperty(value = "interchangeControlNumberSuffix") + private String interchangeControlNumberSuffix; + + /** + * The sender reverse routing address. + */ + @JsonProperty(value = "senderReverseRoutingAddress") + private String senderReverseRoutingAddress; + + /** + * The receiver reverse routing address. + */ + @JsonProperty(value = "receiverReverseRoutingAddress") + private String receiverReverseRoutingAddress; + + /** + * The functional group id. + */ + @JsonProperty(value = "functionalGroupId") + private String functionalGroupId; + + /** + * The group controlling agency code. + */ + @JsonProperty(value = "groupControllingAgencyCode") + private String groupControllingAgencyCode; + + /** + * The group message version. + */ + @JsonProperty(value = "groupMessageVersion") + private String groupMessageVersion; + + /** + * The group message release. + */ + @JsonProperty(value = "groupMessageRelease") + private String groupMessageRelease; + + /** + * The group control number lower bound. + */ + @JsonProperty(value = "groupControlNumberLowerBound", required = true) + private long groupControlNumberLowerBound; + + /** + * The group control number upper bound. + */ + @JsonProperty(value = "groupControlNumberUpperBound", required = true) + private long groupControlNumberUpperBound; + + /** + * The value indicating whether to rollover group control number. + */ + @JsonProperty(value = "rolloverGroupControlNumber", required = true) + private boolean rolloverGroupControlNumber; + + /** + * The group control number prefix. + */ + @JsonProperty(value = "groupControlNumberPrefix") + private String groupControlNumberPrefix; + + /** + * The group control number suffix. + */ + @JsonProperty(value = "groupControlNumberSuffix") + private String groupControlNumberSuffix; + + /** + * The group application receiver qualifier. + */ + @JsonProperty(value = "groupApplicationReceiverQualifier") + private String groupApplicationReceiverQualifier; + + /** + * The group application receiver id. + */ + @JsonProperty(value = "groupApplicationReceiverId") + private String groupApplicationReceiverId; + + /** + * The group application sender qualifier. + */ + @JsonProperty(value = "groupApplicationSenderQualifier") + private String groupApplicationSenderQualifier; + + /** + * The group application sender id. + */ + @JsonProperty(value = "groupApplicationSenderId") + private String groupApplicationSenderId; + + /** + * The group application password. + */ + @JsonProperty(value = "groupApplicationPassword") + private String groupApplicationPassword; + + /** + * The value indicating whether to overwrite existing transaction set + * control number. + */ + @JsonProperty(value = "overwriteExistingTransactionSetControlNumber", required = true) + private boolean overwriteExistingTransactionSetControlNumber; + + /** + * The transaction set control number prefix. + */ + @JsonProperty(value = "transactionSetControlNumberPrefix") + private String transactionSetControlNumberPrefix; + + /** + * The transaction set control number suffix. + */ + @JsonProperty(value = "transactionSetControlNumberSuffix") + private String transactionSetControlNumberSuffix; + + /** + * The transaction set control number lower bound. + */ + @JsonProperty(value = "transactionSetControlNumberLowerBound", required = true) + private long transactionSetControlNumberLowerBound; + + /** + * The transaction set control number upper bound. + */ + @JsonProperty(value = "transactionSetControlNumberUpperBound", required = true) + private long transactionSetControlNumberUpperBound; + + /** + * The value indicating whether to rollover transaction set control number. + */ + @JsonProperty(value = "rolloverTransactionSetControlNumber", required = true) + private boolean rolloverTransactionSetControlNumber; + + /** + * The value indicating whether the message is a test interchange. + */ + @JsonProperty(value = "isTestInterchange", required = true) + private boolean isTestInterchange; + + /** + * The sender internal identification. + */ + @JsonProperty(value = "senderInternalIdentification") + private String senderInternalIdentification; + + /** + * The sender internal sub identification. + */ + @JsonProperty(value = "senderInternalSubIdentification") + private String senderInternalSubIdentification; + + /** + * The receiver internal identification. + */ + @JsonProperty(value = "receiverInternalIdentification") + private String receiverInternalIdentification; + + /** + * The receiver internal sub identification. + */ + @JsonProperty(value = "receiverInternalSubIdentification") + private String receiverInternalSubIdentification; + + /** + * Get the group association assigned code. + * + * @return the groupAssociationAssignedCode value + */ + public String groupAssociationAssignedCode() { + return this.groupAssociationAssignedCode; + } + + /** + * Set the group association assigned code. + * + * @param groupAssociationAssignedCode the groupAssociationAssignedCode value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withGroupAssociationAssignedCode(String groupAssociationAssignedCode) { + this.groupAssociationAssignedCode = groupAssociationAssignedCode; + return this; + } + + /** + * Get the communication agreement id. + * + * @return the communicationAgreementId value + */ + public String communicationAgreementId() { + return this.communicationAgreementId; + } + + /** + * Set the communication agreement id. + * + * @param communicationAgreementId the communicationAgreementId value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withCommunicationAgreementId(String communicationAgreementId) { + this.communicationAgreementId = communicationAgreementId; + return this; + } + + /** + * Get the value indicating whether to apply delimiter string advice. + * + * @return the applyDelimiterStringAdvice value + */ + public boolean applyDelimiterStringAdvice() { + return this.applyDelimiterStringAdvice; + } + + /** + * Set the value indicating whether to apply delimiter string advice. + * + * @param applyDelimiterStringAdvice the applyDelimiterStringAdvice value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withApplyDelimiterStringAdvice(boolean applyDelimiterStringAdvice) { + this.applyDelimiterStringAdvice = applyDelimiterStringAdvice; + return this; + } + + /** + * Get the value indicating whether to create grouping segments. + * + * @return the createGroupingSegments value + */ + public boolean createGroupingSegments() { + return this.createGroupingSegments; + } + + /** + * Set the value indicating whether to create grouping segments. + * + * @param createGroupingSegments the createGroupingSegments value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withCreateGroupingSegments(boolean createGroupingSegments) { + this.createGroupingSegments = createGroupingSegments; + return this; + } + + /** + * Get the value indicating whether to enable default group headers. + * + * @return the enableDefaultGroupHeaders value + */ + public boolean enableDefaultGroupHeaders() { + return this.enableDefaultGroupHeaders; + } + + /** + * Set the value indicating whether to enable default group headers. + * + * @param enableDefaultGroupHeaders the enableDefaultGroupHeaders value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withEnableDefaultGroupHeaders(boolean enableDefaultGroupHeaders) { + this.enableDefaultGroupHeaders = enableDefaultGroupHeaders; + return this; + } + + /** + * Get the recipient reference password value. + * + * @return the recipientReferencePasswordValue value + */ + public String recipientReferencePasswordValue() { + return this.recipientReferencePasswordValue; + } + + /** + * Set the recipient reference password value. + * + * @param recipientReferencePasswordValue the recipientReferencePasswordValue value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withRecipientReferencePasswordValue(String recipientReferencePasswordValue) { + this.recipientReferencePasswordValue = recipientReferencePasswordValue; + return this; + } + + /** + * Get the recipient reference password qualifier. + * + * @return the recipientReferencePasswordQualifier value + */ + public String recipientReferencePasswordQualifier() { + return this.recipientReferencePasswordQualifier; + } + + /** + * Set the recipient reference password qualifier. + * + * @param recipientReferencePasswordQualifier the recipientReferencePasswordQualifier value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withRecipientReferencePasswordQualifier(String recipientReferencePasswordQualifier) { + this.recipientReferencePasswordQualifier = recipientReferencePasswordQualifier; + return this; + } + + /** + * Get the application reference id. + * + * @return the applicationReferenceId value + */ + public String applicationReferenceId() { + return this.applicationReferenceId; + } + + /** + * Set the application reference id. + * + * @param applicationReferenceId the applicationReferenceId value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withApplicationReferenceId(String applicationReferenceId) { + this.applicationReferenceId = applicationReferenceId; + return this; + } + + /** + * Get the processing priority code. + * + * @return the processingPriorityCode value + */ + public String processingPriorityCode() { + return this.processingPriorityCode; + } + + /** + * Set the processing priority code. + * + * @param processingPriorityCode the processingPriorityCode value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withProcessingPriorityCode(String processingPriorityCode) { + this.processingPriorityCode = processingPriorityCode; + return this; + } + + /** + * Get the interchange control number lower bound. + * + * @return the interchangeControlNumberLowerBound value + */ + public long interchangeControlNumberLowerBound() { + return this.interchangeControlNumberLowerBound; + } + + /** + * Set the interchange control number lower bound. + * + * @param interchangeControlNumberLowerBound the interchangeControlNumberLowerBound value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withInterchangeControlNumberLowerBound(long interchangeControlNumberLowerBound) { + this.interchangeControlNumberLowerBound = interchangeControlNumberLowerBound; + return this; + } + + /** + * Get the interchange control number upper bound. + * + * @return the interchangeControlNumberUpperBound value + */ + public long interchangeControlNumberUpperBound() { + return this.interchangeControlNumberUpperBound; + } + + /** + * Set the interchange control number upper bound. + * + * @param interchangeControlNumberUpperBound the interchangeControlNumberUpperBound value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withInterchangeControlNumberUpperBound(long interchangeControlNumberUpperBound) { + this.interchangeControlNumberUpperBound = interchangeControlNumberUpperBound; + return this; + } + + /** + * Get the value indicating whether to rollover interchange control number. + * + * @return the rolloverInterchangeControlNumber value + */ + public boolean rolloverInterchangeControlNumber() { + return this.rolloverInterchangeControlNumber; + } + + /** + * Set the value indicating whether to rollover interchange control number. + * + * @param rolloverInterchangeControlNumber the rolloverInterchangeControlNumber value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withRolloverInterchangeControlNumber(boolean rolloverInterchangeControlNumber) { + this.rolloverInterchangeControlNumber = rolloverInterchangeControlNumber; + return this; + } + + /** + * Get the interchange control number prefix. + * + * @return the interchangeControlNumberPrefix value + */ + public String interchangeControlNumberPrefix() { + return this.interchangeControlNumberPrefix; + } + + /** + * Set the interchange control number prefix. + * + * @param interchangeControlNumberPrefix the interchangeControlNumberPrefix value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withInterchangeControlNumberPrefix(String interchangeControlNumberPrefix) { + this.interchangeControlNumberPrefix = interchangeControlNumberPrefix; + return this; + } + + /** + * Get the interchange control number suffix. + * + * @return the interchangeControlNumberSuffix value + */ + public String interchangeControlNumberSuffix() { + return this.interchangeControlNumberSuffix; + } + + /** + * Set the interchange control number suffix. + * + * @param interchangeControlNumberSuffix the interchangeControlNumberSuffix value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withInterchangeControlNumberSuffix(String interchangeControlNumberSuffix) { + this.interchangeControlNumberSuffix = interchangeControlNumberSuffix; + return this; + } + + /** + * Get the sender reverse routing address. + * + * @return the senderReverseRoutingAddress value + */ + public String senderReverseRoutingAddress() { + return this.senderReverseRoutingAddress; + } + + /** + * Set the sender reverse routing address. + * + * @param senderReverseRoutingAddress the senderReverseRoutingAddress value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withSenderReverseRoutingAddress(String senderReverseRoutingAddress) { + this.senderReverseRoutingAddress = senderReverseRoutingAddress; + return this; + } + + /** + * Get the receiver reverse routing address. + * + * @return the receiverReverseRoutingAddress value + */ + public String receiverReverseRoutingAddress() { + return this.receiverReverseRoutingAddress; + } + + /** + * Set the receiver reverse routing address. + * + * @param receiverReverseRoutingAddress the receiverReverseRoutingAddress value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withReceiverReverseRoutingAddress(String receiverReverseRoutingAddress) { + this.receiverReverseRoutingAddress = receiverReverseRoutingAddress; + return this; + } + + /** + * Get the functional group id. + * + * @return the functionalGroupId value + */ + public String functionalGroupId() { + return this.functionalGroupId; + } + + /** + * Set the functional group id. + * + * @param functionalGroupId the functionalGroupId value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withFunctionalGroupId(String functionalGroupId) { + this.functionalGroupId = functionalGroupId; + return this; + } + + /** + * Get the group controlling agency code. + * + * @return the groupControllingAgencyCode value + */ + public String groupControllingAgencyCode() { + return this.groupControllingAgencyCode; + } + + /** + * Set the group controlling agency code. + * + * @param groupControllingAgencyCode the groupControllingAgencyCode value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withGroupControllingAgencyCode(String groupControllingAgencyCode) { + this.groupControllingAgencyCode = groupControllingAgencyCode; + return this; + } + + /** + * Get the group message version. + * + * @return the groupMessageVersion value + */ + public String groupMessageVersion() { + return this.groupMessageVersion; + } + + /** + * Set the group message version. + * + * @param groupMessageVersion the groupMessageVersion value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withGroupMessageVersion(String groupMessageVersion) { + this.groupMessageVersion = groupMessageVersion; + return this; + } + + /** + * Get the group message release. + * + * @return the groupMessageRelease value + */ + public String groupMessageRelease() { + return this.groupMessageRelease; + } + + /** + * Set the group message release. + * + * @param groupMessageRelease the groupMessageRelease value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withGroupMessageRelease(String groupMessageRelease) { + this.groupMessageRelease = groupMessageRelease; + return this; + } + + /** + * Get the group control number lower bound. + * + * @return the groupControlNumberLowerBound value + */ + public long groupControlNumberLowerBound() { + return this.groupControlNumberLowerBound; + } + + /** + * Set the group control number lower bound. + * + * @param groupControlNumberLowerBound the groupControlNumberLowerBound value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withGroupControlNumberLowerBound(long groupControlNumberLowerBound) { + this.groupControlNumberLowerBound = groupControlNumberLowerBound; + return this; + } + + /** + * Get the group control number upper bound. + * + * @return the groupControlNumberUpperBound value + */ + public long groupControlNumberUpperBound() { + return this.groupControlNumberUpperBound; + } + + /** + * Set the group control number upper bound. + * + * @param groupControlNumberUpperBound the groupControlNumberUpperBound value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withGroupControlNumberUpperBound(long groupControlNumberUpperBound) { + this.groupControlNumberUpperBound = groupControlNumberUpperBound; + return this; + } + + /** + * Get the value indicating whether to rollover group control number. + * + * @return the rolloverGroupControlNumber value + */ + public boolean rolloverGroupControlNumber() { + return this.rolloverGroupControlNumber; + } + + /** + * Set the value indicating whether to rollover group control number. + * + * @param rolloverGroupControlNumber the rolloverGroupControlNumber value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withRolloverGroupControlNumber(boolean rolloverGroupControlNumber) { + this.rolloverGroupControlNumber = rolloverGroupControlNumber; + return this; + } + + /** + * Get the group control number prefix. + * + * @return the groupControlNumberPrefix value + */ + public String groupControlNumberPrefix() { + return this.groupControlNumberPrefix; + } + + /** + * Set the group control number prefix. + * + * @param groupControlNumberPrefix the groupControlNumberPrefix value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withGroupControlNumberPrefix(String groupControlNumberPrefix) { + this.groupControlNumberPrefix = groupControlNumberPrefix; + return this; + } + + /** + * Get the group control number suffix. + * + * @return the groupControlNumberSuffix value + */ + public String groupControlNumberSuffix() { + return this.groupControlNumberSuffix; + } + + /** + * Set the group control number suffix. + * + * @param groupControlNumberSuffix the groupControlNumberSuffix value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withGroupControlNumberSuffix(String groupControlNumberSuffix) { + this.groupControlNumberSuffix = groupControlNumberSuffix; + return this; + } + + /** + * Get the group application receiver qualifier. + * + * @return the groupApplicationReceiverQualifier value + */ + public String groupApplicationReceiverQualifier() { + return this.groupApplicationReceiverQualifier; + } + + /** + * Set the group application receiver qualifier. + * + * @param groupApplicationReceiverQualifier the groupApplicationReceiverQualifier value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withGroupApplicationReceiverQualifier(String groupApplicationReceiverQualifier) { + this.groupApplicationReceiverQualifier = groupApplicationReceiverQualifier; + return this; + } + + /** + * Get the group application receiver id. + * + * @return the groupApplicationReceiverId value + */ + public String groupApplicationReceiverId() { + return this.groupApplicationReceiverId; + } + + /** + * Set the group application receiver id. + * + * @param groupApplicationReceiverId the groupApplicationReceiverId value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withGroupApplicationReceiverId(String groupApplicationReceiverId) { + this.groupApplicationReceiverId = groupApplicationReceiverId; + return this; + } + + /** + * Get the group application sender qualifier. + * + * @return the groupApplicationSenderQualifier value + */ + public String groupApplicationSenderQualifier() { + return this.groupApplicationSenderQualifier; + } + + /** + * Set the group application sender qualifier. + * + * @param groupApplicationSenderQualifier the groupApplicationSenderQualifier value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withGroupApplicationSenderQualifier(String groupApplicationSenderQualifier) { + this.groupApplicationSenderQualifier = groupApplicationSenderQualifier; + return this; + } + + /** + * Get the group application sender id. + * + * @return the groupApplicationSenderId value + */ + public String groupApplicationSenderId() { + return this.groupApplicationSenderId; + } + + /** + * Set the group application sender id. + * + * @param groupApplicationSenderId the groupApplicationSenderId value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withGroupApplicationSenderId(String groupApplicationSenderId) { + this.groupApplicationSenderId = groupApplicationSenderId; + return this; + } + + /** + * Get the group application password. + * + * @return the groupApplicationPassword value + */ + public String groupApplicationPassword() { + return this.groupApplicationPassword; + } + + /** + * Set the group application password. + * + * @param groupApplicationPassword the groupApplicationPassword value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withGroupApplicationPassword(String groupApplicationPassword) { + this.groupApplicationPassword = groupApplicationPassword; + return this; + } + + /** + * Get the value indicating whether to overwrite existing transaction set control number. + * + * @return the overwriteExistingTransactionSetControlNumber value + */ + public boolean overwriteExistingTransactionSetControlNumber() { + return this.overwriteExistingTransactionSetControlNumber; + } + + /** + * Set the value indicating whether to overwrite existing transaction set control number. + * + * @param overwriteExistingTransactionSetControlNumber the overwriteExistingTransactionSetControlNumber value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withOverwriteExistingTransactionSetControlNumber(boolean overwriteExistingTransactionSetControlNumber) { + this.overwriteExistingTransactionSetControlNumber = overwriteExistingTransactionSetControlNumber; + return this; + } + + /** + * Get the transaction set control number prefix. + * + * @return the transactionSetControlNumberPrefix value + */ + public String transactionSetControlNumberPrefix() { + return this.transactionSetControlNumberPrefix; + } + + /** + * Set the transaction set control number prefix. + * + * @param transactionSetControlNumberPrefix the transactionSetControlNumberPrefix value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withTransactionSetControlNumberPrefix(String transactionSetControlNumberPrefix) { + this.transactionSetControlNumberPrefix = transactionSetControlNumberPrefix; + return this; + } + + /** + * Get the transaction set control number suffix. + * + * @return the transactionSetControlNumberSuffix value + */ + public String transactionSetControlNumberSuffix() { + return this.transactionSetControlNumberSuffix; + } + + /** + * Set the transaction set control number suffix. + * + * @param transactionSetControlNumberSuffix the transactionSetControlNumberSuffix value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withTransactionSetControlNumberSuffix(String transactionSetControlNumberSuffix) { + this.transactionSetControlNumberSuffix = transactionSetControlNumberSuffix; + return this; + } + + /** + * Get the transaction set control number lower bound. + * + * @return the transactionSetControlNumberLowerBound value + */ + public long transactionSetControlNumberLowerBound() { + return this.transactionSetControlNumberLowerBound; + } + + /** + * Set the transaction set control number lower bound. + * + * @param transactionSetControlNumberLowerBound the transactionSetControlNumberLowerBound value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withTransactionSetControlNumberLowerBound(long transactionSetControlNumberLowerBound) { + this.transactionSetControlNumberLowerBound = transactionSetControlNumberLowerBound; + return this; + } + + /** + * Get the transaction set control number upper bound. + * + * @return the transactionSetControlNumberUpperBound value + */ + public long transactionSetControlNumberUpperBound() { + return this.transactionSetControlNumberUpperBound; + } + + /** + * Set the transaction set control number upper bound. + * + * @param transactionSetControlNumberUpperBound the transactionSetControlNumberUpperBound value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withTransactionSetControlNumberUpperBound(long transactionSetControlNumberUpperBound) { + this.transactionSetControlNumberUpperBound = transactionSetControlNumberUpperBound; + return this; + } + + /** + * Get the value indicating whether to rollover transaction set control number. + * + * @return the rolloverTransactionSetControlNumber value + */ + public boolean rolloverTransactionSetControlNumber() { + return this.rolloverTransactionSetControlNumber; + } + + /** + * Set the value indicating whether to rollover transaction set control number. + * + * @param rolloverTransactionSetControlNumber the rolloverTransactionSetControlNumber value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withRolloverTransactionSetControlNumber(boolean rolloverTransactionSetControlNumber) { + this.rolloverTransactionSetControlNumber = rolloverTransactionSetControlNumber; + return this; + } + + /** + * Get the value indicating whether the message is a test interchange. + * + * @return the isTestInterchange value + */ + public boolean isTestInterchange() { + return this.isTestInterchange; + } + + /** + * Set the value indicating whether the message is a test interchange. + * + * @param isTestInterchange the isTestInterchange value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withIsTestInterchange(boolean isTestInterchange) { + this.isTestInterchange = isTestInterchange; + return this; + } + + /** + * Get the sender internal identification. + * + * @return the senderInternalIdentification value + */ + public String senderInternalIdentification() { + return this.senderInternalIdentification; + } + + /** + * Set the sender internal identification. + * + * @param senderInternalIdentification the senderInternalIdentification value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withSenderInternalIdentification(String senderInternalIdentification) { + this.senderInternalIdentification = senderInternalIdentification; + return this; + } + + /** + * Get the sender internal sub identification. + * + * @return the senderInternalSubIdentification value + */ + public String senderInternalSubIdentification() { + return this.senderInternalSubIdentification; + } + + /** + * Set the sender internal sub identification. + * + * @param senderInternalSubIdentification the senderInternalSubIdentification value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withSenderInternalSubIdentification(String senderInternalSubIdentification) { + this.senderInternalSubIdentification = senderInternalSubIdentification; + return this; + } + + /** + * Get the receiver internal identification. + * + * @return the receiverInternalIdentification value + */ + public String receiverInternalIdentification() { + return this.receiverInternalIdentification; + } + + /** + * Set the receiver internal identification. + * + * @param receiverInternalIdentification the receiverInternalIdentification value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withReceiverInternalIdentification(String receiverInternalIdentification) { + this.receiverInternalIdentification = receiverInternalIdentification; + return this; + } + + /** + * Get the receiver internal sub identification. + * + * @return the receiverInternalSubIdentification value + */ + public String receiverInternalSubIdentification() { + return this.receiverInternalSubIdentification; + } + + /** + * Set the receiver internal sub identification. + * + * @param receiverInternalSubIdentification the receiverInternalSubIdentification value to set + * @return the EdifactEnvelopeSettings object itself. + */ + public EdifactEnvelopeSettings withReceiverInternalSubIdentification(String receiverInternalSubIdentification) { + this.receiverInternalSubIdentification = receiverInternalSubIdentification; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactFramingSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactFramingSettings.java new file mode 100644 index 000000000000..3fcbd0d58ee2 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactFramingSettings.java @@ -0,0 +1,307 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact agreement framing settings. + */ +public class EdifactFramingSettings { + /** + * The service code list directory version. + */ + @JsonProperty(value = "serviceCodeListDirectoryVersion") + private String serviceCodeListDirectoryVersion; + + /** + * The character encoding. + */ + @JsonProperty(value = "characterEncoding") + private String characterEncoding; + + /** + * The protocol version. + */ + @JsonProperty(value = "protocolVersion", required = true) + private int protocolVersion; + + /** + * The data element separator. + */ + @JsonProperty(value = "dataElementSeparator", required = true) + private int dataElementSeparator; + + /** + * The component separator. + */ + @JsonProperty(value = "componentSeparator", required = true) + private int componentSeparator; + + /** + * The segment terminator. + */ + @JsonProperty(value = "segmentTerminator", required = true) + private int segmentTerminator; + + /** + * The release indicator. + */ + @JsonProperty(value = "releaseIndicator", required = true) + private int releaseIndicator; + + /** + * The repetition separator. + */ + @JsonProperty(value = "repetitionSeparator", required = true) + private int repetitionSeparator; + + /** + * The EDIFACT frame setting characterSet. Possible values include: + * 'NotSpecified', 'UNOB', 'UNOA', 'UNOC', 'UNOD', 'UNOE', 'UNOF', 'UNOG', + * 'UNOH', 'UNOI', 'UNOJ', 'UNOK', 'UNOX', 'UNOY', 'KECA'. + */ + @JsonProperty(value = "characterSet", required = true) + private EdifactCharacterSet characterSet; + + /** + * The EDIFACT frame setting decimal indicator. Possible values include: + * 'NotSpecified', 'Comma', 'Decimal'. + */ + @JsonProperty(value = "decimalPointIndicator", required = true) + private EdifactDecimalIndicator decimalPointIndicator; + + /** + * The EDIFACT frame setting segment terminator suffix. Possible values + * include: 'NotSpecified', 'None', 'CR', 'LF', 'CRLF'. + */ + @JsonProperty(value = "segmentTerminatorSuffix", required = true) + private SegmentTerminatorSuffix segmentTerminatorSuffix; + + /** + * Get the service code list directory version. + * + * @return the serviceCodeListDirectoryVersion value + */ + public String serviceCodeListDirectoryVersion() { + return this.serviceCodeListDirectoryVersion; + } + + /** + * Set the service code list directory version. + * + * @param serviceCodeListDirectoryVersion the serviceCodeListDirectoryVersion value to set + * @return the EdifactFramingSettings object itself. + */ + public EdifactFramingSettings withServiceCodeListDirectoryVersion(String serviceCodeListDirectoryVersion) { + this.serviceCodeListDirectoryVersion = serviceCodeListDirectoryVersion; + return this; + } + + /** + * Get the character encoding. + * + * @return the characterEncoding value + */ + public String characterEncoding() { + return this.characterEncoding; + } + + /** + * Set the character encoding. + * + * @param characterEncoding the characterEncoding value to set + * @return the EdifactFramingSettings object itself. + */ + public EdifactFramingSettings withCharacterEncoding(String characterEncoding) { + this.characterEncoding = characterEncoding; + return this; + } + + /** + * Get the protocol version. + * + * @return the protocolVersion value + */ + public int protocolVersion() { + return this.protocolVersion; + } + + /** + * Set the protocol version. + * + * @param protocolVersion the protocolVersion value to set + * @return the EdifactFramingSettings object itself. + */ + public EdifactFramingSettings withProtocolVersion(int protocolVersion) { + this.protocolVersion = protocolVersion; + return this; + } + + /** + * Get the data element separator. + * + * @return the dataElementSeparator value + */ + public int dataElementSeparator() { + return this.dataElementSeparator; + } + + /** + * Set the data element separator. + * + * @param dataElementSeparator the dataElementSeparator value to set + * @return the EdifactFramingSettings object itself. + */ + public EdifactFramingSettings withDataElementSeparator(int dataElementSeparator) { + this.dataElementSeparator = dataElementSeparator; + return this; + } + + /** + * Get the component separator. + * + * @return the componentSeparator value + */ + public int componentSeparator() { + return this.componentSeparator; + } + + /** + * Set the component separator. + * + * @param componentSeparator the componentSeparator value to set + * @return the EdifactFramingSettings object itself. + */ + public EdifactFramingSettings withComponentSeparator(int componentSeparator) { + this.componentSeparator = componentSeparator; + return this; + } + + /** + * Get the segment terminator. + * + * @return the segmentTerminator value + */ + public int segmentTerminator() { + return this.segmentTerminator; + } + + /** + * Set the segment terminator. + * + * @param segmentTerminator the segmentTerminator value to set + * @return the EdifactFramingSettings object itself. + */ + public EdifactFramingSettings withSegmentTerminator(int segmentTerminator) { + this.segmentTerminator = segmentTerminator; + return this; + } + + /** + * Get the release indicator. + * + * @return the releaseIndicator value + */ + public int releaseIndicator() { + return this.releaseIndicator; + } + + /** + * Set the release indicator. + * + * @param releaseIndicator the releaseIndicator value to set + * @return the EdifactFramingSettings object itself. + */ + public EdifactFramingSettings withReleaseIndicator(int releaseIndicator) { + this.releaseIndicator = releaseIndicator; + return this; + } + + /** + * Get the repetition separator. + * + * @return the repetitionSeparator value + */ + public int repetitionSeparator() { + return this.repetitionSeparator; + } + + /** + * Set the repetition separator. + * + * @param repetitionSeparator the repetitionSeparator value to set + * @return the EdifactFramingSettings object itself. + */ + public EdifactFramingSettings withRepetitionSeparator(int repetitionSeparator) { + this.repetitionSeparator = repetitionSeparator; + return this; + } + + /** + * Get the EDIFACT frame setting characterSet. Possible values include: 'NotSpecified', 'UNOB', 'UNOA', 'UNOC', 'UNOD', 'UNOE', 'UNOF', 'UNOG', 'UNOH', 'UNOI', 'UNOJ', 'UNOK', 'UNOX', 'UNOY', 'KECA'. + * + * @return the characterSet value + */ + public EdifactCharacterSet characterSet() { + return this.characterSet; + } + + /** + * Set the EDIFACT frame setting characterSet. Possible values include: 'NotSpecified', 'UNOB', 'UNOA', 'UNOC', 'UNOD', 'UNOE', 'UNOF', 'UNOG', 'UNOH', 'UNOI', 'UNOJ', 'UNOK', 'UNOX', 'UNOY', 'KECA'. + * + * @param characterSet the characterSet value to set + * @return the EdifactFramingSettings object itself. + */ + public EdifactFramingSettings withCharacterSet(EdifactCharacterSet characterSet) { + this.characterSet = characterSet; + return this; + } + + /** + * Get the EDIFACT frame setting decimal indicator. Possible values include: 'NotSpecified', 'Comma', 'Decimal'. + * + * @return the decimalPointIndicator value + */ + public EdifactDecimalIndicator decimalPointIndicator() { + return this.decimalPointIndicator; + } + + /** + * Set the EDIFACT frame setting decimal indicator. Possible values include: 'NotSpecified', 'Comma', 'Decimal'. + * + * @param decimalPointIndicator the decimalPointIndicator value to set + * @return the EdifactFramingSettings object itself. + */ + public EdifactFramingSettings withDecimalPointIndicator(EdifactDecimalIndicator decimalPointIndicator) { + this.decimalPointIndicator = decimalPointIndicator; + return this; + } + + /** + * Get the EDIFACT frame setting segment terminator suffix. Possible values include: 'NotSpecified', 'None', 'CR', 'LF', 'CRLF'. + * + * @return the segmentTerminatorSuffix value + */ + public SegmentTerminatorSuffix segmentTerminatorSuffix() { + return this.segmentTerminatorSuffix; + } + + /** + * Set the EDIFACT frame setting segment terminator suffix. Possible values include: 'NotSpecified', 'None', 'CR', 'LF', 'CRLF'. + * + * @param segmentTerminatorSuffix the segmentTerminatorSuffix value to set + * @return the EdifactFramingSettings object itself. + */ + public EdifactFramingSettings withSegmentTerminatorSuffix(SegmentTerminatorSuffix segmentTerminatorSuffix) { + this.segmentTerminatorSuffix = segmentTerminatorSuffix; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactMessageFilter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactMessageFilter.java new file mode 100644 index 000000000000..4fd72ffa219a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactMessageFilter.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact message filter for odata query. + */ +public class EdifactMessageFilter { + /** + * The message filter type. Possible values include: 'NotSpecified', + * 'Include', 'Exclude'. + */ + @JsonProperty(value = "messageFilterType", required = true) + private MessageFilterType messageFilterType; + + /** + * Get the message filter type. Possible values include: 'NotSpecified', 'Include', 'Exclude'. + * + * @return the messageFilterType value + */ + public MessageFilterType messageFilterType() { + return this.messageFilterType; + } + + /** + * Set the message filter type. Possible values include: 'NotSpecified', 'Include', 'Exclude'. + * + * @param messageFilterType the messageFilterType value to set + * @return the EdifactMessageFilter object itself. + */ + public EdifactMessageFilter withMessageFilterType(MessageFilterType messageFilterType) { + this.messageFilterType = messageFilterType; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactMessageIdentifier.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactMessageIdentifier.java new file mode 100644 index 000000000000..3a026e99f684 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactMessageIdentifier.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact message identifier. + */ +public class EdifactMessageIdentifier { + /** + * The message id on which this envelope settings has to be applied. + */ + @JsonProperty(value = "messageId", required = true) + private String messageId; + + /** + * Get the message id on which this envelope settings has to be applied. + * + * @return the messageId value + */ + public String messageId() { + return this.messageId; + } + + /** + * Set the message id on which this envelope settings has to be applied. + * + * @param messageId the messageId value to set + * @return the EdifactMessageIdentifier object itself. + */ + public EdifactMessageIdentifier withMessageId(String messageId) { + this.messageId = messageId; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactOneWayAgreement.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactOneWayAgreement.java new file mode 100644 index 000000000000..1e18153ded74 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactOneWayAgreement.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact one way agreement. + */ +public class EdifactOneWayAgreement { + /** + * The sender business identity. + */ + @JsonProperty(value = "senderBusinessIdentity", required = true) + private BusinessIdentity senderBusinessIdentity; + + /** + * The receiver business identity. + */ + @JsonProperty(value = "receiverBusinessIdentity", required = true) + private BusinessIdentity receiverBusinessIdentity; + + /** + * The EDIFACT protocol settings. + */ + @JsonProperty(value = "protocolSettings", required = true) + private EdifactProtocolSettings protocolSettings; + + /** + * Get the sender business identity. + * + * @return the senderBusinessIdentity value + */ + public BusinessIdentity senderBusinessIdentity() { + return this.senderBusinessIdentity; + } + + /** + * Set the sender business identity. + * + * @param senderBusinessIdentity the senderBusinessIdentity value to set + * @return the EdifactOneWayAgreement object itself. + */ + public EdifactOneWayAgreement withSenderBusinessIdentity(BusinessIdentity senderBusinessIdentity) { + this.senderBusinessIdentity = senderBusinessIdentity; + return this; + } + + /** + * Get the receiver business identity. + * + * @return the receiverBusinessIdentity value + */ + public BusinessIdentity receiverBusinessIdentity() { + return this.receiverBusinessIdentity; + } + + /** + * Set the receiver business identity. + * + * @param receiverBusinessIdentity the receiverBusinessIdentity value to set + * @return the EdifactOneWayAgreement object itself. + */ + public EdifactOneWayAgreement withReceiverBusinessIdentity(BusinessIdentity receiverBusinessIdentity) { + this.receiverBusinessIdentity = receiverBusinessIdentity; + return this; + } + + /** + * Get the EDIFACT protocol settings. + * + * @return the protocolSettings value + */ + public EdifactProtocolSettings protocolSettings() { + return this.protocolSettings; + } + + /** + * Set the EDIFACT protocol settings. + * + * @param protocolSettings the protocolSettings value to set + * @return the EdifactOneWayAgreement object itself. + */ + public EdifactOneWayAgreement withProtocolSettings(EdifactProtocolSettings protocolSettings) { + this.protocolSettings = protocolSettings; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactProcessingSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactProcessingSettings.java new file mode 100644 index 000000000000..699b95d2da63 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactProcessingSettings.java @@ -0,0 +1,148 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact agreement protocol settings. + */ +public class EdifactProcessingSettings { + /** + * The value indicating whether to mask security information. + */ + @JsonProperty(value = "maskSecurityInfo", required = true) + private boolean maskSecurityInfo; + + /** + * The value indicating whether to preserve interchange. + */ + @JsonProperty(value = "preserveInterchange", required = true) + private boolean preserveInterchange; + + /** + * The value indicating whether to suspend interchange on error. + */ + @JsonProperty(value = "suspendInterchangeOnError", required = true) + private boolean suspendInterchangeOnError; + + /** + * The value indicating whether to create empty xml tags for trailing + * separators. + */ + @JsonProperty(value = "createEmptyXmlTagsForTrailingSeparators", required = true) + private boolean createEmptyXmlTagsForTrailingSeparators; + + /** + * The value indicating whether to use dot as decimal separator. + */ + @JsonProperty(value = "useDotAsDecimalSeparator", required = true) + private boolean useDotAsDecimalSeparator; + + /** + * Get the value indicating whether to mask security information. + * + * @return the maskSecurityInfo value + */ + public boolean maskSecurityInfo() { + return this.maskSecurityInfo; + } + + /** + * Set the value indicating whether to mask security information. + * + * @param maskSecurityInfo the maskSecurityInfo value to set + * @return the EdifactProcessingSettings object itself. + */ + public EdifactProcessingSettings withMaskSecurityInfo(boolean maskSecurityInfo) { + this.maskSecurityInfo = maskSecurityInfo; + return this; + } + + /** + * Get the value indicating whether to preserve interchange. + * + * @return the preserveInterchange value + */ + public boolean preserveInterchange() { + return this.preserveInterchange; + } + + /** + * Set the value indicating whether to preserve interchange. + * + * @param preserveInterchange the preserveInterchange value to set + * @return the EdifactProcessingSettings object itself. + */ + public EdifactProcessingSettings withPreserveInterchange(boolean preserveInterchange) { + this.preserveInterchange = preserveInterchange; + return this; + } + + /** + * Get the value indicating whether to suspend interchange on error. + * + * @return the suspendInterchangeOnError value + */ + public boolean suspendInterchangeOnError() { + return this.suspendInterchangeOnError; + } + + /** + * Set the value indicating whether to suspend interchange on error. + * + * @param suspendInterchangeOnError the suspendInterchangeOnError value to set + * @return the EdifactProcessingSettings object itself. + */ + public EdifactProcessingSettings withSuspendInterchangeOnError(boolean suspendInterchangeOnError) { + this.suspendInterchangeOnError = suspendInterchangeOnError; + return this; + } + + /** + * Get the value indicating whether to create empty xml tags for trailing separators. + * + * @return the createEmptyXmlTagsForTrailingSeparators value + */ + public boolean createEmptyXmlTagsForTrailingSeparators() { + return this.createEmptyXmlTagsForTrailingSeparators; + } + + /** + * Set the value indicating whether to create empty xml tags for trailing separators. + * + * @param createEmptyXmlTagsForTrailingSeparators the createEmptyXmlTagsForTrailingSeparators value to set + * @return the EdifactProcessingSettings object itself. + */ + public EdifactProcessingSettings withCreateEmptyXmlTagsForTrailingSeparators(boolean createEmptyXmlTagsForTrailingSeparators) { + this.createEmptyXmlTagsForTrailingSeparators = createEmptyXmlTagsForTrailingSeparators; + return this; + } + + /** + * Get the value indicating whether to use dot as decimal separator. + * + * @return the useDotAsDecimalSeparator value + */ + public boolean useDotAsDecimalSeparator() { + return this.useDotAsDecimalSeparator; + } + + /** + * Set the value indicating whether to use dot as decimal separator. + * + * @param useDotAsDecimalSeparator the useDotAsDecimalSeparator value to set + * @return the EdifactProcessingSettings object itself. + */ + public EdifactProcessingSettings withUseDotAsDecimalSeparator(boolean useDotAsDecimalSeparator) { + this.useDotAsDecimalSeparator = useDotAsDecimalSeparator; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactProtocolSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactProtocolSettings.java new file mode 100644 index 000000000000..c223df6be685 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactProtocolSettings.java @@ -0,0 +1,304 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact agreement protocol settings. + */ +public class EdifactProtocolSettings { + /** + * The EDIFACT validation settings. + */ + @JsonProperty(value = "validationSettings", required = true) + private EdifactValidationSettings validationSettings; + + /** + * The EDIFACT framing settings. + */ + @JsonProperty(value = "framingSettings", required = true) + private EdifactFramingSettings framingSettings; + + /** + * The EDIFACT envelope settings. + */ + @JsonProperty(value = "envelopeSettings", required = true) + private EdifactEnvelopeSettings envelopeSettings; + + /** + * The EDIFACT acknowledgement settings. + */ + @JsonProperty(value = "acknowledgementSettings", required = true) + private EdifactAcknowledgementSettings acknowledgementSettings; + + /** + * The EDIFACT message filter. + */ + @JsonProperty(value = "messageFilter", required = true) + private EdifactMessageFilter messageFilter; + + /** + * The EDIFACT processing Settings. + */ + @JsonProperty(value = "processingSettings", required = true) + private EdifactProcessingSettings processingSettings; + + /** + * The EDIFACT envelope override settings. + */ + @JsonProperty(value = "envelopeOverrides") + private List envelopeOverrides; + + /** + * The EDIFACT message filter list. + */ + @JsonProperty(value = "messageFilterList") + private List messageFilterList; + + /** + * The EDIFACT schema references. + */ + @JsonProperty(value = "schemaReferences", required = true) + private List schemaReferences; + + /** + * The EDIFACT validation override settings. + */ + @JsonProperty(value = "validationOverrides") + private List validationOverrides; + + /** + * The EDIFACT delimiter override settings. + */ + @JsonProperty(value = "edifactDelimiterOverrides") + private List edifactDelimiterOverrides; + + /** + * Get the EDIFACT validation settings. + * + * @return the validationSettings value + */ + public EdifactValidationSettings validationSettings() { + return this.validationSettings; + } + + /** + * Set the EDIFACT validation settings. + * + * @param validationSettings the validationSettings value to set + * @return the EdifactProtocolSettings object itself. + */ + public EdifactProtocolSettings withValidationSettings(EdifactValidationSettings validationSettings) { + this.validationSettings = validationSettings; + return this; + } + + /** + * Get the EDIFACT framing settings. + * + * @return the framingSettings value + */ + public EdifactFramingSettings framingSettings() { + return this.framingSettings; + } + + /** + * Set the EDIFACT framing settings. + * + * @param framingSettings the framingSettings value to set + * @return the EdifactProtocolSettings object itself. + */ + public EdifactProtocolSettings withFramingSettings(EdifactFramingSettings framingSettings) { + this.framingSettings = framingSettings; + return this; + } + + /** + * Get the EDIFACT envelope settings. + * + * @return the envelopeSettings value + */ + public EdifactEnvelopeSettings envelopeSettings() { + return this.envelopeSettings; + } + + /** + * Set the EDIFACT envelope settings. + * + * @param envelopeSettings the envelopeSettings value to set + * @return the EdifactProtocolSettings object itself. + */ + public EdifactProtocolSettings withEnvelopeSettings(EdifactEnvelopeSettings envelopeSettings) { + this.envelopeSettings = envelopeSettings; + return this; + } + + /** + * Get the EDIFACT acknowledgement settings. + * + * @return the acknowledgementSettings value + */ + public EdifactAcknowledgementSettings acknowledgementSettings() { + return this.acknowledgementSettings; + } + + /** + * Set the EDIFACT acknowledgement settings. + * + * @param acknowledgementSettings the acknowledgementSettings value to set + * @return the EdifactProtocolSettings object itself. + */ + public EdifactProtocolSettings withAcknowledgementSettings(EdifactAcknowledgementSettings acknowledgementSettings) { + this.acknowledgementSettings = acknowledgementSettings; + return this; + } + + /** + * Get the EDIFACT message filter. + * + * @return the messageFilter value + */ + public EdifactMessageFilter messageFilter() { + return this.messageFilter; + } + + /** + * Set the EDIFACT message filter. + * + * @param messageFilter the messageFilter value to set + * @return the EdifactProtocolSettings object itself. + */ + public EdifactProtocolSettings withMessageFilter(EdifactMessageFilter messageFilter) { + this.messageFilter = messageFilter; + return this; + } + + /** + * Get the EDIFACT processing Settings. + * + * @return the processingSettings value + */ + public EdifactProcessingSettings processingSettings() { + return this.processingSettings; + } + + /** + * Set the EDIFACT processing Settings. + * + * @param processingSettings the processingSettings value to set + * @return the EdifactProtocolSettings object itself. + */ + public EdifactProtocolSettings withProcessingSettings(EdifactProcessingSettings processingSettings) { + this.processingSettings = processingSettings; + return this; + } + + /** + * Get the EDIFACT envelope override settings. + * + * @return the envelopeOverrides value + */ + public List envelopeOverrides() { + return this.envelopeOverrides; + } + + /** + * Set the EDIFACT envelope override settings. + * + * @param envelopeOverrides the envelopeOverrides value to set + * @return the EdifactProtocolSettings object itself. + */ + public EdifactProtocolSettings withEnvelopeOverrides(List envelopeOverrides) { + this.envelopeOverrides = envelopeOverrides; + return this; + } + + /** + * Get the EDIFACT message filter list. + * + * @return the messageFilterList value + */ + public List messageFilterList() { + return this.messageFilterList; + } + + /** + * Set the EDIFACT message filter list. + * + * @param messageFilterList the messageFilterList value to set + * @return the EdifactProtocolSettings object itself. + */ + public EdifactProtocolSettings withMessageFilterList(List messageFilterList) { + this.messageFilterList = messageFilterList; + return this; + } + + /** + * Get the EDIFACT schema references. + * + * @return the schemaReferences value + */ + public List schemaReferences() { + return this.schemaReferences; + } + + /** + * Set the EDIFACT schema references. + * + * @param schemaReferences the schemaReferences value to set + * @return the EdifactProtocolSettings object itself. + */ + public EdifactProtocolSettings withSchemaReferences(List schemaReferences) { + this.schemaReferences = schemaReferences; + return this; + } + + /** + * Get the EDIFACT validation override settings. + * + * @return the validationOverrides value + */ + public List validationOverrides() { + return this.validationOverrides; + } + + /** + * Set the EDIFACT validation override settings. + * + * @param validationOverrides the validationOverrides value to set + * @return the EdifactProtocolSettings object itself. + */ + public EdifactProtocolSettings withValidationOverrides(List validationOverrides) { + this.validationOverrides = validationOverrides; + return this; + } + + /** + * Get the EDIFACT delimiter override settings. + * + * @return the edifactDelimiterOverrides value + */ + public List edifactDelimiterOverrides() { + return this.edifactDelimiterOverrides; + } + + /** + * Set the EDIFACT delimiter override settings. + * + * @param edifactDelimiterOverrides the edifactDelimiterOverrides value to set + * @return the EdifactProtocolSettings object itself. + */ + public EdifactProtocolSettings withEdifactDelimiterOverrides(List edifactDelimiterOverrides) { + this.edifactDelimiterOverrides = edifactDelimiterOverrides; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactSchemaReference.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactSchemaReference.java new file mode 100644 index 000000000000..ae219fd4b63f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactSchemaReference.java @@ -0,0 +1,199 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact schema reference. + */ +public class EdifactSchemaReference { + /** + * The message id. + */ + @JsonProperty(value = "messageId", required = true) + private String messageId; + + /** + * The message version. + */ + @JsonProperty(value = "messageVersion", required = true) + private String messageVersion; + + /** + * The message release version. + */ + @JsonProperty(value = "messageRelease", required = true) + private String messageRelease; + + /** + * The sender application id. + */ + @JsonProperty(value = "senderApplicationId") + private String senderApplicationId; + + /** + * The sender application qualifier. + */ + @JsonProperty(value = "senderApplicationQualifier") + private String senderApplicationQualifier; + + /** + * The association assigned code. + */ + @JsonProperty(value = "associationAssignedCode") + private String associationAssignedCode; + + /** + * The schema name. + */ + @JsonProperty(value = "schemaName", required = true) + private String schemaName; + + /** + * Get the message id. + * + * @return the messageId value + */ + public String messageId() { + return this.messageId; + } + + /** + * Set the message id. + * + * @param messageId the messageId value to set + * @return the EdifactSchemaReference object itself. + */ + public EdifactSchemaReference withMessageId(String messageId) { + this.messageId = messageId; + return this; + } + + /** + * Get the message version. + * + * @return the messageVersion value + */ + public String messageVersion() { + return this.messageVersion; + } + + /** + * Set the message version. + * + * @param messageVersion the messageVersion value to set + * @return the EdifactSchemaReference object itself. + */ + public EdifactSchemaReference withMessageVersion(String messageVersion) { + this.messageVersion = messageVersion; + return this; + } + + /** + * Get the message release version. + * + * @return the messageRelease value + */ + public String messageRelease() { + return this.messageRelease; + } + + /** + * Set the message release version. + * + * @param messageRelease the messageRelease value to set + * @return the EdifactSchemaReference object itself. + */ + public EdifactSchemaReference withMessageRelease(String messageRelease) { + this.messageRelease = messageRelease; + return this; + } + + /** + * Get the sender application id. + * + * @return the senderApplicationId value + */ + public String senderApplicationId() { + return this.senderApplicationId; + } + + /** + * Set the sender application id. + * + * @param senderApplicationId the senderApplicationId value to set + * @return the EdifactSchemaReference object itself. + */ + public EdifactSchemaReference withSenderApplicationId(String senderApplicationId) { + this.senderApplicationId = senderApplicationId; + return this; + } + + /** + * Get the sender application qualifier. + * + * @return the senderApplicationQualifier value + */ + public String senderApplicationQualifier() { + return this.senderApplicationQualifier; + } + + /** + * Set the sender application qualifier. + * + * @param senderApplicationQualifier the senderApplicationQualifier value to set + * @return the EdifactSchemaReference object itself. + */ + public EdifactSchemaReference withSenderApplicationQualifier(String senderApplicationQualifier) { + this.senderApplicationQualifier = senderApplicationQualifier; + return this; + } + + /** + * Get the association assigned code. + * + * @return the associationAssignedCode value + */ + public String associationAssignedCode() { + return this.associationAssignedCode; + } + + /** + * Set the association assigned code. + * + * @param associationAssignedCode the associationAssignedCode value to set + * @return the EdifactSchemaReference object itself. + */ + public EdifactSchemaReference withAssociationAssignedCode(String associationAssignedCode) { + this.associationAssignedCode = associationAssignedCode; + return this; + } + + /** + * Get the schema name. + * + * @return the schemaName value + */ + public String schemaName() { + return this.schemaName; + } + + /** + * Set the schema name. + * + * @param schemaName the schemaName value to set + * @return the EdifactSchemaReference object itself. + */ + public EdifactSchemaReference withSchemaName(String schemaName) { + this.schemaName = schemaName; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactValidationOverride.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactValidationOverride.java new file mode 100644 index 000000000000..00591cc89912 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactValidationOverride.java @@ -0,0 +1,202 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact validation override settings. + */ +public class EdifactValidationOverride { + /** + * The message id on which the validation settings has to be applied. + */ + @JsonProperty(value = "messageId", required = true) + private String messageId; + + /** + * The value indicating whether to validate character Set. + */ + @JsonProperty(value = "enforceCharacterSet", required = true) + private boolean enforceCharacterSet; + + /** + * The value indicating whether to validate EDI types. + */ + @JsonProperty(value = "validateEDITypes", required = true) + private boolean validateEDITypes; + + /** + * The value indicating whether to validate XSD types. + */ + @JsonProperty(value = "validateXSDTypes", required = true) + private boolean validateXSDTypes; + + /** + * The value indicating whether to allow leading and trailing spaces and + * zeroes. + */ + @JsonProperty(value = "allowLeadingAndTrailingSpacesAndZeroes", required = true) + private boolean allowLeadingAndTrailingSpacesAndZeroes; + + /** + * The trailing separator policy. Possible values include: 'NotSpecified', + * 'NotAllowed', 'Optional', 'Mandatory'. + */ + @JsonProperty(value = "trailingSeparatorPolicy", required = true) + private TrailingSeparatorPolicy trailingSeparatorPolicy; + + /** + * The value indicating whether to trim leading and trailing spaces and + * zeroes. + */ + @JsonProperty(value = "trimLeadingAndTrailingSpacesAndZeroes", required = true) + private boolean trimLeadingAndTrailingSpacesAndZeroes; + + /** + * Get the message id on which the validation settings has to be applied. + * + * @return the messageId value + */ + public String messageId() { + return this.messageId; + } + + /** + * Set the message id on which the validation settings has to be applied. + * + * @param messageId the messageId value to set + * @return the EdifactValidationOverride object itself. + */ + public EdifactValidationOverride withMessageId(String messageId) { + this.messageId = messageId; + return this; + } + + /** + * Get the value indicating whether to validate character Set. + * + * @return the enforceCharacterSet value + */ + public boolean enforceCharacterSet() { + return this.enforceCharacterSet; + } + + /** + * Set the value indicating whether to validate character Set. + * + * @param enforceCharacterSet the enforceCharacterSet value to set + * @return the EdifactValidationOverride object itself. + */ + public EdifactValidationOverride withEnforceCharacterSet(boolean enforceCharacterSet) { + this.enforceCharacterSet = enforceCharacterSet; + return this; + } + + /** + * Get the value indicating whether to validate EDI types. + * + * @return the validateEDITypes value + */ + public boolean validateEDITypes() { + return this.validateEDITypes; + } + + /** + * Set the value indicating whether to validate EDI types. + * + * @param validateEDITypes the validateEDITypes value to set + * @return the EdifactValidationOverride object itself. + */ + public EdifactValidationOverride withValidateEDITypes(boolean validateEDITypes) { + this.validateEDITypes = validateEDITypes; + return this; + } + + /** + * Get the value indicating whether to validate XSD types. + * + * @return the validateXSDTypes value + */ + public boolean validateXSDTypes() { + return this.validateXSDTypes; + } + + /** + * Set the value indicating whether to validate XSD types. + * + * @param validateXSDTypes the validateXSDTypes value to set + * @return the EdifactValidationOverride object itself. + */ + public EdifactValidationOverride withValidateXSDTypes(boolean validateXSDTypes) { + this.validateXSDTypes = validateXSDTypes; + return this; + } + + /** + * Get the value indicating whether to allow leading and trailing spaces and zeroes. + * + * @return the allowLeadingAndTrailingSpacesAndZeroes value + */ + public boolean allowLeadingAndTrailingSpacesAndZeroes() { + return this.allowLeadingAndTrailingSpacesAndZeroes; + } + + /** + * Set the value indicating whether to allow leading and trailing spaces and zeroes. + * + * @param allowLeadingAndTrailingSpacesAndZeroes the allowLeadingAndTrailingSpacesAndZeroes value to set + * @return the EdifactValidationOverride object itself. + */ + public EdifactValidationOverride withAllowLeadingAndTrailingSpacesAndZeroes(boolean allowLeadingAndTrailingSpacesAndZeroes) { + this.allowLeadingAndTrailingSpacesAndZeroes = allowLeadingAndTrailingSpacesAndZeroes; + return this; + } + + /** + * Get the trailing separator policy. Possible values include: 'NotSpecified', 'NotAllowed', 'Optional', 'Mandatory'. + * + * @return the trailingSeparatorPolicy value + */ + public TrailingSeparatorPolicy trailingSeparatorPolicy() { + return this.trailingSeparatorPolicy; + } + + /** + * Set the trailing separator policy. Possible values include: 'NotSpecified', 'NotAllowed', 'Optional', 'Mandatory'. + * + * @param trailingSeparatorPolicy the trailingSeparatorPolicy value to set + * @return the EdifactValidationOverride object itself. + */ + public EdifactValidationOverride withTrailingSeparatorPolicy(TrailingSeparatorPolicy trailingSeparatorPolicy) { + this.trailingSeparatorPolicy = trailingSeparatorPolicy; + return this; + } + + /** + * Get the value indicating whether to trim leading and trailing spaces and zeroes. + * + * @return the trimLeadingAndTrailingSpacesAndZeroes value + */ + public boolean trimLeadingAndTrailingSpacesAndZeroes() { + return this.trimLeadingAndTrailingSpacesAndZeroes; + } + + /** + * Set the value indicating whether to trim leading and trailing spaces and zeroes. + * + * @param trimLeadingAndTrailingSpacesAndZeroes the trimLeadingAndTrailingSpacesAndZeroes value to set + * @return the EdifactValidationOverride object itself. + */ + public EdifactValidationOverride withTrimLeadingAndTrailingSpacesAndZeroes(boolean trimLeadingAndTrailingSpacesAndZeroes) { + this.trimLeadingAndTrailingSpacesAndZeroes = trimLeadingAndTrailingSpacesAndZeroes; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactValidationSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactValidationSettings.java new file mode 100644 index 000000000000..046b80472b5b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EdifactValidationSettings.java @@ -0,0 +1,283 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Edifact agreement validation settings. + */ +public class EdifactValidationSettings { + /** + * The value indicating whether to validate character set in the message. + */ + @JsonProperty(value = "validateCharacterSet", required = true) + private boolean validateCharacterSet; + + /** + * The value indicating whether to check for duplicate interchange control + * number. + */ + @JsonProperty(value = "checkDuplicateInterchangeControlNumber", required = true) + private boolean checkDuplicateInterchangeControlNumber; + + /** + * The validity period of interchange control number. + */ + @JsonProperty(value = "interchangeControlNumberValidityDays", required = true) + private int interchangeControlNumberValidityDays; + + /** + * The value indicating whether to check for duplicate group control + * number. + */ + @JsonProperty(value = "checkDuplicateGroupControlNumber", required = true) + private boolean checkDuplicateGroupControlNumber; + + /** + * The value indicating whether to check for duplicate transaction set + * control number. + */ + @JsonProperty(value = "checkDuplicateTransactionSetControlNumber", required = true) + private boolean checkDuplicateTransactionSetControlNumber; + + /** + * The value indicating whether to Whether to validate EDI types. + */ + @JsonProperty(value = "validateEDITypes", required = true) + private boolean validateEDITypes; + + /** + * The value indicating whether to Whether to validate XSD types. + */ + @JsonProperty(value = "validateXSDTypes", required = true) + private boolean validateXSDTypes; + + /** + * The value indicating whether to allow leading and trailing spaces and + * zeroes. + */ + @JsonProperty(value = "allowLeadingAndTrailingSpacesAndZeroes", required = true) + private boolean allowLeadingAndTrailingSpacesAndZeroes; + + /** + * The value indicating whether to trim leading and trailing spaces and + * zeroes. + */ + @JsonProperty(value = "trimLeadingAndTrailingSpacesAndZeroes", required = true) + private boolean trimLeadingAndTrailingSpacesAndZeroes; + + /** + * The trailing separator policy. Possible values include: 'NotSpecified', + * 'NotAllowed', 'Optional', 'Mandatory'. + */ + @JsonProperty(value = "trailingSeparatorPolicy", required = true) + private TrailingSeparatorPolicy trailingSeparatorPolicy; + + /** + * Get the value indicating whether to validate character set in the message. + * + * @return the validateCharacterSet value + */ + public boolean validateCharacterSet() { + return this.validateCharacterSet; + } + + /** + * Set the value indicating whether to validate character set in the message. + * + * @param validateCharacterSet the validateCharacterSet value to set + * @return the EdifactValidationSettings object itself. + */ + public EdifactValidationSettings withValidateCharacterSet(boolean validateCharacterSet) { + this.validateCharacterSet = validateCharacterSet; + return this; + } + + /** + * Get the value indicating whether to check for duplicate interchange control number. + * + * @return the checkDuplicateInterchangeControlNumber value + */ + public boolean checkDuplicateInterchangeControlNumber() { + return this.checkDuplicateInterchangeControlNumber; + } + + /** + * Set the value indicating whether to check for duplicate interchange control number. + * + * @param checkDuplicateInterchangeControlNumber the checkDuplicateInterchangeControlNumber value to set + * @return the EdifactValidationSettings object itself. + */ + public EdifactValidationSettings withCheckDuplicateInterchangeControlNumber(boolean checkDuplicateInterchangeControlNumber) { + this.checkDuplicateInterchangeControlNumber = checkDuplicateInterchangeControlNumber; + return this; + } + + /** + * Get the validity period of interchange control number. + * + * @return the interchangeControlNumberValidityDays value + */ + public int interchangeControlNumberValidityDays() { + return this.interchangeControlNumberValidityDays; + } + + /** + * Set the validity period of interchange control number. + * + * @param interchangeControlNumberValidityDays the interchangeControlNumberValidityDays value to set + * @return the EdifactValidationSettings object itself. + */ + public EdifactValidationSettings withInterchangeControlNumberValidityDays(int interchangeControlNumberValidityDays) { + this.interchangeControlNumberValidityDays = interchangeControlNumberValidityDays; + return this; + } + + /** + * Get the value indicating whether to check for duplicate group control number. + * + * @return the checkDuplicateGroupControlNumber value + */ + public boolean checkDuplicateGroupControlNumber() { + return this.checkDuplicateGroupControlNumber; + } + + /** + * Set the value indicating whether to check for duplicate group control number. + * + * @param checkDuplicateGroupControlNumber the checkDuplicateGroupControlNumber value to set + * @return the EdifactValidationSettings object itself. + */ + public EdifactValidationSettings withCheckDuplicateGroupControlNumber(boolean checkDuplicateGroupControlNumber) { + this.checkDuplicateGroupControlNumber = checkDuplicateGroupControlNumber; + return this; + } + + /** + * Get the value indicating whether to check for duplicate transaction set control number. + * + * @return the checkDuplicateTransactionSetControlNumber value + */ + public boolean checkDuplicateTransactionSetControlNumber() { + return this.checkDuplicateTransactionSetControlNumber; + } + + /** + * Set the value indicating whether to check for duplicate transaction set control number. + * + * @param checkDuplicateTransactionSetControlNumber the checkDuplicateTransactionSetControlNumber value to set + * @return the EdifactValidationSettings object itself. + */ + public EdifactValidationSettings withCheckDuplicateTransactionSetControlNumber(boolean checkDuplicateTransactionSetControlNumber) { + this.checkDuplicateTransactionSetControlNumber = checkDuplicateTransactionSetControlNumber; + return this; + } + + /** + * Get the value indicating whether to Whether to validate EDI types. + * + * @return the validateEDITypes value + */ + public boolean validateEDITypes() { + return this.validateEDITypes; + } + + /** + * Set the value indicating whether to Whether to validate EDI types. + * + * @param validateEDITypes the validateEDITypes value to set + * @return the EdifactValidationSettings object itself. + */ + public EdifactValidationSettings withValidateEDITypes(boolean validateEDITypes) { + this.validateEDITypes = validateEDITypes; + return this; + } + + /** + * Get the value indicating whether to Whether to validate XSD types. + * + * @return the validateXSDTypes value + */ + public boolean validateXSDTypes() { + return this.validateXSDTypes; + } + + /** + * Set the value indicating whether to Whether to validate XSD types. + * + * @param validateXSDTypes the validateXSDTypes value to set + * @return the EdifactValidationSettings object itself. + */ + public EdifactValidationSettings withValidateXSDTypes(boolean validateXSDTypes) { + this.validateXSDTypes = validateXSDTypes; + return this; + } + + /** + * Get the value indicating whether to allow leading and trailing spaces and zeroes. + * + * @return the allowLeadingAndTrailingSpacesAndZeroes value + */ + public boolean allowLeadingAndTrailingSpacesAndZeroes() { + return this.allowLeadingAndTrailingSpacesAndZeroes; + } + + /** + * Set the value indicating whether to allow leading and trailing spaces and zeroes. + * + * @param allowLeadingAndTrailingSpacesAndZeroes the allowLeadingAndTrailingSpacesAndZeroes value to set + * @return the EdifactValidationSettings object itself. + */ + public EdifactValidationSettings withAllowLeadingAndTrailingSpacesAndZeroes(boolean allowLeadingAndTrailingSpacesAndZeroes) { + this.allowLeadingAndTrailingSpacesAndZeroes = allowLeadingAndTrailingSpacesAndZeroes; + return this; + } + + /** + * Get the value indicating whether to trim leading and trailing spaces and zeroes. + * + * @return the trimLeadingAndTrailingSpacesAndZeroes value + */ + public boolean trimLeadingAndTrailingSpacesAndZeroes() { + return this.trimLeadingAndTrailingSpacesAndZeroes; + } + + /** + * Set the value indicating whether to trim leading and trailing spaces and zeroes. + * + * @param trimLeadingAndTrailingSpacesAndZeroes the trimLeadingAndTrailingSpacesAndZeroes value to set + * @return the EdifactValidationSettings object itself. + */ + public EdifactValidationSettings withTrimLeadingAndTrailingSpacesAndZeroes(boolean trimLeadingAndTrailingSpacesAndZeroes) { + this.trimLeadingAndTrailingSpacesAndZeroes = trimLeadingAndTrailingSpacesAndZeroes; + return this; + } + + /** + * Get the trailing separator policy. Possible values include: 'NotSpecified', 'NotAllowed', 'Optional', 'Mandatory'. + * + * @return the trailingSeparatorPolicy value + */ + public TrailingSeparatorPolicy trailingSeparatorPolicy() { + return this.trailingSeparatorPolicy; + } + + /** + * Set the trailing separator policy. Possible values include: 'NotSpecified', 'NotAllowed', 'Optional', 'Mandatory'. + * + * @param trailingSeparatorPolicy the trailingSeparatorPolicy value to set + * @return the EdifactValidationSettings object itself. + */ + public EdifactValidationSettings withTrailingSeparatorPolicy(TrailingSeparatorPolicy trailingSeparatorPolicy) { + this.trailingSeparatorPolicy = trailingSeparatorPolicy; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EncryptionAlgorithm.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EncryptionAlgorithm.java new file mode 100644 index 000000000000..e1e5470c3ef5 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EncryptionAlgorithm.java @@ -0,0 +1,56 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for EncryptionAlgorithm. + */ +public final class EncryptionAlgorithm extends ExpandableStringEnum { + /** Static value NotSpecified for EncryptionAlgorithm. */ + public static final EncryptionAlgorithm NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value None for EncryptionAlgorithm. */ + public static final EncryptionAlgorithm NONE = fromString("None"); + + /** Static value DES3 for EncryptionAlgorithm. */ + public static final EncryptionAlgorithm DES3 = fromString("DES3"); + + /** Static value RC2 for EncryptionAlgorithm. */ + public static final EncryptionAlgorithm RC2 = fromString("RC2"); + + /** Static value AES128 for EncryptionAlgorithm. */ + public static final EncryptionAlgorithm AES128 = fromString("AES128"); + + /** Static value AES192 for EncryptionAlgorithm. */ + public static final EncryptionAlgorithm AES192 = fromString("AES192"); + + /** Static value AES256 for EncryptionAlgorithm. */ + public static final EncryptionAlgorithm AES256 = fromString("AES256"); + + /** + * Creates or finds a EncryptionAlgorithm from its string representation. + * @param name a name to look for + * @return the corresponding EncryptionAlgorithm + */ + @JsonCreator + public static EncryptionAlgorithm fromString(String name) { + return fromString(name, EncryptionAlgorithm.class); + } + + /** + * @return known EncryptionAlgorithm values + */ + public static Collection values() { + return values(EncryptionAlgorithm.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorInfo.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorInfo.java new file mode 100644 index 000000000000..cf23be6b1d16 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorInfo.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The error info. + */ +public class ErrorInfo { + /** + * The error code. + */ + @JsonProperty(value = "code", required = true) + private String code; + + /** + * Get the error code. + * + * @return the code value + */ + public String code() { + return this.code; + } + + /** + * Set the error code. + * + * @param code the code value to set + * @return the ErrorInfo object itself. + */ + public ErrorInfo withCode(String code) { + this.code = code; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorProperties.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorProperties.java new file mode 100644 index 000000000000..c36e6ec3de7f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorProperties.java @@ -0,0 +1,70 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Error properties indicate why the Logic service was not able to process the + * incoming request. The reason is provided in the error message. + */ +public class ErrorProperties { + /** + * Error code. + */ + @JsonProperty(value = "code") + private String code; + + /** + * Error message indicating why the operation failed. + */ + @JsonProperty(value = "message") + private String message; + + /** + * Get error code. + * + * @return the code value + */ + public String code() { + return this.code; + } + + /** + * Set error code. + * + * @param code the code value to set + * @return the ErrorProperties object itself. + */ + public ErrorProperties withCode(String code) { + this.code = code; + return this; + } + + /** + * Get error message indicating why the operation failed. + * + * @return the message value + */ + public String message() { + return this.message; + } + + /** + * Set error message indicating why the operation failed. + * + * @param message the message value to set + * @return the ErrorProperties object itself. + */ + public ErrorProperties withMessage(String message) { + this.message = message; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorResponse.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorResponse.java new file mode 100644 index 000000000000..3f840f536f05 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorResponse.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Error response indicates Logic service is not able to process the incoming + * request. The error property contains the error details. + */ +public class ErrorResponse { + /** + * The error properties. + */ + @JsonProperty(value = "error") + private ErrorProperties error; + + /** + * Get the error properties. + * + * @return the error value + */ + public ErrorProperties error() { + return this.error; + } + + /** + * Set the error properties. + * + * @param error the error value to set + * @return the ErrorResponse object itself. + */ + public ErrorResponse withError(ErrorProperties error) { + this.error = error; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorResponseCode.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorResponseCode.java new file mode 100644 index 000000000000..21dcde2c27fa --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorResponseCode.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for ErrorResponseCode. + */ +public final class ErrorResponseCode extends ExpandableStringEnum { + /** Static value NotSpecified for ErrorResponseCode. */ + public static final ErrorResponseCode NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value IntegrationServiceEnvironmentNotFound for ErrorResponseCode. */ + public static final ErrorResponseCode INTEGRATION_SERVICE_ENVIRONMENT_NOT_FOUND = fromString("IntegrationServiceEnvironmentNotFound"); + + /** Static value InternalServerError for ErrorResponseCode. */ + public static final ErrorResponseCode INTERNAL_SERVER_ERROR = fromString("InternalServerError"); + + /** Static value InvalidOperationId for ErrorResponseCode. */ + public static final ErrorResponseCode INVALID_OPERATION_ID = fromString("InvalidOperationId"); + + /** + * Creates or finds a ErrorResponseCode from its string representation. + * @param name a name to look for + * @return the corresponding ErrorResponseCode + */ + @JsonCreator + public static ErrorResponseCode fromString(String name) { + return fromString(name, ErrorResponseCode.class); + } + + /** + * @return known ErrorResponseCode values + */ + public static Collection values() { + return values(ErrorResponseCode.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorResponseException.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorResponseException.java new file mode 100644 index 000000000000..5cbcac2afb64 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ErrorResponseException.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.rest.RestException; +import okhttp3.ResponseBody; +import retrofit2.Response; + +/** + * Exception thrown for an invalid response with ErrorResponse information. + */ +public class ErrorResponseException extends RestException { + /** + * Initializes a new instance of the ErrorResponseException class. + * + * @param message the exception message or the response content if a message is not available + * @param response the HTTP response + */ + public ErrorResponseException(final String message, final Response response) { + super(message, response); + } + + /** + * Initializes a new instance of the ErrorResponseException class. + * + * @param message the exception message or the response content if a message is not available + * @param response the HTTP response + * @param body the deserialized response body + */ + public ErrorResponseException(final String message, final Response response, final ErrorResponse body) { + super(message, response, body); + } + + @Override + public ErrorResponse body() { + return (ErrorResponse) super.body(); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EventLevel.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EventLevel.java new file mode 100644 index 000000000000..554669875810 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/EventLevel.java @@ -0,0 +1,65 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +/** + * Defines values for EventLevel. + */ +public enum EventLevel { + /** Enum value LogAlways. */ + LOG_ALWAYS("LogAlways"), + + /** Enum value Critical. */ + CRITICAL("Critical"), + + /** Enum value Error. */ + ERROR("Error"), + + /** Enum value Warning. */ + WARNING("Warning"), + + /** Enum value Informational. */ + INFORMATIONAL("Informational"), + + /** Enum value Verbose. */ + VERBOSE("Verbose"); + + /** The actual serialized value for a EventLevel instance. */ + private String value; + + EventLevel(String value) { + this.value = value; + } + + /** + * Parses a serialized value to a EventLevel instance. + * + * @param value the serialized value to parse. + * @return the parsed EventLevel object, or null if unable to parse. + */ + @JsonCreator + public static EventLevel fromString(String value) { + EventLevel[] items = EventLevel.values(); + for (EventLevel item : items) { + if (item.toString().equalsIgnoreCase(value)) { + return item; + } + } + return null; + } + + @JsonValue + @Override + public String toString() { + return this.value; + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Expression.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Expression.java new file mode 100644 index 000000000000..50471eec14e0 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Expression.java @@ -0,0 +1,122 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The expression. + */ +public class Expression { + /** + * The text. + */ + @JsonProperty(value = "text") + private String text; + + /** + * The value property. + */ + @JsonProperty(value = "value") + private Object value; + + /** + * The sub expressions. + */ + @JsonProperty(value = "subexpressions") + private List subexpressions; + + /** + * The error property. + */ + @JsonProperty(value = "error") + private AzureResourceErrorInfo error; + + /** + * Get the text. + * + * @return the text value + */ + public String text() { + return this.text; + } + + /** + * Set the text. + * + * @param text the text value to set + * @return the Expression object itself. + */ + public Expression withText(String text) { + this.text = text; + return this; + } + + /** + * Get the value value. + * + * @return the value value + */ + public Object value() { + return this.value; + } + + /** + * Set the value value. + * + * @param value the value value to set + * @return the Expression object itself. + */ + public Expression withValue(Object value) { + this.value = value; + return this; + } + + /** + * Get the sub expressions. + * + * @return the subexpressions value + */ + public List subexpressions() { + return this.subexpressions; + } + + /** + * Set the sub expressions. + * + * @param subexpressions the subexpressions value to set + * @return the Expression object itself. + */ + public Expression withSubexpressions(List subexpressions) { + this.subexpressions = subexpressions; + return this; + } + + /** + * Get the error value. + * + * @return the error value + */ + public AzureResourceErrorInfo error() { + return this.error; + } + + /** + * Set the error value. + * + * @param error the error value to set + * @return the Expression object itself. + */ + public Expression withError(AzureResourceErrorInfo error) { + this.error = error; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ExpressionRoot.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ExpressionRoot.java new file mode 100644 index 000000000000..78241e190f11 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ExpressionRoot.java @@ -0,0 +1,46 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.ExpressionRootInner; +import java.util.List; + +/** + * Type representing ExpressionRoot. + */ +public interface ExpressionRoot extends HasInner, HasManager { + /** + * @return the error value. + */ + AzureResourceErrorInfo error(); + + /** + * @return the path value. + */ + String path(); + + /** + * @return the subexpressions value. + */ + List subexpressions(); + + /** + * @return the text value. + */ + String text(); + + /** + * @return the value value. + */ + Object value(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ExtendedErrorInfo.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ExtendedErrorInfo.java new file mode 100644 index 000000000000..5ceb5fc0cc7b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ExtendedErrorInfo.java @@ -0,0 +1,124 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The extended error info. + */ +public class ExtendedErrorInfo { + /** + * The error code. Possible values include: 'NotSpecified', + * 'IntegrationServiceEnvironmentNotFound', 'InternalServerError', + * 'InvalidOperationId'. + */ + @JsonProperty(value = "code", required = true) + private ErrorResponseCode code; + + /** + * The error message. + */ + @JsonProperty(value = "message", required = true) + private String message; + + /** + * The error message details. + */ + @JsonProperty(value = "details") + private List details; + + /** + * The inner error. + */ + @JsonProperty(value = "innerError") + private Object innerError; + + /** + * Get the error code. Possible values include: 'NotSpecified', 'IntegrationServiceEnvironmentNotFound', 'InternalServerError', 'InvalidOperationId'. + * + * @return the code value + */ + public ErrorResponseCode code() { + return this.code; + } + + /** + * Set the error code. Possible values include: 'NotSpecified', 'IntegrationServiceEnvironmentNotFound', 'InternalServerError', 'InvalidOperationId'. + * + * @param code the code value to set + * @return the ExtendedErrorInfo object itself. + */ + public ExtendedErrorInfo withCode(ErrorResponseCode code) { + this.code = code; + return this; + } + + /** + * Get the error message. + * + * @return the message value + */ + public String message() { + return this.message; + } + + /** + * Set the error message. + * + * @param message the message value to set + * @return the ExtendedErrorInfo object itself. + */ + public ExtendedErrorInfo withMessage(String message) { + this.message = message; + return this; + } + + /** + * Get the error message details. + * + * @return the details value + */ + public List details() { + return this.details; + } + + /** + * Set the error message details. + * + * @param details the details value to set + * @return the ExtendedErrorInfo object itself. + */ + public ExtendedErrorInfo withDetails(List details) { + this.details = details; + return this; + } + + /** + * Get the inner error. + * + * @return the innerError value + */ + public Object innerError() { + return this.innerError; + } + + /** + * Set the inner error. + * + * @param innerError the innerError value to set + * @return the ExtendedErrorInfo object itself. + */ + public ExtendedErrorInfo withInnerError(Object innerError) { + this.innerError = innerError; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/FlowAccessControlConfiguration.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/FlowAccessControlConfiguration.java new file mode 100644 index 000000000000..2bd7f20b70bb --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/FlowAccessControlConfiguration.java @@ -0,0 +1,121 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The access control configuration. + */ +public class FlowAccessControlConfiguration { + /** + * The access control configuration for invoking workflow triggers. + */ + @JsonProperty(value = "triggers") + private FlowAccessControlConfigurationPolicy triggers; + + /** + * The access control configuration for accessing workflow run contents. + */ + @JsonProperty(value = "contents") + private FlowAccessControlConfigurationPolicy contents; + + /** + * The access control configuration for workflow actions. + */ + @JsonProperty(value = "actions") + private FlowAccessControlConfigurationPolicy actions; + + /** + * The access control configuration for workflow management. + */ + @JsonProperty(value = "workflowManagement") + private FlowAccessControlConfigurationPolicy workflowManagement; + + /** + * Get the access control configuration for invoking workflow triggers. + * + * @return the triggers value + */ + public FlowAccessControlConfigurationPolicy triggers() { + return this.triggers; + } + + /** + * Set the access control configuration for invoking workflow triggers. + * + * @param triggers the triggers value to set + * @return the FlowAccessControlConfiguration object itself. + */ + public FlowAccessControlConfiguration withTriggers(FlowAccessControlConfigurationPolicy triggers) { + this.triggers = triggers; + return this; + } + + /** + * Get the access control configuration for accessing workflow run contents. + * + * @return the contents value + */ + public FlowAccessControlConfigurationPolicy contents() { + return this.contents; + } + + /** + * Set the access control configuration for accessing workflow run contents. + * + * @param contents the contents value to set + * @return the FlowAccessControlConfiguration object itself. + */ + public FlowAccessControlConfiguration withContents(FlowAccessControlConfigurationPolicy contents) { + this.contents = contents; + return this; + } + + /** + * Get the access control configuration for workflow actions. + * + * @return the actions value + */ + public FlowAccessControlConfigurationPolicy actions() { + return this.actions; + } + + /** + * Set the access control configuration for workflow actions. + * + * @param actions the actions value to set + * @return the FlowAccessControlConfiguration object itself. + */ + public FlowAccessControlConfiguration withActions(FlowAccessControlConfigurationPolicy actions) { + this.actions = actions; + return this; + } + + /** + * Get the access control configuration for workflow management. + * + * @return the workflowManagement value + */ + public FlowAccessControlConfigurationPolicy workflowManagement() { + return this.workflowManagement; + } + + /** + * Set the access control configuration for workflow management. + * + * @param workflowManagement the workflowManagement value to set + * @return the FlowAccessControlConfiguration object itself. + */ + public FlowAccessControlConfiguration withWorkflowManagement(FlowAccessControlConfigurationPolicy workflowManagement) { + this.workflowManagement = workflowManagement; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/FlowAccessControlConfigurationPolicy.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/FlowAccessControlConfigurationPolicy.java new file mode 100644 index 000000000000..f9d53feb5332 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/FlowAccessControlConfigurationPolicy.java @@ -0,0 +1,70 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The access control configuration policy. + */ +public class FlowAccessControlConfigurationPolicy { + /** + * The allowed caller IP address ranges. + */ + @JsonProperty(value = "allowedCallerIpAddresses") + private List allowedCallerIpAddresses; + + /** + * The authentication policies for workflow. + */ + @JsonProperty(value = "openAuthenticationPolicies") + private OpenAuthenticationAccessPolicies openAuthenticationPolicies; + + /** + * Get the allowed caller IP address ranges. + * + * @return the allowedCallerIpAddresses value + */ + public List allowedCallerIpAddresses() { + return this.allowedCallerIpAddresses; + } + + /** + * Set the allowed caller IP address ranges. + * + * @param allowedCallerIpAddresses the allowedCallerIpAddresses value to set + * @return the FlowAccessControlConfigurationPolicy object itself. + */ + public FlowAccessControlConfigurationPolicy withAllowedCallerIpAddresses(List allowedCallerIpAddresses) { + this.allowedCallerIpAddresses = allowedCallerIpAddresses; + return this; + } + + /** + * Get the authentication policies for workflow. + * + * @return the openAuthenticationPolicies value + */ + public OpenAuthenticationAccessPolicies openAuthenticationPolicies() { + return this.openAuthenticationPolicies; + } + + /** + * Set the authentication policies for workflow. + * + * @param openAuthenticationPolicies the openAuthenticationPolicies value to set + * @return the FlowAccessControlConfigurationPolicy object itself. + */ + public FlowAccessControlConfigurationPolicy withOpenAuthenticationPolicies(OpenAuthenticationAccessPolicies openAuthenticationPolicies) { + this.openAuthenticationPolicies = openAuthenticationPolicies; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/FlowEndpoints.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/FlowEndpoints.java new file mode 100644 index 000000000000..216fefcd0dbb --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/FlowEndpoints.java @@ -0,0 +1,70 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The flow endpoints configuration. + */ +public class FlowEndpoints { + /** + * The outgoing ip address. + */ + @JsonProperty(value = "outgoingIpAddresses") + private List outgoingIpAddresses; + + /** + * The access endpoint ip address. + */ + @JsonProperty(value = "accessEndpointIpAddresses") + private List accessEndpointIpAddresses; + + /** + * Get the outgoing ip address. + * + * @return the outgoingIpAddresses value + */ + public List outgoingIpAddresses() { + return this.outgoingIpAddresses; + } + + /** + * Set the outgoing ip address. + * + * @param outgoingIpAddresses the outgoingIpAddresses value to set + * @return the FlowEndpoints object itself. + */ + public FlowEndpoints withOutgoingIpAddresses(List outgoingIpAddresses) { + this.outgoingIpAddresses = outgoingIpAddresses; + return this; + } + + /** + * Get the access endpoint ip address. + * + * @return the accessEndpointIpAddresses value + */ + public List accessEndpointIpAddresses() { + return this.accessEndpointIpAddresses; + } + + /** + * Set the access endpoint ip address. + * + * @param accessEndpointIpAddresses the accessEndpointIpAddresses value to set + * @return the FlowEndpoints object itself. + */ + public FlowEndpoints withAccessEndpointIpAddresses(List accessEndpointIpAddresses) { + this.accessEndpointIpAddresses = accessEndpointIpAddresses; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/FlowEndpointsConfiguration.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/FlowEndpointsConfiguration.java new file mode 100644 index 000000000000..013f1d3552cc --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/FlowEndpointsConfiguration.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The endpoints configuration. + */ +public class FlowEndpointsConfiguration { + /** + * The workflow endpoints. + */ + @JsonProperty(value = "workflow") + private FlowEndpoints workflow; + + /** + * The connector endpoints. + */ + @JsonProperty(value = "connector") + private FlowEndpoints connector; + + /** + * Get the workflow endpoints. + * + * @return the workflow value + */ + public FlowEndpoints workflow() { + return this.workflow; + } + + /** + * Set the workflow endpoints. + * + * @param workflow the workflow value to set + * @return the FlowEndpointsConfiguration object itself. + */ + public FlowEndpointsConfiguration withWorkflow(FlowEndpoints workflow) { + this.workflow = workflow; + return this; + } + + /** + * Get the connector endpoints. + * + * @return the connector value + */ + public FlowEndpoints connector() { + return this.connector; + } + + /** + * Set the connector endpoints. + * + * @param connector the connector value to set + * @return the FlowEndpointsConfiguration object itself. + */ + public FlowEndpointsConfiguration withConnector(FlowEndpoints connector) { + this.connector = connector; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/GenerateUpgradedDefinitionParameters.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/GenerateUpgradedDefinitionParameters.java new file mode 100644 index 000000000000..c1dac339f41e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/GenerateUpgradedDefinitionParameters.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The parameters to generate upgraded definition. + */ +public class GenerateUpgradedDefinitionParameters { + /** + * The target schema version. + */ + @JsonProperty(value = "targetSchemaVersion") + private String targetSchemaVersion; + + /** + * Get the target schema version. + * + * @return the targetSchemaVersion value + */ + public String targetSchemaVersion() { + return this.targetSchemaVersion; + } + + /** + * Set the target schema version. + * + * @param targetSchemaVersion the targetSchemaVersion value to set + * @return the GenerateUpgradedDefinitionParameters object itself. + */ + public GenerateUpgradedDefinitionParameters withTargetSchemaVersion(String targetSchemaVersion) { + this.targetSchemaVersion = targetSchemaVersion; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/GetCallbackUrlParameters.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/GetCallbackUrlParameters.java new file mode 100644 index 000000000000..623e7d1103e5 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/GetCallbackUrlParameters.java @@ -0,0 +1,71 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import org.joda.time.DateTime; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The callback url parameters. + */ +public class GetCallbackUrlParameters { + /** + * The expiry time. + */ + @JsonProperty(value = "notAfter") + private DateTime notAfter; + + /** + * The key type. Possible values include: 'NotSpecified', 'Primary', + * 'Secondary'. + */ + @JsonProperty(value = "keyType") + private KeyType keyType; + + /** + * Get the expiry time. + * + * @return the notAfter value + */ + public DateTime notAfter() { + return this.notAfter; + } + + /** + * Set the expiry time. + * + * @param notAfter the notAfter value to set + * @return the GetCallbackUrlParameters object itself. + */ + public GetCallbackUrlParameters withNotAfter(DateTime notAfter) { + this.notAfter = notAfter; + return this; + } + + /** + * Get the key type. Possible values include: 'NotSpecified', 'Primary', 'Secondary'. + * + * @return the keyType value + */ + public KeyType keyType() { + return this.keyType; + } + + /** + * Set the key type. Possible values include: 'NotSpecified', 'Primary', 'Secondary'. + * + * @param keyType the keyType value to set + * @return the GetCallbackUrlParameters object itself. + */ + public GetCallbackUrlParameters withKeyType(KeyType keyType) { + this.keyType = keyType; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/HashingAlgorithm.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/HashingAlgorithm.java new file mode 100644 index 000000000000..fadb114eaa1a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/HashingAlgorithm.java @@ -0,0 +1,56 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for HashingAlgorithm. + */ +public final class HashingAlgorithm extends ExpandableStringEnum { + /** Static value NotSpecified for HashingAlgorithm. */ + public static final HashingAlgorithm NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value None for HashingAlgorithm. */ + public static final HashingAlgorithm NONE = fromString("None"); + + /** Static value MD5 for HashingAlgorithm. */ + public static final HashingAlgorithm MD5 = fromString("MD5"); + + /** Static value SHA1 for HashingAlgorithm. */ + public static final HashingAlgorithm SHA1 = fromString("SHA1"); + + /** Static value SHA2256 for HashingAlgorithm. */ + public static final HashingAlgorithm SHA2256 = fromString("SHA2256"); + + /** Static value SHA2384 for HashingAlgorithm. */ + public static final HashingAlgorithm SHA2384 = fromString("SHA2384"); + + /** Static value SHA2512 for HashingAlgorithm. */ + public static final HashingAlgorithm SHA2512 = fromString("SHA2512"); + + /** + * Creates or finds a HashingAlgorithm from its string representation. + * @param name a name to look for + * @return the corresponding HashingAlgorithm + */ + @JsonCreator + public static HashingAlgorithm fromString(String name) { + return fromString(name, HashingAlgorithm.class); + } + + /** + * @return known HashingAlgorithm values + */ + public static Collection values() { + return values(HashingAlgorithm.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccount.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccount.java new file mode 100644 index 000000000000..ceb02e673f0c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccount.java @@ -0,0 +1,156 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.Resource; +import com.microsoft.azure.arm.resources.models.GroupableResourceCore; +import com.microsoft.azure.arm.resources.models.HasResourceGroup; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.model.Updatable; +import com.microsoft.azure.arm.model.Appliable; +import com.microsoft.azure.arm.model.Creatable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationServiceEnvironmentInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountInner; + +/** + * Type representing IntegrationAccount. + */ +public interface IntegrationAccount extends HasInner, Resource, GroupableResourceCore, HasResourceGroup, Refreshable, Updatable, HasManager { + /** + * @return the integrationServiceEnvironment value. + */ + IntegrationServiceEnvironment integrationServiceEnvironment(); + + /** + * @return the sku value. + */ + IntegrationAccountSku sku(); + + /** + * @return the state value. + */ + WorkflowState state(); + + /** + * The entirety of the IntegrationAccount definition. + */ + interface Definition extends DefinitionStages.Blank, DefinitionStages.WithGroup, DefinitionStages.WithCreate { + } + + /** + * Grouping of IntegrationAccount definition stages. + */ + interface DefinitionStages { + /** + * The first stage of a IntegrationAccount definition. + */ + interface Blank extends GroupableResourceCore.DefinitionWithRegion { + } + + /** + * The stage of the IntegrationAccount definition allowing to specify the resource group. + */ + interface WithGroup extends GroupableResourceCore.DefinitionStages.WithGroup { + } + + /** + * The stage of the integrationaccount definition allowing to specify IntegrationServiceEnvironment. + */ + interface WithIntegrationServiceEnvironment { + /** + * Specifies integrationServiceEnvironment. + * @param integrationServiceEnvironment The integration service environment + * @return the next definition stage + */ + WithCreate withIntegrationServiceEnvironment(IntegrationServiceEnvironmentInner integrationServiceEnvironment); + } + + /** + * The stage of the integrationaccount definition allowing to specify Sku. + */ + interface WithSku { + /** + * Specifies sku. + * @param sku The sku + * @return the next definition stage + */ + WithCreate withSku(IntegrationAccountSku sku); + } + + /** + * The stage of the integrationaccount definition allowing to specify State. + */ + interface WithState { + /** + * Specifies state. + * @param state The workflow state. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended' + * @return the next definition stage + */ + WithCreate withState(WorkflowState state); + } + + /** + * The stage of the definition which contains all the minimum required inputs for + * the resource to be created (via {@link WithCreate#create()}), but also allows + * for any other optional settings to be specified. + */ + interface WithCreate extends Creatable, Resource.DefinitionWithTags, DefinitionStages.WithIntegrationServiceEnvironment, DefinitionStages.WithSku, DefinitionStages.WithState { + } + } + /** + * The template for a IntegrationAccount update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable, Resource.UpdateWithTags, UpdateStages.WithIntegrationServiceEnvironment, UpdateStages.WithSku, UpdateStages.WithState { + } + + /** + * Grouping of IntegrationAccount update stages. + */ + interface UpdateStages { + /** + * The stage of the integrationaccount update allowing to specify IntegrationServiceEnvironment. + */ + interface WithIntegrationServiceEnvironment { + /** + * Specifies integrationServiceEnvironment. + * @param integrationServiceEnvironment The integration service environment + * @return the next update stage + */ + Update withIntegrationServiceEnvironment(IntegrationServiceEnvironmentInner integrationServiceEnvironment); + } + + /** + * The stage of the integrationaccount update allowing to specify Sku. + */ + interface WithSku { + /** + * Specifies sku. + * @param sku The sku + * @return the next update stage + */ + Update withSku(IntegrationAccountSku sku); + } + + /** + * The stage of the integrationaccount update allowing to specify State. + */ + interface WithState { + /** + * Specifies state. + * @param state The workflow state. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended' + * @return the next update stage + */ + Update withState(WorkflowState state); + } + + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountAgreement.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountAgreement.java new file mode 100644 index 000000000000..8aa2fb2256f4 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountAgreement.java @@ -0,0 +1,289 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountAgreementInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.model.Updatable; +import com.microsoft.azure.arm.model.Appliable; +import com.microsoft.azure.arm.model.Creatable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import java.util.Map; +import org.joda.time.DateTime; + +/** + * Type representing IntegrationAccountAgreement. + */ +public interface IntegrationAccountAgreement extends HasInner, Indexable, Refreshable, Updatable, HasManager { + /** + * @return the agreementType value. + */ + AgreementType agreementType(); + + /** + * @return the changedTime value. + */ + DateTime changedTime(); + + /** + * @return the content value. + */ + AgreementContent content(); + + /** + * @return the createdTime value. + */ + DateTime createdTime(); + + /** + * @return the guestIdentity value. + */ + BusinessIdentity guestIdentity(); + + /** + * @return the guestPartner value. + */ + String guestPartner(); + + /** + * @return the hostIdentity value. + */ + BusinessIdentity hostIdentity(); + + /** + * @return the hostPartner value. + */ + String hostPartner(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the metadata value. + */ + Object metadata(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the type value. + */ + String type(); + + /** + * The entirety of the IntegrationAccountAgreement definition. + */ + interface Definition extends DefinitionStages.Blank, DefinitionStages.WithIntegrationAccount, DefinitionStages.WithAgreementType, DefinitionStages.WithContent, DefinitionStages.WithGuestIdentity, DefinitionStages.WithGuestPartner, DefinitionStages.WithHostIdentity, DefinitionStages.WithHostPartner, DefinitionStages.WithCreate { + } + + /** + * Grouping of IntegrationAccountAgreement definition stages. + */ + interface DefinitionStages { + /** + * The first stage of a IntegrationAccountAgreement definition. + */ + interface Blank extends WithIntegrationAccount { + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify IntegrationAccount. + */ + interface WithIntegrationAccount { + /** + * Specifies resourceGroupName, integrationAccountName. + * @param resourceGroupName The resource group name + * @param integrationAccountName The integration account name + * @return the next definition stage + */ + WithAgreementType withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify AgreementType. + */ + interface WithAgreementType { + /** + * Specifies agreementType. + * @param agreementType The agreement type. Possible values include: 'NotSpecified', 'AS2', 'X12', 'Edifact' + * @return the next definition stage + */ + WithContent withAgreementType(AgreementType agreementType); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify Content. + */ + interface WithContent { + /** + * Specifies content. + * @param content The agreement content + * @return the next definition stage + */ + WithGuestIdentity withContent(AgreementContent content); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify GuestIdentity. + */ + interface WithGuestIdentity { + /** + * Specifies guestIdentity. + * @param guestIdentity The business identity of the guest partner + * @return the next definition stage + */ + WithGuestPartner withGuestIdentity(BusinessIdentity guestIdentity); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify GuestPartner. + */ + interface WithGuestPartner { + /** + * Specifies guestPartner. + * @param guestPartner The integration account partner that is set as guest partner for this agreement + * @return the next definition stage + */ + WithHostIdentity withGuestPartner(String guestPartner); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify HostIdentity. + */ + interface WithHostIdentity { + /** + * Specifies hostIdentity. + * @param hostIdentity The business identity of the host partner + * @return the next definition stage + */ + WithHostPartner withHostIdentity(BusinessIdentity hostIdentity); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify HostPartner. + */ + interface WithHostPartner { + /** + * Specifies hostPartner. + * @param hostPartner The integration account partner that is set as host partner for this agreement + * @return the next definition stage + */ + WithCreate withHostPartner(String hostPartner); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next definition stage + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + * @param metadata The metadata + * @return the next definition stage + */ + WithCreate withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next definition stage + */ + WithCreate withTags(Map tags); + } + + /** + * The stage of the definition which contains all the minimum required inputs for + * the resource to be created (via {@link WithCreate#create()}), but also allows + * for any other optional settings to be specified. + */ + interface WithCreate extends Creatable, DefinitionStages.WithLocation, DefinitionStages.WithMetadata, DefinitionStages.WithTags { + } + } + /** + * The template for a IntegrationAccountAgreement update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable, UpdateStages.WithLocation, UpdateStages.WithMetadata, UpdateStages.WithTags { + } + + /** + * Grouping of IntegrationAccountAgreement update stages. + */ + interface UpdateStages { + /** + * The stage of the integrationaccountagreement update allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next update stage + */ + Update withLocation(String location); + } + + /** + * The stage of the integrationaccountagreement update allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + * @param metadata The metadata + * @return the next update stage + */ + Update withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountagreement update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next update stage + */ + Update withTags(Map tags); + } + + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountAgreementFilter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountAgreementFilter.java new file mode 100644 index 000000000000..50392674f55e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountAgreementFilter.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration account agreement filter for odata query. + */ +public class IntegrationAccountAgreementFilter { + /** + * The agreement type of integration account agreement. Possible values + * include: 'NotSpecified', 'AS2', 'X12', 'Edifact'. + */ + @JsonProperty(value = "agreementType", required = true) + private AgreementType agreementType; + + /** + * Get the agreement type of integration account agreement. Possible values include: 'NotSpecified', 'AS2', 'X12', 'Edifact'. + * + * @return the agreementType value + */ + public AgreementType agreementType() { + return this.agreementType; + } + + /** + * Set the agreement type of integration account agreement. Possible values include: 'NotSpecified', 'AS2', 'X12', 'Edifact'. + * + * @param agreementType the agreementType value to set + * @return the IntegrationAccountAgreementFilter object itself. + */ + public IntegrationAccountAgreementFilter withAgreementType(AgreementType agreementType) { + this.agreementType = agreementType; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountAgreements.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountAgreements.java new file mode 100644 index 000000000000..49ab22c09d52 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountAgreements.java @@ -0,0 +1,65 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountAgreementsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationAccountAgreements. + */ +public interface IntegrationAccountAgreements extends SupportsCreating, HasInner { + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String agreementName, GetCallbackUrlParameters listContentCallbackUrl); + + /** + * Gets an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String integrationAccountName, String agreementName); + + /** + * Gets a list of integration account agreements. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroupName, final String integrationAccountName); + + /** + * Deletes an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable deleteAsync(String resourceGroupName, String integrationAccountName, String agreementName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountAssemblies.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountAssemblies.java new file mode 100644 index 000000000000..6e08fe84190e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountAssemblies.java @@ -0,0 +1,64 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountAssembliesInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationAccountAssemblies. + */ +public interface IntegrationAccountAssemblies extends SupportsCreating, HasInner { + /** + * Get the content callback url for an integration account assembly. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName); + + /** + * Get an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName); + + /** + * List the assemblies for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(String resourceGroupName, String integrationAccountName); + + /** + * Delete an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable deleteAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountBatchConfigurations.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountBatchConfigurations.java new file mode 100644 index 000000000000..a2c8ce757530 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountBatchConfigurations.java @@ -0,0 +1,53 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountBatchConfigurationsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationAccountBatchConfigurations. + */ +public interface IntegrationAccountBatchConfigurations extends SupportsCreating, HasInner { + /** + * Get a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String integrationAccountName, String batchConfigurationName); + + /** + * List the batch configurations for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(String resourceGroupName, String integrationAccountName); + + /** + * Delete a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable deleteAsync(String resourceGroupName, String integrationAccountName, String batchConfigurationName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountCertificate.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountCertificate.java new file mode 100644 index 000000000000..cd0a1b0e288c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountCertificate.java @@ -0,0 +1,245 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountCertificateInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.model.Updatable; +import com.microsoft.azure.arm.model.Appliable; +import com.microsoft.azure.arm.model.Creatable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import java.util.Map; +import org.joda.time.DateTime; + +/** + * Type representing IntegrationAccountCertificate. + */ +public interface IntegrationAccountCertificate extends HasInner, Indexable, Refreshable, Updatable, HasManager { + /** + * @return the changedTime value. + */ + DateTime changedTime(); + + /** + * @return the createdTime value. + */ + DateTime createdTime(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the key value. + */ + KeyVaultKeyReference keyVal(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the metadata value. + */ + Object metadata(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the publicCertificate value. + */ + String publicCertificate(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the type value. + */ + String type(); + + /** + * The entirety of the IntegrationAccountCertificate definition. + */ + interface Definition extends DefinitionStages.Blank, DefinitionStages.WithIntegrationAccount, DefinitionStages.WithCreate { + } + + /** + * Grouping of IntegrationAccountCertificate definition stages. + */ + interface DefinitionStages { + /** + * The first stage of a IntegrationAccountCertificate definition. + */ + interface Blank extends WithIntegrationAccount { + } + + /** + * The stage of the integrationaccountcertificate definition allowing to specify IntegrationAccount. + */ + interface WithIntegrationAccount { + /** + * Specifies resourceGroupName, integrationAccountName. + * @param resourceGroupName The resource group name + * @param integrationAccountName The integration account name + * @return the next definition stage + */ + WithCreate withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the integrationaccountcertificate definition allowing to specify Key. + */ + interface WithKey { + /** + * Specifies key. + * @param key The key details in the key vault + * @return the next definition stage + */ + WithCreate withKey(KeyVaultKeyReference key); + } + + /** + * The stage of the integrationaccountcertificate definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next definition stage + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the integrationaccountcertificate definition allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + * @param metadata The metadata + * @return the next definition stage + */ + WithCreate withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountcertificate definition allowing to specify PublicCertificate. + */ + interface WithPublicCertificate { + /** + * Specifies publicCertificate. + * @param publicCertificate The public certificate + * @return the next definition stage + */ + WithCreate withPublicCertificate(String publicCertificate); + } + + /** + * The stage of the integrationaccountcertificate definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next definition stage + */ + WithCreate withTags(Map tags); + } + + /** + * The stage of the definition which contains all the minimum required inputs for + * the resource to be created (via {@link WithCreate#create()}), but also allows + * for any other optional settings to be specified. + */ + interface WithCreate extends Creatable, DefinitionStages.WithKey, DefinitionStages.WithLocation, DefinitionStages.WithMetadata, DefinitionStages.WithPublicCertificate, DefinitionStages.WithTags { + } + } + /** + * The template for a IntegrationAccountCertificate update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable, UpdateStages.WithKey, UpdateStages.WithLocation, UpdateStages.WithMetadata, UpdateStages.WithPublicCertificate, UpdateStages.WithTags { + } + + /** + * Grouping of IntegrationAccountCertificate update stages. + */ + interface UpdateStages { + /** + * The stage of the integrationaccountcertificate update allowing to specify Key. + */ + interface WithKey { + /** + * Specifies key. + * @param key The key details in the key vault + * @return the next update stage + */ + Update withKey(KeyVaultKeyReference key); + } + + /** + * The stage of the integrationaccountcertificate update allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next update stage + */ + Update withLocation(String location); + } + + /** + * The stage of the integrationaccountcertificate update allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + * @param metadata The metadata + * @return the next update stage + */ + Update withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountcertificate update allowing to specify PublicCertificate. + */ + interface WithPublicCertificate { + /** + * Specifies publicCertificate. + * @param publicCertificate The public certificate + * @return the next update stage + */ + Update withPublicCertificate(String publicCertificate); + } + + /** + * The stage of the integrationaccountcertificate update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next update stage + */ + Update withTags(Map tags); + } + + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountCertificates.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountCertificates.java new file mode 100644 index 000000000000..c4378b989d5b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountCertificates.java @@ -0,0 +1,53 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountCertificatesInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationAccountCertificates. + */ +public interface IntegrationAccountCertificates extends SupportsCreating, HasInner { + /** + * Gets an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String integrationAccountName, String certificateName); + + /** + * Gets a list of integration account certificates. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroupName, final String integrationAccountName); + + /** + * Deletes an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable deleteAsync(String resourceGroupName, String integrationAccountName, String certificateName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountMap.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountMap.java new file mode 100644 index 000000000000..febbbc3f9f07 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountMap.java @@ -0,0 +1,296 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountMapInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.model.Updatable; +import com.microsoft.azure.arm.model.Appliable; +import com.microsoft.azure.arm.model.Creatable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import java.util.Map; +import org.joda.time.DateTime; + +/** + * Type representing IntegrationAccountMap. + */ +public interface IntegrationAccountMap extends HasInner, Indexable, Refreshable, Updatable, HasManager { + /** + * @return the changedTime value. + */ + DateTime changedTime(); + + /** + * @return the content value. + */ + String content(); + + /** + * @return the contentLink value. + */ + ContentLink contentLink(); + + /** + * @return the contentType value. + */ + String contentType(); + + /** + * @return the createdTime value. + */ + DateTime createdTime(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the mapType value. + */ + MapType mapType(); + + /** + * @return the metadata value. + */ + Object metadata(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the parametersSchema value. + */ + IntegrationAccountMapPropertiesParametersSchema parametersSchema(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the type value. + */ + String type(); + + /** + * The entirety of the IntegrationAccountMap definition. + */ + interface Definition extends DefinitionStages.Blank, DefinitionStages.WithIntegrationAccount, DefinitionStages.WithMapType, DefinitionStages.WithCreate { + } + + /** + * Grouping of IntegrationAccountMap definition stages. + */ + interface DefinitionStages { + /** + * The first stage of a IntegrationAccountMap definition. + */ + interface Blank extends WithIntegrationAccount { + } + + /** + * The stage of the integrationaccountmap definition allowing to specify IntegrationAccount. + */ + interface WithIntegrationAccount { + /** + * Specifies resourceGroupName, integrationAccountName. + * @param resourceGroupName The resource group name + * @param integrationAccountName The integration account name + * @return the next definition stage + */ + WithMapType withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify MapType. + */ + interface WithMapType { + /** + * Specifies mapType. + * @param mapType The map type. Possible values include: 'NotSpecified', 'Xslt', 'Xslt20', 'Xslt30', 'Liquid' + * @return the next definition stage + */ + WithCreate withMapType(MapType mapType); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify Content. + */ + interface WithContent { + /** + * Specifies content. + * @param content The content + * @return the next definition stage + */ + WithCreate withContent(String content); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify ContentType. + */ + interface WithContentType { + /** + * Specifies contentType. + * @param contentType The content type + * @return the next definition stage + */ + WithCreate withContentType(String contentType); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next definition stage + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + * @param metadata The metadata + * @return the next definition stage + */ + WithCreate withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify ParametersSchema. + */ + interface WithParametersSchema { + /** + * Specifies parametersSchema. + * @param parametersSchema The parameters schema of integration account map + * @return the next definition stage + */ + WithCreate withParametersSchema(IntegrationAccountMapPropertiesParametersSchema parametersSchema); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next definition stage + */ + WithCreate withTags(Map tags); + } + + /** + * The stage of the definition which contains all the minimum required inputs for + * the resource to be created (via {@link WithCreate#create()}), but also allows + * for any other optional settings to be specified. + */ + interface WithCreate extends Creatable, DefinitionStages.WithContent, DefinitionStages.WithContentType, DefinitionStages.WithLocation, DefinitionStages.WithMetadata, DefinitionStages.WithParametersSchema, DefinitionStages.WithTags { + } + } + /** + * The template for a IntegrationAccountMap update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable, UpdateStages.WithContent, UpdateStages.WithContentType, UpdateStages.WithLocation, UpdateStages.WithMetadata, UpdateStages.WithParametersSchema, UpdateStages.WithTags { + } + + /** + * Grouping of IntegrationAccountMap update stages. + */ + interface UpdateStages { + /** + * The stage of the integrationaccountmap update allowing to specify Content. + */ + interface WithContent { + /** + * Specifies content. + * @param content The content + * @return the next update stage + */ + Update withContent(String content); + } + + /** + * The stage of the integrationaccountmap update allowing to specify ContentType. + */ + interface WithContentType { + /** + * Specifies contentType. + * @param contentType The content type + * @return the next update stage + */ + Update withContentType(String contentType); + } + + /** + * The stage of the integrationaccountmap update allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next update stage + */ + Update withLocation(String location); + } + + /** + * The stage of the integrationaccountmap update allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + * @param metadata The metadata + * @return the next update stage + */ + Update withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountmap update allowing to specify ParametersSchema. + */ + interface WithParametersSchema { + /** + * Specifies parametersSchema. + * @param parametersSchema The parameters schema of integration account map + * @return the next update stage + */ + Update withParametersSchema(IntegrationAccountMapPropertiesParametersSchema parametersSchema); + } + + /** + * The stage of the integrationaccountmap update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next update stage + */ + Update withTags(Map tags); + } + + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountMapFilter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountMapFilter.java new file mode 100644 index 000000000000..001686b7e960 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountMapFilter.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration account map filter for odata query. + */ +public class IntegrationAccountMapFilter { + /** + * The map type of integration account map. Possible values include: + * 'NotSpecified', 'Xslt', 'Xslt20', 'Xslt30', 'Liquid'. + */ + @JsonProperty(value = "mapType", required = true) + private MapType mapType; + + /** + * Get the map type of integration account map. Possible values include: 'NotSpecified', 'Xslt', 'Xslt20', 'Xslt30', 'Liquid'. + * + * @return the mapType value + */ + public MapType mapType() { + return this.mapType; + } + + /** + * Set the map type of integration account map. Possible values include: 'NotSpecified', 'Xslt', 'Xslt20', 'Xslt30', 'Liquid'. + * + * @param mapType the mapType value to set + * @return the IntegrationAccountMapFilter object itself. + */ + public IntegrationAccountMapFilter withMapType(MapType mapType) { + this.mapType = mapType; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountMapPropertiesParametersSchema.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountMapPropertiesParametersSchema.java new file mode 100644 index 000000000000..fd81f7c0175a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountMapPropertiesParametersSchema.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The parameters schema of integration account map. + */ +public class IntegrationAccountMapPropertiesParametersSchema { + /** + * The reference name. + */ + @JsonProperty(value = "ref") + private String ref; + + /** + * Get the reference name. + * + * @return the ref value + */ + public String ref() { + return this.ref; + } + + /** + * Set the reference name. + * + * @param ref the ref value to set + * @return the IntegrationAccountMapPropertiesParametersSchema object itself. + */ + public IntegrationAccountMapPropertiesParametersSchema withRef(String ref) { + this.ref = ref; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountMaps.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountMaps.java new file mode 100644 index 000000000000..c7b7fd826574 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountMaps.java @@ -0,0 +1,65 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountMapsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationAccountMaps. + */ +public interface IntegrationAccountMaps extends SupportsCreating, HasInner { + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String mapName, GetCallbackUrlParameters listContentCallbackUrl); + + /** + * Gets an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String integrationAccountName, String mapName); + + /** + * Gets a list of integration account maps. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroupName, final String integrationAccountName); + + /** + * Deletes an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable deleteAsync(String resourceGroupName, String integrationAccountName, String mapName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountPartner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountPartner.java new file mode 100644 index 000000000000..8f82b3ae1e92 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountPartner.java @@ -0,0 +1,221 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountPartnerInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.model.Updatable; +import com.microsoft.azure.arm.model.Appliable; +import com.microsoft.azure.arm.model.Creatable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import java.util.Map; +import org.joda.time.DateTime; + +/** + * Type representing IntegrationAccountPartner. + */ +public interface IntegrationAccountPartner extends HasInner, Indexable, Refreshable, Updatable, HasManager { + /** + * @return the changedTime value. + */ + DateTime changedTime(); + + /** + * @return the content value. + */ + PartnerContent content(); + + /** + * @return the createdTime value. + */ + DateTime createdTime(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the metadata value. + */ + Object metadata(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the partnerType value. + */ + PartnerType partnerType(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the type value. + */ + String type(); + + /** + * The entirety of the IntegrationAccountPartner definition. + */ + interface Definition extends DefinitionStages.Blank, DefinitionStages.WithIntegrationAccount, DefinitionStages.WithContent, DefinitionStages.WithPartnerType, DefinitionStages.WithCreate { + } + + /** + * Grouping of IntegrationAccountPartner definition stages. + */ + interface DefinitionStages { + /** + * The first stage of a IntegrationAccountPartner definition. + */ + interface Blank extends WithIntegrationAccount { + } + + /** + * The stage of the integrationaccountpartner definition allowing to specify IntegrationAccount. + */ + interface WithIntegrationAccount { + /** + * Specifies resourceGroupName, integrationAccountName. + * @param resourceGroupName The resource group name + * @param integrationAccountName The integration account name + * @return the next definition stage + */ + WithContent withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the integrationaccountpartner definition allowing to specify Content. + */ + interface WithContent { + /** + * Specifies content. + * @param content The partner content + * @return the next definition stage + */ + WithPartnerType withContent(PartnerContent content); + } + + /** + * The stage of the integrationaccountpartner definition allowing to specify PartnerType. + */ + interface WithPartnerType { + /** + * Specifies partnerType. + * @param partnerType The partner type. Possible values include: 'NotSpecified', 'B2B' + * @return the next definition stage + */ + WithCreate withPartnerType(PartnerType partnerType); + } + + /** + * The stage of the integrationaccountpartner definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next definition stage + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the integrationaccountpartner definition allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + * @param metadata The metadata + * @return the next definition stage + */ + WithCreate withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountpartner definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next definition stage + */ + WithCreate withTags(Map tags); + } + + /** + * The stage of the definition which contains all the minimum required inputs for + * the resource to be created (via {@link WithCreate#create()}), but also allows + * for any other optional settings to be specified. + */ + interface WithCreate extends Creatable, DefinitionStages.WithLocation, DefinitionStages.WithMetadata, DefinitionStages.WithTags { + } + } + /** + * The template for a IntegrationAccountPartner update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable, UpdateStages.WithLocation, UpdateStages.WithMetadata, UpdateStages.WithTags { + } + + /** + * Grouping of IntegrationAccountPartner update stages. + */ + interface UpdateStages { + /** + * The stage of the integrationaccountpartner update allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next update stage + */ + Update withLocation(String location); + } + + /** + * The stage of the integrationaccountpartner update allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + * @param metadata The metadata + * @return the next update stage + */ + Update withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountpartner update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next update stage + */ + Update withTags(Map tags); + } + + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountPartnerFilter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountPartnerFilter.java new file mode 100644 index 000000000000..a2699b5d43bd --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountPartnerFilter.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration account partner filter for odata query. + */ +public class IntegrationAccountPartnerFilter { + /** + * The partner type of integration account partner. Possible values + * include: 'NotSpecified', 'B2B'. + */ + @JsonProperty(value = "partnerType", required = true) + private PartnerType partnerType; + + /** + * Get the partner type of integration account partner. Possible values include: 'NotSpecified', 'B2B'. + * + * @return the partnerType value + */ + public PartnerType partnerType() { + return this.partnerType; + } + + /** + * Set the partner type of integration account partner. Possible values include: 'NotSpecified', 'B2B'. + * + * @param partnerType the partnerType value to set + * @return the IntegrationAccountPartnerFilter object itself. + */ + public IntegrationAccountPartnerFilter withPartnerType(PartnerType partnerType) { + this.partnerType = partnerType; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountPartners.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountPartners.java new file mode 100644 index 000000000000..5a2f000f6d25 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountPartners.java @@ -0,0 +1,65 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountPartnersInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationAccountPartners. + */ +public interface IntegrationAccountPartners extends SupportsCreating, HasInner { + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String partnerName, GetCallbackUrlParameters listContentCallbackUrl); + + /** + * Gets an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String integrationAccountName, String partnerName); + + /** + * Gets a list of integration account partners. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroupName, final String integrationAccountName); + + /** + * Deletes an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable deleteAsync(String resourceGroupName, String integrationAccountName, String partnerName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSchema.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSchema.java new file mode 100644 index 000000000000..c848f75e1dc7 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSchema.java @@ -0,0 +1,354 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountSchemaInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.model.Updatable; +import com.microsoft.azure.arm.model.Appliable; +import com.microsoft.azure.arm.model.Creatable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import java.util.Map; +import org.joda.time.DateTime; + +/** + * Type representing IntegrationAccountSchema. + */ +public interface IntegrationAccountSchema extends HasInner, Indexable, Refreshable, Updatable, HasManager { + /** + * @return the changedTime value. + */ + DateTime changedTime(); + + /** + * @return the content value. + */ + String content(); + + /** + * @return the contentLink value. + */ + ContentLink contentLink(); + + /** + * @return the contentType value. + */ + String contentType(); + + /** + * @return the createdTime value. + */ + DateTime createdTime(); + + /** + * @return the documentName value. + */ + String documentName(); + + /** + * @return the fileName value. + */ + String fileName(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the metadata value. + */ + Object metadata(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the schemaType value. + */ + SchemaType schemaType(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the targetNamespace value. + */ + String targetNamespace(); + + /** + * @return the type value. + */ + String type(); + + /** + * The entirety of the IntegrationAccountSchema definition. + */ + interface Definition extends DefinitionStages.Blank, DefinitionStages.WithIntegrationAccount, DefinitionStages.WithSchemaType, DefinitionStages.WithCreate { + } + + /** + * Grouping of IntegrationAccountSchema definition stages. + */ + interface DefinitionStages { + /** + * The first stage of a IntegrationAccountSchema definition. + */ + interface Blank extends WithIntegrationAccount { + } + + /** + * The stage of the integrationaccountschema definition allowing to specify IntegrationAccount. + */ + interface WithIntegrationAccount { + /** + * Specifies resourceGroupName, integrationAccountName. + * @param resourceGroupName The resource group name + * @param integrationAccountName The integration account name + * @return the next definition stage + */ + WithSchemaType withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify SchemaType. + */ + interface WithSchemaType { + /** + * Specifies schemaType. + * @param schemaType The schema type. Possible values include: 'NotSpecified', 'Xml' + * @return the next definition stage + */ + WithCreate withSchemaType(SchemaType schemaType); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify Content. + */ + interface WithContent { + /** + * Specifies content. + * @param content The content + * @return the next definition stage + */ + WithCreate withContent(String content); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify ContentType. + */ + interface WithContentType { + /** + * Specifies contentType. + * @param contentType The content type + * @return the next definition stage + */ + WithCreate withContentType(String contentType); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify DocumentName. + */ + interface WithDocumentName { + /** + * Specifies documentName. + * @param documentName The document name + * @return the next definition stage + */ + WithCreate withDocumentName(String documentName); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify FileName. + */ + interface WithFileName { + /** + * Specifies fileName. + * @param fileName The file name + * @return the next definition stage + */ + WithCreate withFileName(String fileName); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next definition stage + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + * @param metadata The metadata + * @return the next definition stage + */ + WithCreate withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next definition stage + */ + WithCreate withTags(Map tags); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify TargetNamespace. + */ + interface WithTargetNamespace { + /** + * Specifies targetNamespace. + * @param targetNamespace The target namespace of the schema + * @return the next definition stage + */ + WithCreate withTargetNamespace(String targetNamespace); + } + + /** + * The stage of the definition which contains all the minimum required inputs for + * the resource to be created (via {@link WithCreate#create()}), but also allows + * for any other optional settings to be specified. + */ + interface WithCreate extends Creatable, DefinitionStages.WithContent, DefinitionStages.WithContentType, DefinitionStages.WithDocumentName, DefinitionStages.WithFileName, DefinitionStages.WithLocation, DefinitionStages.WithMetadata, DefinitionStages.WithTags, DefinitionStages.WithTargetNamespace { + } + } + /** + * The template for a IntegrationAccountSchema update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable, UpdateStages.WithContent, UpdateStages.WithContentType, UpdateStages.WithDocumentName, UpdateStages.WithFileName, UpdateStages.WithLocation, UpdateStages.WithMetadata, UpdateStages.WithTags, UpdateStages.WithTargetNamespace { + } + + /** + * Grouping of IntegrationAccountSchema update stages. + */ + interface UpdateStages { + /** + * The stage of the integrationaccountschema update allowing to specify Content. + */ + interface WithContent { + /** + * Specifies content. + * @param content The content + * @return the next update stage + */ + Update withContent(String content); + } + + /** + * The stage of the integrationaccountschema update allowing to specify ContentType. + */ + interface WithContentType { + /** + * Specifies contentType. + * @param contentType The content type + * @return the next update stage + */ + Update withContentType(String contentType); + } + + /** + * The stage of the integrationaccountschema update allowing to specify DocumentName. + */ + interface WithDocumentName { + /** + * Specifies documentName. + * @param documentName The document name + * @return the next update stage + */ + Update withDocumentName(String documentName); + } + + /** + * The stage of the integrationaccountschema update allowing to specify FileName. + */ + interface WithFileName { + /** + * Specifies fileName. + * @param fileName The file name + * @return the next update stage + */ + Update withFileName(String fileName); + } + + /** + * The stage of the integrationaccountschema update allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next update stage + */ + Update withLocation(String location); + } + + /** + * The stage of the integrationaccountschema update allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + * @param metadata The metadata + * @return the next update stage + */ + Update withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountschema update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next update stage + */ + Update withTags(Map tags); + } + + /** + * The stage of the integrationaccountschema update allowing to specify TargetNamespace. + */ + interface WithTargetNamespace { + /** + * Specifies targetNamespace. + * @param targetNamespace The target namespace of the schema + * @return the next update stage + */ + Update withTargetNamespace(String targetNamespace); + } + + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSchemaFilter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSchemaFilter.java new file mode 100644 index 000000000000..423a6c46045c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSchemaFilter.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration account schema filter for odata query. + */ +public class IntegrationAccountSchemaFilter { + /** + * The schema type of integration account schema. Possible values include: + * 'NotSpecified', 'Xml'. + */ + @JsonProperty(value = "schemaType", required = true) + private SchemaType schemaType; + + /** + * Get the schema type of integration account schema. Possible values include: 'NotSpecified', 'Xml'. + * + * @return the schemaType value + */ + public SchemaType schemaType() { + return this.schemaType; + } + + /** + * Set the schema type of integration account schema. Possible values include: 'NotSpecified', 'Xml'. + * + * @param schemaType the schemaType value to set + * @return the IntegrationAccountSchemaFilter object itself. + */ + public IntegrationAccountSchemaFilter withSchemaType(SchemaType schemaType) { + this.schemaType = schemaType; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSchemas.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSchemas.java new file mode 100644 index 000000000000..9026dcf5adcc --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSchemas.java @@ -0,0 +1,65 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountSchemasInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationAccountSchemas. + */ +public interface IntegrationAccountSchemas extends SupportsCreating, HasInner { + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String schemaName, GetCallbackUrlParameters listContentCallbackUrl); + + /** + * Gets an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String integrationAccountName, String schemaName); + + /** + * Gets a list of integration account schemas. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroupName, final String integrationAccountName); + + /** + * Deletes an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable deleteAsync(String resourceGroupName, String integrationAccountName, String schemaName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSession.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSession.java new file mode 100644 index 000000000000..2e60dc4e99b9 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSession.java @@ -0,0 +1,187 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountSessionInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.model.Updatable; +import com.microsoft.azure.arm.model.Appliable; +import com.microsoft.azure.arm.model.Creatable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import java.util.Map; +import org.joda.time.DateTime; + +/** + * Type representing IntegrationAccountSession. + */ +public interface IntegrationAccountSession extends HasInner, Indexable, Refreshable, Updatable, HasManager { + /** + * @return the changedTime value. + */ + DateTime changedTime(); + + /** + * @return the content value. + */ + Object content(); + + /** + * @return the createdTime value. + */ + DateTime createdTime(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the type value. + */ + String type(); + + /** + * The entirety of the IntegrationAccountSession definition. + */ + interface Definition extends DefinitionStages.Blank, DefinitionStages.WithIntegrationAccount, DefinitionStages.WithCreate { + } + + /** + * Grouping of IntegrationAccountSession definition stages. + */ + interface DefinitionStages { + /** + * The first stage of a IntegrationAccountSession definition. + */ + interface Blank extends WithIntegrationAccount { + } + + /** + * The stage of the integrationaccountsession definition allowing to specify IntegrationAccount. + */ + interface WithIntegrationAccount { + /** + * Specifies resourceGroupName, integrationAccountName. + * @param resourceGroupName The resource group name + * @param integrationAccountName The integration account name + * @return the next definition stage + */ + WithCreate withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the integrationaccountsession definition allowing to specify Content. + */ + interface WithContent { + /** + * Specifies content. + * @param content The session content + * @return the next definition stage + */ + WithCreate withContent(Object content); + } + + /** + * The stage of the integrationaccountsession definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next definition stage + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the integrationaccountsession definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next definition stage + */ + WithCreate withTags(Map tags); + } + + /** + * The stage of the definition which contains all the minimum required inputs for + * the resource to be created (via {@link WithCreate#create()}), but also allows + * for any other optional settings to be specified. + */ + interface WithCreate extends Creatable, DefinitionStages.WithContent, DefinitionStages.WithLocation, DefinitionStages.WithTags { + } + } + /** + * The template for a IntegrationAccountSession update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable, UpdateStages.WithContent, UpdateStages.WithLocation, UpdateStages.WithTags { + } + + /** + * Grouping of IntegrationAccountSession update stages. + */ + interface UpdateStages { + /** + * The stage of the integrationaccountsession update allowing to specify Content. + */ + interface WithContent { + /** + * Specifies content. + * @param content The session content + * @return the next update stage + */ + Update withContent(Object content); + } + + /** + * The stage of the integrationaccountsession update allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + * @param location The resource location + * @return the next update stage + */ + Update withLocation(String location); + } + + /** + * The stage of the integrationaccountsession update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + * @param tags The resource tags + * @return the next update stage + */ + Update withTags(Map tags); + } + + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSessionFilter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSessionFilter.java new file mode 100644 index 000000000000..f10ecc5b3724 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSessionFilter.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import org.joda.time.DateTime; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration account session filter. + */ +public class IntegrationAccountSessionFilter { + /** + * The changed time of integration account sessions. + */ + @JsonProperty(value = "changedTime", required = true) + private DateTime changedTime; + + /** + * Get the changed time of integration account sessions. + * + * @return the changedTime value + */ + public DateTime changedTime() { + return this.changedTime; + } + + /** + * Set the changed time of integration account sessions. + * + * @param changedTime the changedTime value to set + * @return the IntegrationAccountSessionFilter object itself. + */ + public IntegrationAccountSessionFilter withChangedTime(DateTime changedTime) { + this.changedTime = changedTime; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSessions.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSessions.java new file mode 100644 index 000000000000..76bbbb1adb9c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSessions.java @@ -0,0 +1,53 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountSessionsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationAccountSessions. + */ +public interface IntegrationAccountSessions extends SupportsCreating, HasInner { + /** + * Gets an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String integrationAccountName, String sessionName); + + /** + * Gets a list of integration account sessions. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroupName, final String integrationAccountName); + + /** + * Deletes an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable deleteAsync(String resourceGroupName, String integrationAccountName, String sessionName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSku.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSku.java new file mode 100644 index 000000000000..91f4e0f4fe7a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSku.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration account sku. + */ +public class IntegrationAccountSku { + /** + * The sku name. Possible values include: 'NotSpecified', 'Free', 'Basic', + * 'Standard'. + */ + @JsonProperty(value = "name", required = true) + private IntegrationAccountSkuName name; + + /** + * Get the sku name. Possible values include: 'NotSpecified', 'Free', 'Basic', 'Standard'. + * + * @return the name value + */ + public IntegrationAccountSkuName name() { + return this.name; + } + + /** + * Set the sku name. Possible values include: 'NotSpecified', 'Free', 'Basic', 'Standard'. + * + * @param name the name value to set + * @return the IntegrationAccountSku object itself. + */ + public IntegrationAccountSku withName(IntegrationAccountSkuName name) { + this.name = name; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSkuName.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSkuName.java new file mode 100644 index 000000000000..81b84b6ae61d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccountSkuName.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for IntegrationAccountSkuName. + */ +public final class IntegrationAccountSkuName extends ExpandableStringEnum { + /** Static value NotSpecified for IntegrationAccountSkuName. */ + public static final IntegrationAccountSkuName NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Free for IntegrationAccountSkuName. */ + public static final IntegrationAccountSkuName FREE = fromString("Free"); + + /** Static value Basic for IntegrationAccountSkuName. */ + public static final IntegrationAccountSkuName BASIC = fromString("Basic"); + + /** Static value Standard for IntegrationAccountSkuName. */ + public static final IntegrationAccountSkuName STANDARD = fromString("Standard"); + + /** + * Creates or finds a IntegrationAccountSkuName from its string representation. + * @param name a name to look for + * @return the corresponding IntegrationAccountSkuName + */ + @JsonCreator + public static IntegrationAccountSkuName fromString(String name) { + return fromString(name, IntegrationAccountSkuName.class); + } + + /** + * @return known IntegrationAccountSkuName values + */ + public static Collection values() { + return values(IntegrationAccountSkuName.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccounts.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccounts.java new file mode 100644 index 000000000000..c763b4477e30 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationAccounts.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import com.microsoft.azure.arm.resources.collection.SupportsDeletingByResourceGroup; +import com.microsoft.azure.arm.resources.collection.SupportsBatchDeletion; +import com.microsoft.azure.arm.resources.collection.SupportsGettingByResourceGroup; +import rx.Observable; +import com.microsoft.azure.arm.resources.collection.SupportsListingByResourceGroup; +import com.microsoft.azure.arm.collection.SupportsListing; +import rx.Completable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationAccountsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationAccounts. + */ +public interface IntegrationAccounts extends SupportsCreating, SupportsDeletingByResourceGroup, SupportsBatchDeletion, SupportsGettingByResourceGroup, SupportsListingByResourceGroup, SupportsListing, HasInner { + /** + * Gets the integration account callback URL. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param parameters The callback URL parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listCallbackUrlAsync(String resourceGroupName, String integrationAccountName, GetCallbackUrlParameters parameters); + + /** + * Gets the integration account's Key Vault keys. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param listKeyVaultKeys The key vault parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listKeyVaultKeysAsync(String resourceGroupName, String integrationAccountName, ListKeyVaultKeysDefinition listKeyVaultKeys); + + /** + * Logs the integration account's tracking events. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param logTrackingEvents The callback URL parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable logTrackingEventsAsync(String resourceGroupName, String integrationAccountName, TrackingEventsDefinition logTrackingEvents); + + /** + * Regenerates the integration account access key. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable regenerateAccessKeyAsync(String resourceGroupName, String integrationAccountName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmenEncryptionConfiguration.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmenEncryptionConfiguration.java new file mode 100644 index 000000000000..ee54444c18ca --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmenEncryptionConfiguration.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The encryption configuration for the integration service environment. + */ +public class IntegrationServiceEnvironmenEncryptionConfiguration { + /** + * The encryption key reference. + */ + @JsonProperty(value = "encryptionKeyReference") + private IntegrationServiceEnvironmenEncryptionKeyReference encryptionKeyReference; + + /** + * Get the encryption key reference. + * + * @return the encryptionKeyReference value + */ + public IntegrationServiceEnvironmenEncryptionKeyReference encryptionKeyReference() { + return this.encryptionKeyReference; + } + + /** + * Set the encryption key reference. + * + * @param encryptionKeyReference the encryptionKeyReference value to set + * @return the IntegrationServiceEnvironmenEncryptionConfiguration object itself. + */ + public IntegrationServiceEnvironmenEncryptionConfiguration withEncryptionKeyReference(IntegrationServiceEnvironmenEncryptionKeyReference encryptionKeyReference) { + this.encryptionKeyReference = encryptionKeyReference; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmenEncryptionKeyReference.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmenEncryptionKeyReference.java new file mode 100644 index 000000000000..ebbb8ba95db8 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmenEncryptionKeyReference.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The encryption key details for the integration service environment. + */ +public class IntegrationServiceEnvironmenEncryptionKeyReference { + /** + * The key vault reference. + */ + @JsonProperty(value = "keyVault") + private ResourceReference keyVault; + + /** + * Gets the key name in the Key Vault. + */ + @JsonProperty(value = "keyName") + private String keyName; + + /** + * Gets the version of the key specified in the keyName property. + */ + @JsonProperty(value = "keyVersion") + private String keyVersion; + + /** + * Get the key vault reference. + * + * @return the keyVault value + */ + public ResourceReference keyVault() { + return this.keyVault; + } + + /** + * Set the key vault reference. + * + * @param keyVault the keyVault value to set + * @return the IntegrationServiceEnvironmenEncryptionKeyReference object itself. + */ + public IntegrationServiceEnvironmenEncryptionKeyReference withKeyVault(ResourceReference keyVault) { + this.keyVault = keyVault; + return this; + } + + /** + * Get gets the key name in the Key Vault. + * + * @return the keyName value + */ + public String keyName() { + return this.keyName; + } + + /** + * Set gets the key name in the Key Vault. + * + * @param keyName the keyName value to set + * @return the IntegrationServiceEnvironmenEncryptionKeyReference object itself. + */ + public IntegrationServiceEnvironmenEncryptionKeyReference withKeyName(String keyName) { + this.keyName = keyName; + return this; + } + + /** + * Get gets the version of the key specified in the keyName property. + * + * @return the keyVersion value + */ + public String keyVersion() { + return this.keyVersion; + } + + /** + * Set gets the version of the key specified in the keyName property. + * + * @param keyVersion the keyVersion value to set + * @return the IntegrationServiceEnvironmenEncryptionKeyReference object itself. + */ + public IntegrationServiceEnvironmenEncryptionKeyReference withKeyVersion(String keyVersion) { + this.keyVersion = keyVersion; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironment.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironment.java new file mode 100644 index 000000000000..9f64f85a024d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironment.java @@ -0,0 +1,127 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.Resource; +import com.microsoft.azure.arm.resources.models.GroupableResourceCore; +import com.microsoft.azure.arm.resources.models.HasResourceGroup; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.model.Updatable; +import com.microsoft.azure.arm.model.Appliable; +import com.microsoft.azure.arm.model.Creatable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationServiceEnvironmentSkuInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationServiceEnvironmentInner; + +/** + * Type representing IntegrationServiceEnvironment. + */ +public interface IntegrationServiceEnvironment extends HasInner, Resource, GroupableResourceCore, HasResourceGroup, Refreshable, Updatable, HasManager { + /** + * @return the properties value. + */ + IntegrationServiceEnvironmentProperties properties(); + + /** + * @return the sku value. + */ + IntegrationServiceEnvironmentSkuInner sku(); + + /** + * The entirety of the IntegrationServiceEnvironment definition. + */ + interface Definition extends DefinitionStages.Blank, DefinitionStages.WithGroup, DefinitionStages.WithCreate { + } + + /** + * Grouping of IntegrationServiceEnvironment definition stages. + */ + interface DefinitionStages { + /** + * The first stage of a IntegrationServiceEnvironment definition. + */ + interface Blank extends GroupableResourceCore.DefinitionWithRegion { + } + + /** + * The stage of the IntegrationServiceEnvironment definition allowing to specify the resource group. + */ + interface WithGroup extends GroupableResourceCore.DefinitionStages.WithGroup { + } + + /** + * The stage of the integrationserviceenvironment definition allowing to specify Properties. + */ + interface WithProperties { + /** + * Specifies properties. + * @param properties The integration service environment properties + * @return the next definition stage + */ + WithCreate withProperties(IntegrationServiceEnvironmentProperties properties); + } + + /** + * The stage of the integrationserviceenvironment definition allowing to specify Sku. + */ + interface WithSku { + /** + * Specifies sku. + * @param sku The sku + * @return the next definition stage + */ + WithCreate withSku(IntegrationServiceEnvironmentSkuInner sku); + } + + /** + * The stage of the definition which contains all the minimum required inputs for + * the resource to be created (via {@link WithCreate#create()}), but also allows + * for any other optional settings to be specified. + */ + interface WithCreate extends Creatable, Resource.DefinitionWithTags, DefinitionStages.WithProperties, DefinitionStages.WithSku { + } + } + /** + * The template for a IntegrationServiceEnvironment update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable, Resource.UpdateWithTags, UpdateStages.WithProperties, UpdateStages.WithSku { + } + + /** + * Grouping of IntegrationServiceEnvironment update stages. + */ + interface UpdateStages { + /** + * The stage of the integrationserviceenvironment update allowing to specify Properties. + */ + interface WithProperties { + /** + * Specifies properties. + * @param properties The integration service environment properties + * @return the next update stage + */ + Update withProperties(IntegrationServiceEnvironmentProperties properties); + } + + /** + * The stage of the integrationserviceenvironment update allowing to specify Sku. + */ + interface WithSku { + /** + * Specifies sku. + * @param sku The sku + * @return the next update stage + */ + Update withSku(IntegrationServiceEnvironmentSkuInner sku); + } + + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentAccessEndpoint.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentAccessEndpoint.java new file mode 100644 index 000000000000..ec42cb0c0b14 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentAccessEndpoint.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration service environment access endpoint. + */ +public class IntegrationServiceEnvironmentAccessEndpoint { + /** + * The access endpoint type. Possible values include: 'NotSpecified', + * 'External', 'Internal'. + */ + @JsonProperty(value = "type") + private IntegrationServiceEnvironmentAccessEndpointType type; + + /** + * Get the access endpoint type. Possible values include: 'NotSpecified', 'External', 'Internal'. + * + * @return the type value + */ + public IntegrationServiceEnvironmentAccessEndpointType type() { + return this.type; + } + + /** + * Set the access endpoint type. Possible values include: 'NotSpecified', 'External', 'Internal'. + * + * @param type the type value to set + * @return the IntegrationServiceEnvironmentAccessEndpoint object itself. + */ + public IntegrationServiceEnvironmentAccessEndpoint withType(IntegrationServiceEnvironmentAccessEndpointType type) { + this.type = type; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentAccessEndpointType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentAccessEndpointType.java new file mode 100644 index 000000000000..971ff594d2bf --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentAccessEndpointType.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for IntegrationServiceEnvironmentAccessEndpointType. + */ +public final class IntegrationServiceEnvironmentAccessEndpointType extends ExpandableStringEnum { + /** Static value NotSpecified for IntegrationServiceEnvironmentAccessEndpointType. */ + public static final IntegrationServiceEnvironmentAccessEndpointType NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value External for IntegrationServiceEnvironmentAccessEndpointType. */ + public static final IntegrationServiceEnvironmentAccessEndpointType EXTERNAL = fromString("External"); + + /** Static value Internal for IntegrationServiceEnvironmentAccessEndpointType. */ + public static final IntegrationServiceEnvironmentAccessEndpointType INTERNAL = fromString("Internal"); + + /** + * Creates or finds a IntegrationServiceEnvironmentAccessEndpointType from its string representation. + * @param name a name to look for + * @return the corresponding IntegrationServiceEnvironmentAccessEndpointType + */ + @JsonCreator + public static IntegrationServiceEnvironmentAccessEndpointType fromString(String name) { + return fromString(name, IntegrationServiceEnvironmentAccessEndpointType.class); + } + + /** + * @return known IntegrationServiceEnvironmentAccessEndpointType values + */ + public static Collection values() { + return values(IntegrationServiceEnvironmentAccessEndpointType.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentManagedApiOperations.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentManagedApiOperations.java new file mode 100644 index 000000000000..78158f60f0dd --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentManagedApiOperations.java @@ -0,0 +1,30 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationServiceEnvironmentManagedApiOperationsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationServiceEnvironmentManagedApiOperations. + */ +public interface IntegrationServiceEnvironmentManagedApiOperations extends HasInner { + /** + * Gets the managed Api operations. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroup, final String integrationServiceEnvironmentName, final String apiName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentManagedApis.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentManagedApis.java new file mode 100644 index 000000000000..3aa436404142 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentManagedApis.java @@ -0,0 +1,53 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationServiceEnvironmentManagedApisInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationServiceEnvironmentManagedApis. + */ +public interface IntegrationServiceEnvironmentManagedApis extends SupportsCreating, HasInner { + /** + * Gets the integration service environment managed Api. + * + * @param resourceGroup The resource group name. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName); + + /** + * Gets the integration service environment managed Apis. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroup, final String integrationServiceEnvironmentName); + + /** + * Deletes the integration service environment managed Api. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable deleteAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkDependency.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkDependency.java new file mode 100644 index 000000000000..d4f3cda788c6 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkDependency.java @@ -0,0 +1,101 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The azure async operation resource. + */ +public class IntegrationServiceEnvironmentNetworkDependency { + /** + * The network dependency category type. Possible values include: + * 'NotSpecified', 'AzureStorage', 'AzureManagement', + * 'AzureActiveDirectory', 'SSLCertificateVerification', + * 'DiagnosticLogsAndMetrics', 'IntegrationServiceEnvironmentConnectors', + * 'RedisCache', 'AccessEndpoints', 'RecoveryService', 'SQL', + * 'RegionalService'. + */ + @JsonProperty(value = "category") + private IntegrationServiceEnvironmentNetworkDependencyCategoryType category; + + /** + * The display name. + */ + @JsonProperty(value = "displayName") + private String displayName; + + /** + * The endpoints. + */ + @JsonProperty(value = "endpoints") + private List endpoints; + + /** + * Get the network dependency category type. Possible values include: 'NotSpecified', 'AzureStorage', 'AzureManagement', 'AzureActiveDirectory', 'SSLCertificateVerification', 'DiagnosticLogsAndMetrics', 'IntegrationServiceEnvironmentConnectors', 'RedisCache', 'AccessEndpoints', 'RecoveryService', 'SQL', 'RegionalService'. + * + * @return the category value + */ + public IntegrationServiceEnvironmentNetworkDependencyCategoryType category() { + return this.category; + } + + /** + * Set the network dependency category type. Possible values include: 'NotSpecified', 'AzureStorage', 'AzureManagement', 'AzureActiveDirectory', 'SSLCertificateVerification', 'DiagnosticLogsAndMetrics', 'IntegrationServiceEnvironmentConnectors', 'RedisCache', 'AccessEndpoints', 'RecoveryService', 'SQL', 'RegionalService'. + * + * @param category the category value to set + * @return the IntegrationServiceEnvironmentNetworkDependency object itself. + */ + public IntegrationServiceEnvironmentNetworkDependency withCategory(IntegrationServiceEnvironmentNetworkDependencyCategoryType category) { + this.category = category; + return this; + } + + /** + * Get the display name. + * + * @return the displayName value + */ + public String displayName() { + return this.displayName; + } + + /** + * Set the display name. + * + * @param displayName the displayName value to set + * @return the IntegrationServiceEnvironmentNetworkDependency object itself. + */ + public IntegrationServiceEnvironmentNetworkDependency withDisplayName(String displayName) { + this.displayName = displayName; + return this; + } + + /** + * Get the endpoints. + * + * @return the endpoints value + */ + public List endpoints() { + return this.endpoints; + } + + /** + * Set the endpoints. + * + * @param endpoints the endpoints value to set + * @return the IntegrationServiceEnvironmentNetworkDependency object itself. + */ + public IntegrationServiceEnvironmentNetworkDependency withEndpoints(List endpoints) { + this.endpoints = endpoints; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkDependencyCategoryType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkDependencyCategoryType.java new file mode 100644 index 000000000000..fbd8e47e0a12 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkDependencyCategoryType.java @@ -0,0 +1,71 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for IntegrationServiceEnvironmentNetworkDependencyCategoryType. + */ +public final class IntegrationServiceEnvironmentNetworkDependencyCategoryType extends ExpandableStringEnum { + /** Static value NotSpecified for IntegrationServiceEnvironmentNetworkDependencyCategoryType. */ + public static final IntegrationServiceEnvironmentNetworkDependencyCategoryType NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value AzureStorage for IntegrationServiceEnvironmentNetworkDependencyCategoryType. */ + public static final IntegrationServiceEnvironmentNetworkDependencyCategoryType AZURE_STORAGE = fromString("AzureStorage"); + + /** Static value AzureManagement for IntegrationServiceEnvironmentNetworkDependencyCategoryType. */ + public static final IntegrationServiceEnvironmentNetworkDependencyCategoryType AZURE_MANAGEMENT = fromString("AzureManagement"); + + /** Static value AzureActiveDirectory for IntegrationServiceEnvironmentNetworkDependencyCategoryType. */ + public static final IntegrationServiceEnvironmentNetworkDependencyCategoryType AZURE_ACTIVE_DIRECTORY = fromString("AzureActiveDirectory"); + + /** Static value SSLCertificateVerification for IntegrationServiceEnvironmentNetworkDependencyCategoryType. */ + public static final IntegrationServiceEnvironmentNetworkDependencyCategoryType SSLCERTIFICATE_VERIFICATION = fromString("SSLCertificateVerification"); + + /** Static value DiagnosticLogsAndMetrics for IntegrationServiceEnvironmentNetworkDependencyCategoryType. */ + public static final IntegrationServiceEnvironmentNetworkDependencyCategoryType DIAGNOSTIC_LOGS_AND_METRICS = fromString("DiagnosticLogsAndMetrics"); + + /** Static value IntegrationServiceEnvironmentConnectors for IntegrationServiceEnvironmentNetworkDependencyCategoryType. */ + public static final IntegrationServiceEnvironmentNetworkDependencyCategoryType INTEGRATION_SERVICE_ENVIRONMENT_CONNECTORS = fromString("IntegrationServiceEnvironmentConnectors"); + + /** Static value RedisCache for IntegrationServiceEnvironmentNetworkDependencyCategoryType. */ + public static final IntegrationServiceEnvironmentNetworkDependencyCategoryType REDIS_CACHE = fromString("RedisCache"); + + /** Static value AccessEndpoints for IntegrationServiceEnvironmentNetworkDependencyCategoryType. */ + public static final IntegrationServiceEnvironmentNetworkDependencyCategoryType ACCESS_ENDPOINTS = fromString("AccessEndpoints"); + + /** Static value RecoveryService for IntegrationServiceEnvironmentNetworkDependencyCategoryType. */ + public static final IntegrationServiceEnvironmentNetworkDependencyCategoryType RECOVERY_SERVICE = fromString("RecoveryService"); + + /** Static value SQL for IntegrationServiceEnvironmentNetworkDependencyCategoryType. */ + public static final IntegrationServiceEnvironmentNetworkDependencyCategoryType SQL = fromString("SQL"); + + /** Static value RegionalService for IntegrationServiceEnvironmentNetworkDependencyCategoryType. */ + public static final IntegrationServiceEnvironmentNetworkDependencyCategoryType REGIONAL_SERVICE = fromString("RegionalService"); + + /** + * Creates or finds a IntegrationServiceEnvironmentNetworkDependencyCategoryType from its string representation. + * @param name a name to look for + * @return the corresponding IntegrationServiceEnvironmentNetworkDependencyCategoryType + */ + @JsonCreator + public static IntegrationServiceEnvironmentNetworkDependencyCategoryType fromString(String name) { + return fromString(name, IntegrationServiceEnvironmentNetworkDependencyCategoryType.class); + } + + /** + * @return known IntegrationServiceEnvironmentNetworkDependencyCategoryType values + */ + public static Collection values() { + return values(IntegrationServiceEnvironmentNetworkDependencyCategoryType.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkDependencyHealth.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkDependencyHealth.java new file mode 100644 index 000000000000..93914a2dd507 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkDependencyHealth.java @@ -0,0 +1,70 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration service environment subnet network health. + */ +public class IntegrationServiceEnvironmentNetworkDependencyHealth { + /** + * The error if any occurred during the operation. + */ + @JsonProperty(value = "error") + private ExtendedErrorInfo error; + + /** + * The network dependency health state. Possible values include: + * 'NotSpecified', 'Healthy', 'Unhealthy', 'Unknown'. + */ + @JsonProperty(value = "state") + private IntegrationServiceEnvironmentNetworkDependencyHealthState state; + + /** + * Get the error if any occurred during the operation. + * + * @return the error value + */ + public ExtendedErrorInfo error() { + return this.error; + } + + /** + * Set the error if any occurred during the operation. + * + * @param error the error value to set + * @return the IntegrationServiceEnvironmentNetworkDependencyHealth object itself. + */ + public IntegrationServiceEnvironmentNetworkDependencyHealth withError(ExtendedErrorInfo error) { + this.error = error; + return this; + } + + /** + * Get the network dependency health state. Possible values include: 'NotSpecified', 'Healthy', 'Unhealthy', 'Unknown'. + * + * @return the state value + */ + public IntegrationServiceEnvironmentNetworkDependencyHealthState state() { + return this.state; + } + + /** + * Set the network dependency health state. Possible values include: 'NotSpecified', 'Healthy', 'Unhealthy', 'Unknown'. + * + * @param state the state value to set + * @return the IntegrationServiceEnvironmentNetworkDependencyHealth object itself. + */ + public IntegrationServiceEnvironmentNetworkDependencyHealth withState(IntegrationServiceEnvironmentNetworkDependencyHealthState state) { + this.state = state; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkDependencyHealthState.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkDependencyHealthState.java new file mode 100644 index 000000000000..6bd979d1c4cb --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkDependencyHealthState.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for IntegrationServiceEnvironmentNetworkDependencyHealthState. + */ +public final class IntegrationServiceEnvironmentNetworkDependencyHealthState extends ExpandableStringEnum { + /** Static value NotSpecified for IntegrationServiceEnvironmentNetworkDependencyHealthState. */ + public static final IntegrationServiceEnvironmentNetworkDependencyHealthState NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Healthy for IntegrationServiceEnvironmentNetworkDependencyHealthState. */ + public static final IntegrationServiceEnvironmentNetworkDependencyHealthState HEALTHY = fromString("Healthy"); + + /** Static value Unhealthy for IntegrationServiceEnvironmentNetworkDependencyHealthState. */ + public static final IntegrationServiceEnvironmentNetworkDependencyHealthState UNHEALTHY = fromString("Unhealthy"); + + /** Static value Unknown for IntegrationServiceEnvironmentNetworkDependencyHealthState. */ + public static final IntegrationServiceEnvironmentNetworkDependencyHealthState UNKNOWN = fromString("Unknown"); + + /** + * Creates or finds a IntegrationServiceEnvironmentNetworkDependencyHealthState from its string representation. + * @param name a name to look for + * @return the corresponding IntegrationServiceEnvironmentNetworkDependencyHealthState + */ + @JsonCreator + public static IntegrationServiceEnvironmentNetworkDependencyHealthState fromString(String name) { + return fromString(name, IntegrationServiceEnvironmentNetworkDependencyHealthState.class); + } + + /** + * @return known IntegrationServiceEnvironmentNetworkDependencyHealthState values + */ + public static Collection values() { + return values(IntegrationServiceEnvironmentNetworkDependencyHealthState.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkEndPointAccessibilityState.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkEndPointAccessibilityState.java new file mode 100644 index 000000000000..bbe42dce0d26 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkEndPointAccessibilityState.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for IntegrationServiceEnvironmentNetworkEndPointAccessibilityState. + */ +public final class IntegrationServiceEnvironmentNetworkEndPointAccessibilityState extends ExpandableStringEnum { + /** Static value NotSpecified for IntegrationServiceEnvironmentNetworkEndPointAccessibilityState. */ + public static final IntegrationServiceEnvironmentNetworkEndPointAccessibilityState NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Unknown for IntegrationServiceEnvironmentNetworkEndPointAccessibilityState. */ + public static final IntegrationServiceEnvironmentNetworkEndPointAccessibilityState UNKNOWN = fromString("Unknown"); + + /** Static value Available for IntegrationServiceEnvironmentNetworkEndPointAccessibilityState. */ + public static final IntegrationServiceEnvironmentNetworkEndPointAccessibilityState AVAILABLE = fromString("Available"); + + /** Static value NotAvailable for IntegrationServiceEnvironmentNetworkEndPointAccessibilityState. */ + public static final IntegrationServiceEnvironmentNetworkEndPointAccessibilityState NOT_AVAILABLE = fromString("NotAvailable"); + + /** + * Creates or finds a IntegrationServiceEnvironmentNetworkEndPointAccessibilityState from its string representation. + * @param name a name to look for + * @return the corresponding IntegrationServiceEnvironmentNetworkEndPointAccessibilityState + */ + @JsonCreator + public static IntegrationServiceEnvironmentNetworkEndPointAccessibilityState fromString(String name) { + return fromString(name, IntegrationServiceEnvironmentNetworkEndPointAccessibilityState.class); + } + + /** + * @return known IntegrationServiceEnvironmentNetworkEndPointAccessibilityState values + */ + public static Collection values() { + return values(IntegrationServiceEnvironmentNetworkEndPointAccessibilityState.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkEndpoint.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkEndpoint.java new file mode 100644 index 000000000000..d733f1d7ceac --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkEndpoint.java @@ -0,0 +1,97 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The network endpoint. + */ +public class IntegrationServiceEnvironmentNetworkEndpoint { + /** + * The accessibility state. Possible values include: 'NotSpecified', + * 'Unknown', 'Available', 'NotAvailable'. + */ + @JsonProperty(value = "accessibility") + private IntegrationServiceEnvironmentNetworkEndPointAccessibilityState accessibility; + + /** + * The domain name. + */ + @JsonProperty(value = "domainName") + private String domainName; + + /** + * The ports. + */ + @JsonProperty(value = "ports") + private List ports; + + /** + * Get the accessibility state. Possible values include: 'NotSpecified', 'Unknown', 'Available', 'NotAvailable'. + * + * @return the accessibility value + */ + public IntegrationServiceEnvironmentNetworkEndPointAccessibilityState accessibility() { + return this.accessibility; + } + + /** + * Set the accessibility state. Possible values include: 'NotSpecified', 'Unknown', 'Available', 'NotAvailable'. + * + * @param accessibility the accessibility value to set + * @return the IntegrationServiceEnvironmentNetworkEndpoint object itself. + */ + public IntegrationServiceEnvironmentNetworkEndpoint withAccessibility(IntegrationServiceEnvironmentNetworkEndPointAccessibilityState accessibility) { + this.accessibility = accessibility; + return this; + } + + /** + * Get the domain name. + * + * @return the domainName value + */ + public String domainName() { + return this.domainName; + } + + /** + * Set the domain name. + * + * @param domainName the domainName value to set + * @return the IntegrationServiceEnvironmentNetworkEndpoint object itself. + */ + public IntegrationServiceEnvironmentNetworkEndpoint withDomainName(String domainName) { + this.domainName = domainName; + return this; + } + + /** + * Get the ports. + * + * @return the ports value + */ + public List ports() { + return this.ports; + } + + /** + * Set the ports. + * + * @param ports the ports value to set + * @return the IntegrationServiceEnvironmentNetworkEndpoint object itself. + */ + public IntegrationServiceEnvironmentNetworkEndpoint withPorts(List ports) { + this.ports = ports; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkHealths.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkHealths.java new file mode 100644 index 000000000000..9b3b1dffd4c5 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentNetworkHealths.java @@ -0,0 +1,29 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationServiceEnvironmentNetworkHealthsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationServiceEnvironmentNetworkHealths. + */ +public interface IntegrationServiceEnvironmentNetworkHealths extends HasInner { + /** + * Gets the integration service environment network health. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable> getAsync(String resourceGroup, String integrationServiceEnvironmentName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentProperties.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentProperties.java new file mode 100644 index 000000000000..22e034e2bed0 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentProperties.java @@ -0,0 +1,179 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration service environment properties. + */ +public class IntegrationServiceEnvironmentProperties { + /** + * The provisioning state. Possible values include: 'NotSpecified', + * 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', + * 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', + * 'Registering', 'Registered', 'Unregistering', 'Unregistered', + * 'Completed', 'Renewing', 'Pending', 'Waiting', 'InProgress'. + */ + @JsonProperty(value = "provisioningState") + private WorkflowProvisioningState provisioningState; + + /** + * The integration service environment state. Possible values include: + * 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', + * 'Suspended'. + */ + @JsonProperty(value = "state") + private WorkflowState state; + + /** + * Gets the tracking id. + */ + @JsonProperty(value = "integrationServiceEnvironmentId") + private String integrationServiceEnvironmentId; + + /** + * The endpoints configuration. + */ + @JsonProperty(value = "endpointsConfiguration") + private FlowEndpointsConfiguration endpointsConfiguration; + + /** + * The network configuration. + */ + @JsonProperty(value = "networkConfiguration") + private NetworkConfiguration networkConfiguration; + + /** + * The encryption configuration. + */ + @JsonProperty(value = "encryptionConfiguration") + private IntegrationServiceEnvironmenEncryptionConfiguration encryptionConfiguration; + + /** + * Get the provisioning state. Possible values include: 'NotSpecified', 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', 'Registering', 'Registered', 'Unregistering', 'Unregistered', 'Completed', 'Renewing', 'Pending', 'Waiting', 'InProgress'. + * + * @return the provisioningState value + */ + public WorkflowProvisioningState provisioningState() { + return this.provisioningState; + } + + /** + * Set the provisioning state. Possible values include: 'NotSpecified', 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', 'Registering', 'Registered', 'Unregistering', 'Unregistered', 'Completed', 'Renewing', 'Pending', 'Waiting', 'InProgress'. + * + * @param provisioningState the provisioningState value to set + * @return the IntegrationServiceEnvironmentProperties object itself. + */ + public IntegrationServiceEnvironmentProperties withProvisioningState(WorkflowProvisioningState provisioningState) { + this.provisioningState = provisioningState; + return this; + } + + /** + * Get the integration service environment state. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + * + * @return the state value + */ + public WorkflowState state() { + return this.state; + } + + /** + * Set the integration service environment state. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + * + * @param state the state value to set + * @return the IntegrationServiceEnvironmentProperties object itself. + */ + public IntegrationServiceEnvironmentProperties withState(WorkflowState state) { + this.state = state; + return this; + } + + /** + * Get gets the tracking id. + * + * @return the integrationServiceEnvironmentId value + */ + public String integrationServiceEnvironmentId() { + return this.integrationServiceEnvironmentId; + } + + /** + * Set gets the tracking id. + * + * @param integrationServiceEnvironmentId the integrationServiceEnvironmentId value to set + * @return the IntegrationServiceEnvironmentProperties object itself. + */ + public IntegrationServiceEnvironmentProperties withIntegrationServiceEnvironmentId(String integrationServiceEnvironmentId) { + this.integrationServiceEnvironmentId = integrationServiceEnvironmentId; + return this; + } + + /** + * Get the endpoints configuration. + * + * @return the endpointsConfiguration value + */ + public FlowEndpointsConfiguration endpointsConfiguration() { + return this.endpointsConfiguration; + } + + /** + * Set the endpoints configuration. + * + * @param endpointsConfiguration the endpointsConfiguration value to set + * @return the IntegrationServiceEnvironmentProperties object itself. + */ + public IntegrationServiceEnvironmentProperties withEndpointsConfiguration(FlowEndpointsConfiguration endpointsConfiguration) { + this.endpointsConfiguration = endpointsConfiguration; + return this; + } + + /** + * Get the network configuration. + * + * @return the networkConfiguration value + */ + public NetworkConfiguration networkConfiguration() { + return this.networkConfiguration; + } + + /** + * Set the network configuration. + * + * @param networkConfiguration the networkConfiguration value to set + * @return the IntegrationServiceEnvironmentProperties object itself. + */ + public IntegrationServiceEnvironmentProperties withNetworkConfiguration(NetworkConfiguration networkConfiguration) { + this.networkConfiguration = networkConfiguration; + return this; + } + + /** + * Get the encryption configuration. + * + * @return the encryptionConfiguration value + */ + public IntegrationServiceEnvironmenEncryptionConfiguration encryptionConfiguration() { + return this.encryptionConfiguration; + } + + /** + * Set the encryption configuration. + * + * @param encryptionConfiguration the encryptionConfiguration value to set + * @return the IntegrationServiceEnvironmentProperties object itself. + */ + public IntegrationServiceEnvironmentProperties withEncryptionConfiguration(IntegrationServiceEnvironmenEncryptionConfiguration encryptionConfiguration) { + this.encryptionConfiguration = encryptionConfiguration; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuCapacity.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuCapacity.java new file mode 100644 index 000000000000..f5a4aa5321ee --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuCapacity.java @@ -0,0 +1,122 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration service environment sku capacity. + */ +public class IntegrationServiceEnvironmentSkuCapacity { + /** + * The minimum capacity. + */ + @JsonProperty(value = "minimum") + private Integer minimum; + + /** + * The maximum capacity. + */ + @JsonProperty(value = "maximum") + private Integer maximum; + + /** + * The default capacity. + */ + @JsonProperty(value = "default") + private Integer defaultProperty; + + /** + * The sku scale type. Possible values include: 'Manual', 'Automatic', + * 'None'. + */ + @JsonProperty(value = "scaleType") + private IntegrationServiceEnvironmentSkuScaleType scaleType; + + /** + * Get the minimum capacity. + * + * @return the minimum value + */ + public Integer minimum() { + return this.minimum; + } + + /** + * Set the minimum capacity. + * + * @param minimum the minimum value to set + * @return the IntegrationServiceEnvironmentSkuCapacity object itself. + */ + public IntegrationServiceEnvironmentSkuCapacity withMinimum(Integer minimum) { + this.minimum = minimum; + return this; + } + + /** + * Get the maximum capacity. + * + * @return the maximum value + */ + public Integer maximum() { + return this.maximum; + } + + /** + * Set the maximum capacity. + * + * @param maximum the maximum value to set + * @return the IntegrationServiceEnvironmentSkuCapacity object itself. + */ + public IntegrationServiceEnvironmentSkuCapacity withMaximum(Integer maximum) { + this.maximum = maximum; + return this; + } + + /** + * Get the default capacity. + * + * @return the defaultProperty value + */ + public Integer defaultProperty() { + return this.defaultProperty; + } + + /** + * Set the default capacity. + * + * @param defaultProperty the defaultProperty value to set + * @return the IntegrationServiceEnvironmentSkuCapacity object itself. + */ + public IntegrationServiceEnvironmentSkuCapacity withDefaultProperty(Integer defaultProperty) { + this.defaultProperty = defaultProperty; + return this; + } + + /** + * Get the sku scale type. Possible values include: 'Manual', 'Automatic', 'None'. + * + * @return the scaleType value + */ + public IntegrationServiceEnvironmentSkuScaleType scaleType() { + return this.scaleType; + } + + /** + * Set the sku scale type. Possible values include: 'Manual', 'Automatic', 'None'. + * + * @param scaleType the scaleType value to set + * @return the IntegrationServiceEnvironmentSkuCapacity object itself. + */ + public IntegrationServiceEnvironmentSkuCapacity withScaleType(IntegrationServiceEnvironmentSkuScaleType scaleType) { + this.scaleType = scaleType; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuDefinition.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuDefinition.java new file mode 100644 index 000000000000..c6e654c36562 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuDefinition.java @@ -0,0 +1,35 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationServiceEnvironmentSkuDefinitionInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; + +/** + * Type representing IntegrationServiceEnvironmentSkuDefinition. + */ +public interface IntegrationServiceEnvironmentSkuDefinition extends HasInner, HasManager { + /** + * @return the capacity value. + */ + IntegrationServiceEnvironmentSkuCapacity capacity(); + + /** + * @return the resourceType value. + */ + String resourceType(); + + /** + * @return the sku value. + */ + IntegrationServiceEnvironmentSkuDefinitionSku sku(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuDefinitionSku.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuDefinitionSku.java new file mode 100644 index 000000000000..8a509171b76f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuDefinitionSku.java @@ -0,0 +1,70 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The sku. + */ +public class IntegrationServiceEnvironmentSkuDefinitionSku { + /** + * The sku name. Possible values include: 'NotSpecified', 'Premium', + * 'Developer'. + */ + @JsonProperty(value = "name") + private IntegrationServiceEnvironmentSkuName name; + + /** + * The sku tier. + */ + @JsonProperty(value = "tier") + private String tier; + + /** + * Get the sku name. Possible values include: 'NotSpecified', 'Premium', 'Developer'. + * + * @return the name value + */ + public IntegrationServiceEnvironmentSkuName name() { + return this.name; + } + + /** + * Set the sku name. Possible values include: 'NotSpecified', 'Premium', 'Developer'. + * + * @param name the name value to set + * @return the IntegrationServiceEnvironmentSkuDefinitionSku object itself. + */ + public IntegrationServiceEnvironmentSkuDefinitionSku withName(IntegrationServiceEnvironmentSkuName name) { + this.name = name; + return this; + } + + /** + * Get the sku tier. + * + * @return the tier value + */ + public String tier() { + return this.tier; + } + + /** + * Set the sku tier. + * + * @param tier the tier value to set + * @return the IntegrationServiceEnvironmentSkuDefinitionSku object itself. + */ + public IntegrationServiceEnvironmentSkuDefinitionSku withTier(String tier) { + this.tier = tier; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuName.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuName.java new file mode 100644 index 000000000000..22a39a3bbe96 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuName.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for IntegrationServiceEnvironmentSkuName. + */ +public final class IntegrationServiceEnvironmentSkuName extends ExpandableStringEnum { + /** Static value NotSpecified for IntegrationServiceEnvironmentSkuName. */ + public static final IntegrationServiceEnvironmentSkuName NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Premium for IntegrationServiceEnvironmentSkuName. */ + public static final IntegrationServiceEnvironmentSkuName PREMIUM = fromString("Premium"); + + /** Static value Developer for IntegrationServiceEnvironmentSkuName. */ + public static final IntegrationServiceEnvironmentSkuName DEVELOPER = fromString("Developer"); + + /** + * Creates or finds a IntegrationServiceEnvironmentSkuName from its string representation. + * @param name a name to look for + * @return the corresponding IntegrationServiceEnvironmentSkuName + */ + @JsonCreator + public static IntegrationServiceEnvironmentSkuName fromString(String name) { + return fromString(name, IntegrationServiceEnvironmentSkuName.class); + } + + /** + * @return known IntegrationServiceEnvironmentSkuName values + */ + public static Collection values() { + return values(IntegrationServiceEnvironmentSkuName.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuScaleType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuScaleType.java new file mode 100644 index 000000000000..1be253125791 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkuScaleType.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for IntegrationServiceEnvironmentSkuScaleType. + */ +public final class IntegrationServiceEnvironmentSkuScaleType extends ExpandableStringEnum { + /** Static value Manual for IntegrationServiceEnvironmentSkuScaleType. */ + public static final IntegrationServiceEnvironmentSkuScaleType MANUAL = fromString("Manual"); + + /** Static value Automatic for IntegrationServiceEnvironmentSkuScaleType. */ + public static final IntegrationServiceEnvironmentSkuScaleType AUTOMATIC = fromString("Automatic"); + + /** Static value None for IntegrationServiceEnvironmentSkuScaleType. */ + public static final IntegrationServiceEnvironmentSkuScaleType NONE = fromString("None"); + + /** + * Creates or finds a IntegrationServiceEnvironmentSkuScaleType from its string representation. + * @param name a name to look for + * @return the corresponding IntegrationServiceEnvironmentSkuScaleType + */ + @JsonCreator + public static IntegrationServiceEnvironmentSkuScaleType fromString(String name) { + return fromString(name, IntegrationServiceEnvironmentSkuScaleType.class); + } + + /** + * @return known IntegrationServiceEnvironmentSkuScaleType values + */ + public static Collection values() { + return values(IntegrationServiceEnvironmentSkuScaleType.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkus.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkus.java new file mode 100644 index 000000000000..514681b85886 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironmentSkus.java @@ -0,0 +1,29 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationServiceEnvironmentSkusInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationServiceEnvironmentSkus. + */ +public interface IntegrationServiceEnvironmentSkus extends HasInner { + /** + * Gets a list of integration service environment Skus. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroup, final String integrationServiceEnvironmentName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironments.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironments.java new file mode 100644 index 000000000000..7ad58995233a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IntegrationServiceEnvironments.java @@ -0,0 +1,36 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import com.microsoft.azure.arm.resources.collection.SupportsDeletingByResourceGroup; +import com.microsoft.azure.arm.resources.collection.SupportsBatchDeletion; +import com.microsoft.azure.arm.resources.collection.SupportsGettingByResourceGroup; +import rx.Observable; +import com.microsoft.azure.arm.resources.collection.SupportsListingByResourceGroup; +import com.microsoft.azure.arm.collection.SupportsListing; +import rx.Completable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.IntegrationServiceEnvironmentsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing IntegrationServiceEnvironments. + */ +public interface IntegrationServiceEnvironments extends SupportsCreating, SupportsDeletingByResourceGroup, SupportsBatchDeletion, SupportsGettingByResourceGroup, SupportsListingByResourceGroup, SupportsListing, HasInner { + /** + * Restarts an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable restartAsync(String resourceGroup, String integrationServiceEnvironmentName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IpAddress.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IpAddress.java new file mode 100644 index 000000000000..bc173a3229b1 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IpAddress.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The ip address. + */ +public class IpAddress { + /** + * The address. + */ + @JsonProperty(value = "address") + private String address; + + /** + * Get the address. + * + * @return the address value + */ + public String address() { + return this.address; + } + + /** + * Set the address. + * + * @param address the address value to set + * @return the IpAddress object itself. + */ + public IpAddress withAddress(String address) { + this.address = address; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IpAddressRange.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IpAddressRange.java new file mode 100644 index 000000000000..55340eaf4583 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/IpAddressRange.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The ip address range. + */ +public class IpAddressRange { + /** + * The IP address range. + */ + @JsonProperty(value = "addressRange") + private String addressRange; + + /** + * Get the IP address range. + * + * @return the addressRange value + */ + public String addressRange() { + return this.addressRange; + } + + /** + * Set the IP address range. + * + * @param addressRange the addressRange value to set + * @return the IpAddressRange object itself. + */ + public IpAddressRange withAddressRange(String addressRange) { + this.addressRange = addressRange; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/JsonSchema.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/JsonSchema.java new file mode 100644 index 000000000000..8d5068585f1c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/JsonSchema.java @@ -0,0 +1,30 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.JsonSchemaInner; + +/** + * Type representing JsonSchema. + */ +public interface JsonSchema extends HasInner, HasManager { + /** + * @return the content value. + */ + String content(); + + /** + * @return the title value. + */ + String title(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyType.java new file mode 100644 index 000000000000..ec1bd724ed1f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyType.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for KeyType. + */ +public final class KeyType extends ExpandableStringEnum { + /** Static value NotSpecified for KeyType. */ + public static final KeyType NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Primary for KeyType. */ + public static final KeyType PRIMARY = fromString("Primary"); + + /** Static value Secondary for KeyType. */ + public static final KeyType SECONDARY = fromString("Secondary"); + + /** + * Creates or finds a KeyType from its string representation. + * @param name a name to look for + * @return the corresponding KeyType + */ + @JsonCreator + public static KeyType fromString(String name) { + return fromString(name, KeyType.class); + } + + /** + * @return known KeyType values + */ + public static Collection values() { + return values(KeyType.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultKey.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultKey.java new file mode 100644 index 000000000000..3ce5d500f86b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultKey.java @@ -0,0 +1,30 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.KeyVaultKeyInner; + +/** + * Type representing KeyVaultKey. + */ +public interface KeyVaultKey extends HasInner, HasManager { + /** + * @return the attributes value. + */ + KeyVaultKeyAttributes attributes(); + + /** + * @return the kid value. + */ + String kid(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultKeyAttributes.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultKeyAttributes.java new file mode 100644 index 000000000000..fafddcb23faf --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultKeyAttributes.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The key attributes. + */ +public class KeyVaultKeyAttributes { + /** + * Whether the key is enabled or not. + */ + @JsonProperty(value = "enabled") + private Boolean enabled; + + /** + * When the key was created. + */ + @JsonProperty(value = "created") + private Long created; + + /** + * When the key was updated. + */ + @JsonProperty(value = "updated") + private Long updated; + + /** + * Get whether the key is enabled or not. + * + * @return the enabled value + */ + public Boolean enabled() { + return this.enabled; + } + + /** + * Set whether the key is enabled or not. + * + * @param enabled the enabled value to set + * @return the KeyVaultKeyAttributes object itself. + */ + public KeyVaultKeyAttributes withEnabled(Boolean enabled) { + this.enabled = enabled; + return this; + } + + /** + * Get when the key was created. + * + * @return the created value + */ + public Long created() { + return this.created; + } + + /** + * Set when the key was created. + * + * @param created the created value to set + * @return the KeyVaultKeyAttributes object itself. + */ + public KeyVaultKeyAttributes withCreated(Long created) { + this.created = created; + return this; + } + + /** + * Get when the key was updated. + * + * @return the updated value + */ + public Long updated() { + return this.updated; + } + + /** + * Set when the key was updated. + * + * @param updated the updated value to set + * @return the KeyVaultKeyAttributes object itself. + */ + public KeyVaultKeyAttributes withUpdated(Long updated) { + this.updated = updated; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultKeyReference.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultKeyReference.java new file mode 100644 index 000000000000..0f5f7df0ed6e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultKeyReference.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The reference to the key vault key. + */ +public class KeyVaultKeyReference { + /** + * The key vault reference. + */ + @JsonProperty(value = "keyVault", required = true) + private KeyVaultKeyReferenceKeyVault keyVault; + + /** + * The private key name in key vault. + */ + @JsonProperty(value = "keyName", required = true) + private String keyName; + + /** + * The private key version in key vault. + */ + @JsonProperty(value = "keyVersion") + private String keyVersion; + + /** + * Get the key vault reference. + * + * @return the keyVault value + */ + public KeyVaultKeyReferenceKeyVault keyVault() { + return this.keyVault; + } + + /** + * Set the key vault reference. + * + * @param keyVault the keyVault value to set + * @return the KeyVaultKeyReference object itself. + */ + public KeyVaultKeyReference withKeyVault(KeyVaultKeyReferenceKeyVault keyVault) { + this.keyVault = keyVault; + return this; + } + + /** + * Get the private key name in key vault. + * + * @return the keyName value + */ + public String keyName() { + return this.keyName; + } + + /** + * Set the private key name in key vault. + * + * @param keyName the keyName value to set + * @return the KeyVaultKeyReference object itself. + */ + public KeyVaultKeyReference withKeyName(String keyName) { + this.keyName = keyName; + return this; + } + + /** + * Get the private key version in key vault. + * + * @return the keyVersion value + */ + public String keyVersion() { + return this.keyVersion; + } + + /** + * Set the private key version in key vault. + * + * @param keyVersion the keyVersion value to set + * @return the KeyVaultKeyReference object itself. + */ + public KeyVaultKeyReference withKeyVersion(String keyVersion) { + this.keyVersion = keyVersion; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultKeyReferenceKeyVault.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultKeyReferenceKeyVault.java new file mode 100644 index 000000000000..dab301c3a596 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultKeyReferenceKeyVault.java @@ -0,0 +1,73 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The key vault reference. + */ +public class KeyVaultKeyReferenceKeyVault { + /** + * The resource id. + */ + @JsonProperty(value = "id") + private String id; + + /** + * The resource name. + */ + @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY) + private String name; + + /** + * The resource type. + */ + @JsonProperty(value = "type", access = JsonProperty.Access.WRITE_ONLY) + private String type; + + /** + * Get the resource id. + * + * @return the id value + */ + public String id() { + return this.id; + } + + /** + * Set the resource id. + * + * @param id the id value to set + * @return the KeyVaultKeyReferenceKeyVault object itself. + */ + public KeyVaultKeyReferenceKeyVault withId(String id) { + this.id = id; + return this; + } + + /** + * Get the resource name. + * + * @return the name value + */ + public String name() { + return this.name; + } + + /** + * Get the resource type. + * + * @return the type value + */ + public String type() { + return this.type; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultReference.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultReference.java new file mode 100644 index 000000000000..108e93e48f4d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/KeyVaultReference.java @@ -0,0 +1,16 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + + +/** + * The key vault reference. + */ +public class KeyVaultReference extends ResourceReference { +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ListKeyVaultKeysDefinition.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ListKeyVaultKeysDefinition.java new file mode 100644 index 000000000000..7f5e5c56d782 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ListKeyVaultKeysDefinition.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The list key vault keys definition. + */ +public class ListKeyVaultKeysDefinition { + /** + * The key vault reference. + */ + @JsonProperty(value = "keyVault", required = true) + private KeyVaultReference keyVault; + + /** + * The skip token. + */ + @JsonProperty(value = "skipToken") + private String skipToken; + + /** + * Get the key vault reference. + * + * @return the keyVault value + */ + public KeyVaultReference keyVault() { + return this.keyVault; + } + + /** + * Set the key vault reference. + * + * @param keyVault the keyVault value to set + * @return the ListKeyVaultKeysDefinition object itself. + */ + public ListKeyVaultKeysDefinition withKeyVault(KeyVaultReference keyVault) { + this.keyVault = keyVault; + return this; + } + + /** + * Get the skip token. + * + * @return the skipToken value + */ + public String skipToken() { + return this.skipToken; + } + + /** + * Set the skip token. + * + * @param skipToken the skipToken value to set + * @return the ListKeyVaultKeysDefinition object itself. + */ + public ListKeyVaultKeysDefinition withSkipToken(String skipToken) { + this.skipToken = skipToken; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ManagedApi.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ManagedApi.java new file mode 100644 index 000000000000..bd17d84561f8 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ManagedApi.java @@ -0,0 +1,104 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.ManagedApiInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.model.Updatable; +import com.microsoft.azure.arm.model.Appliable; +import com.microsoft.azure.arm.model.Creatable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import java.util.Map; + +/** + * Type representing ManagedApi. + */ +public interface ManagedApi extends HasInner, Indexable, Refreshable, Updatable, HasManager { + /** + * @return the id value. + */ + String id(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the properties value. + */ + ApiResourceProperties properties(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the type value. + */ + String type(); + + /** + * The entirety of the ManagedApi definition. + */ + interface Definition extends DefinitionStages.Blank, DefinitionStages.WithIntegrationServiceEnvironment, DefinitionStages.WithCreate { + } + + /** + * Grouping of ManagedApi definition stages. + */ + interface DefinitionStages { + /** + * The first stage of a ManagedApi definition. + */ + interface Blank extends WithIntegrationServiceEnvironment { + } + + /** + * The stage of the managedapi definition allowing to specify IntegrationServiceEnvironment. + */ + interface WithIntegrationServiceEnvironment { + /** + * Specifies resourceGroup, integrationServiceEnvironmentName. + * @param resourceGroup The resource group name + * @param integrationServiceEnvironmentName The integration service environment name + * @return the next definition stage + */ + WithCreate withExistingIntegrationServiceEnvironment(String resourceGroup, String integrationServiceEnvironmentName); + } + + /** + * The stage of the definition which contains all the minimum required inputs for + * the resource to be created (via {@link WithCreate#create()}), but also allows + * for any other optional settings to be specified. + */ + interface WithCreate extends Creatable { + } + } + /** + * The template for a ManagedApi update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable { + } + + /** + * Grouping of ManagedApi update stages. + */ + interface UpdateStages { + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/MapType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/MapType.java new file mode 100644 index 000000000000..5b6e76de2f74 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/MapType.java @@ -0,0 +1,50 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for MapType. + */ +public final class MapType extends ExpandableStringEnum { + /** Static value NotSpecified for MapType. */ + public static final MapType NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Xslt for MapType. */ + public static final MapType XSLT = fromString("Xslt"); + + /** Static value Xslt20 for MapType. */ + public static final MapType XSLT20 = fromString("Xslt20"); + + /** Static value Xslt30 for MapType. */ + public static final MapType XSLT30 = fromString("Xslt30"); + + /** Static value Liquid for MapType. */ + public static final MapType LIQUID = fromString("Liquid"); + + /** + * Creates or finds a MapType from its string representation. + * @param name a name to look for + * @return the corresponding MapType + */ + @JsonCreator + public static MapType fromString(String name) { + return fromString(name, MapType.class); + } + + /** + * @return known MapType values + */ + public static Collection values() { + return values(MapType.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/MessageFilterType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/MessageFilterType.java new file mode 100644 index 000000000000..64807b92125b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/MessageFilterType.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for MessageFilterType. + */ +public final class MessageFilterType extends ExpandableStringEnum { + /** Static value NotSpecified for MessageFilterType. */ + public static final MessageFilterType NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Include for MessageFilterType. */ + public static final MessageFilterType INCLUDE = fromString("Include"); + + /** Static value Exclude for MessageFilterType. */ + public static final MessageFilterType EXCLUDE = fromString("Exclude"); + + /** + * Creates or finds a MessageFilterType from its string representation. + * @param name a name to look for + * @return the corresponding MessageFilterType + */ + @JsonCreator + public static MessageFilterType fromString(String name) { + return fromString(name, MessageFilterType.class); + } + + /** + * @return known MessageFilterType values + */ + public static Collection values() { + return values(MessageFilterType.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/NetworkConfiguration.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/NetworkConfiguration.java new file mode 100644 index 000000000000..07dec047b46e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/NetworkConfiguration.java @@ -0,0 +1,96 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The network configuration. + */ +public class NetworkConfiguration { + /** + * Gets the virtual network address space. + */ + @JsonProperty(value = "virtualNetworkAddressSpace") + private String virtualNetworkAddressSpace; + + /** + * The access endpoint. + */ + @JsonProperty(value = "accessEndpoint") + private IntegrationServiceEnvironmentAccessEndpoint accessEndpoint; + + /** + * The subnets. + */ + @JsonProperty(value = "subnets") + private List subnets; + + /** + * Get gets the virtual network address space. + * + * @return the virtualNetworkAddressSpace value + */ + public String virtualNetworkAddressSpace() { + return this.virtualNetworkAddressSpace; + } + + /** + * Set gets the virtual network address space. + * + * @param virtualNetworkAddressSpace the virtualNetworkAddressSpace value to set + * @return the NetworkConfiguration object itself. + */ + public NetworkConfiguration withVirtualNetworkAddressSpace(String virtualNetworkAddressSpace) { + this.virtualNetworkAddressSpace = virtualNetworkAddressSpace; + return this; + } + + /** + * Get the access endpoint. + * + * @return the accessEndpoint value + */ + public IntegrationServiceEnvironmentAccessEndpoint accessEndpoint() { + return this.accessEndpoint; + } + + /** + * Set the access endpoint. + * + * @param accessEndpoint the accessEndpoint value to set + * @return the NetworkConfiguration object itself. + */ + public NetworkConfiguration withAccessEndpoint(IntegrationServiceEnvironmentAccessEndpoint accessEndpoint) { + this.accessEndpoint = accessEndpoint; + return this; + } + + /** + * Get the subnets. + * + * @return the subnets value + */ + public List subnets() { + return this.subnets; + } + + /** + * Set the subnets. + * + * @param subnets the subnets value to set + * @return the NetworkConfiguration object itself. + */ + public NetworkConfiguration withSubnets(List subnets) { + this.subnets = subnets; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OpenAuthenticationAccessPolicies.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OpenAuthenticationAccessPolicies.java new file mode 100644 index 000000000000..e0f5acf5c605 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OpenAuthenticationAccessPolicies.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * AuthenticationPolicy of type Open. + */ +public class OpenAuthenticationAccessPolicies { + /** + * Open authentication policies. + */ + @JsonProperty(value = "policies") + private Map policies; + + /** + * Get open authentication policies. + * + * @return the policies value + */ + public Map policies() { + return this.policies; + } + + /** + * Set open authentication policies. + * + * @param policies the policies value to set + * @return the OpenAuthenticationAccessPolicies object itself. + */ + public OpenAuthenticationAccessPolicies withPolicies(Map policies) { + this.policies = policies; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OpenAuthenticationAccessPolicy.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OpenAuthenticationAccessPolicy.java new file mode 100644 index 000000000000..bcdbb3a7a842 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OpenAuthenticationAccessPolicy.java @@ -0,0 +1,59 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Open authentication access policy defined by user. + */ +public class OpenAuthenticationAccessPolicy { + /** + * Type of provider for OAuth. Possible values include: 'AAD'. + */ + @JsonProperty(value = "type", access = JsonProperty.Access.WRITE_ONLY) + private OpenAuthenticationProviderType type; + + /** + * The access policy claims. + */ + @JsonProperty(value = "claims") + private List claims; + + /** + * Get type of provider for OAuth. Possible values include: 'AAD'. + * + * @return the type value + */ + public OpenAuthenticationProviderType type() { + return this.type; + } + + /** + * Get the access policy claims. + * + * @return the claims value + */ + public List claims() { + return this.claims; + } + + /** + * Set the access policy claims. + * + * @param claims the claims value to set + * @return the OpenAuthenticationAccessPolicy object itself. + */ + public OpenAuthenticationAccessPolicy withClaims(List claims) { + this.claims = claims; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OpenAuthenticationPolicyClaim.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OpenAuthenticationPolicyClaim.java new file mode 100644 index 000000000000..b84ffe7c7037 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OpenAuthenticationPolicyClaim.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Open authentication policy claim. + */ +public class OpenAuthenticationPolicyClaim { + /** + * The name of the claim. + */ + @JsonProperty(value = "name") + private String name; + + /** + * The value of the claim. + */ + @JsonProperty(value = "value") + private String value; + + /** + * Get the name of the claim. + * + * @return the name value + */ + public String name() { + return this.name; + } + + /** + * Set the name of the claim. + * + * @param name the name value to set + * @return the OpenAuthenticationPolicyClaim object itself. + */ + public OpenAuthenticationPolicyClaim withName(String name) { + this.name = name; + return this; + } + + /** + * Get the value of the claim. + * + * @return the value value + */ + public String value() { + return this.value; + } + + /** + * Set the value of the claim. + * + * @param value the value value to set + * @return the OpenAuthenticationPolicyClaim object itself. + */ + public OpenAuthenticationPolicyClaim withValue(String value) { + this.value = value; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OpenAuthenticationProviderType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OpenAuthenticationProviderType.java new file mode 100644 index 000000000000..30f4bb25029e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OpenAuthenticationProviderType.java @@ -0,0 +1,38 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for OpenAuthenticationProviderType. + */ +public final class OpenAuthenticationProviderType extends ExpandableStringEnum { + /** Static value AAD for OpenAuthenticationProviderType. */ + public static final OpenAuthenticationProviderType AAD = fromString("AAD"); + + /** + * Creates or finds a OpenAuthenticationProviderType from its string representation. + * @param name a name to look for + * @return the corresponding OpenAuthenticationProviderType + */ + @JsonCreator + public static OpenAuthenticationProviderType fromString(String name) { + return fromString(name, OpenAuthenticationProviderType.class); + } + + /** + * @return known OpenAuthenticationProviderType values + */ + public static Collection values() { + return values(OpenAuthenticationProviderType.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Operation.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Operation.java new file mode 100644 index 000000000000..9ff03bd0faf6 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Operation.java @@ -0,0 +1,40 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.OperationInner; + +/** + * Type representing Operation. + */ +public interface Operation extends HasInner, HasManager { + /** + * @return the display value. + */ + OperationDisplay display(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the origin value. + */ + String origin(); + + /** + * @return the properties value. + */ + Object properties(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OperationDisplay.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OperationDisplay.java new file mode 100644 index 000000000000..87824469e3e1 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OperationDisplay.java @@ -0,0 +1,121 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The object that represents the operation. + */ +public class OperationDisplay { + /** + * Service provider: Microsoft.Logic. + */ + @JsonProperty(value = "provider") + private String provider; + + /** + * Resource on which the operation is performed: Profile, endpoint, etc. + */ + @JsonProperty(value = "resource") + private String resource; + + /** + * Operation type: Read, write, delete, etc. + */ + @JsonProperty(value = "operation") + private String operation; + + /** + * Operation: description. + */ + @JsonProperty(value = "description") + private String description; + + /** + * Get service provider: Microsoft.Logic. + * + * @return the provider value + */ + public String provider() { + return this.provider; + } + + /** + * Set service provider: Microsoft.Logic. + * + * @param provider the provider value to set + * @return the OperationDisplay object itself. + */ + public OperationDisplay withProvider(String provider) { + this.provider = provider; + return this; + } + + /** + * Get resource on which the operation is performed: Profile, endpoint, etc. + * + * @return the resource value + */ + public String resource() { + return this.resource; + } + + /** + * Set resource on which the operation is performed: Profile, endpoint, etc. + * + * @param resource the resource value to set + * @return the OperationDisplay object itself. + */ + public OperationDisplay withResource(String resource) { + this.resource = resource; + return this; + } + + /** + * Get operation type: Read, write, delete, etc. + * + * @return the operation value + */ + public String operation() { + return this.operation; + } + + /** + * Set operation type: Read, write, delete, etc. + * + * @param operation the operation value to set + * @return the OperationDisplay object itself. + */ + public OperationDisplay withOperation(String operation) { + this.operation = operation; + return this; + } + + /** + * Get operation: description. + * + * @return the description value + */ + public String description() { + return this.description; + } + + /** + * Set operation: description. + * + * @param description the description value to set + * @return the OperationDisplay object itself. + */ + public OperationDisplay withDescription(String description) { + this.description = description; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OperationResult.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OperationResult.java new file mode 100644 index 000000000000..0891711c6c1c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OperationResult.java @@ -0,0 +1,160 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The operation result definition. + */ +public class OperationResult extends OperationResultProperties { + /** + * Gets the tracking id. + */ + @JsonProperty(value = "trackingId", access = JsonProperty.Access.WRITE_ONLY) + private String trackingId; + + /** + * Gets the inputs. + */ + @JsonProperty(value = "inputs", access = JsonProperty.Access.WRITE_ONLY) + private Object inputs; + + /** + * Gets the link to inputs. + */ + @JsonProperty(value = "inputsLink", access = JsonProperty.Access.WRITE_ONLY) + private ContentLink inputsLink; + + /** + * Gets the outputs. + */ + @JsonProperty(value = "outputs", access = JsonProperty.Access.WRITE_ONLY) + private Object outputs; + + /** + * Gets the link to outputs. + */ + @JsonProperty(value = "outputsLink", access = JsonProperty.Access.WRITE_ONLY) + private ContentLink outputsLink; + + /** + * Gets the tracked properties. + */ + @JsonProperty(value = "trackedProperties", access = JsonProperty.Access.WRITE_ONLY) + private Object trackedProperties; + + /** + * Gets the retry histories. + */ + @JsonProperty(value = "retryHistory") + private List retryHistory; + + /** + * The iterationCount property. + */ + @JsonProperty(value = "iterationCount") + private Integer iterationCount; + + /** + * Get gets the tracking id. + * + * @return the trackingId value + */ + public String trackingId() { + return this.trackingId; + } + + /** + * Get gets the inputs. + * + * @return the inputs value + */ + public Object inputs() { + return this.inputs; + } + + /** + * Get gets the link to inputs. + * + * @return the inputsLink value + */ + public ContentLink inputsLink() { + return this.inputsLink; + } + + /** + * Get gets the outputs. + * + * @return the outputs value + */ + public Object outputs() { + return this.outputs; + } + + /** + * Get gets the link to outputs. + * + * @return the outputsLink value + */ + public ContentLink outputsLink() { + return this.outputsLink; + } + + /** + * Get gets the tracked properties. + * + * @return the trackedProperties value + */ + public Object trackedProperties() { + return this.trackedProperties; + } + + /** + * Get gets the retry histories. + * + * @return the retryHistory value + */ + public List retryHistory() { + return this.retryHistory; + } + + /** + * Set gets the retry histories. + * + * @param retryHistory the retryHistory value to set + * @return the OperationResult object itself. + */ + public OperationResult withRetryHistory(List retryHistory) { + this.retryHistory = retryHistory; + return this; + } + + /** + * Get the iterationCount value. + * + * @return the iterationCount value + */ + public Integer iterationCount() { + return this.iterationCount; + } + + /** + * Set the iterationCount value. + * + * @param iterationCount the iterationCount value to set + * @return the OperationResult object itself. + */ + public OperationResult withIterationCount(Integer iterationCount) { + this.iterationCount = iterationCount; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OperationResultProperties.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OperationResultProperties.java new file mode 100644 index 000000000000..aa4a91fe3d7b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/OperationResultProperties.java @@ -0,0 +1,177 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import org.joda.time.DateTime; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The run operation result properties. + */ +public class OperationResultProperties { + /** + * The start time of the workflow scope repetition. + */ + @JsonProperty(value = "startTime") + private DateTime startTime; + + /** + * The end time of the workflow scope repetition. + */ + @JsonProperty(value = "endTime") + private DateTime endTime; + + /** + * The correlation properties. + */ + @JsonProperty(value = "correlation") + private RunActionCorrelation correlation; + + /** + * The status of the workflow scope repetition. Possible values include: + * 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', + * 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', + * 'Ignored'. + */ + @JsonProperty(value = "status") + private WorkflowStatus status; + + /** + * The workflow scope repetition code. + */ + @JsonProperty(value = "code") + private String code; + + /** + * The error property. + */ + @JsonProperty(value = "error") + private Object error; + + /** + * Get the start time of the workflow scope repetition. + * + * @return the startTime value + */ + public DateTime startTime() { + return this.startTime; + } + + /** + * Set the start time of the workflow scope repetition. + * + * @param startTime the startTime value to set + * @return the OperationResultProperties object itself. + */ + public OperationResultProperties withStartTime(DateTime startTime) { + this.startTime = startTime; + return this; + } + + /** + * Get the end time of the workflow scope repetition. + * + * @return the endTime value + */ + public DateTime endTime() { + return this.endTime; + } + + /** + * Set the end time of the workflow scope repetition. + * + * @param endTime the endTime value to set + * @return the OperationResultProperties object itself. + */ + public OperationResultProperties withEndTime(DateTime endTime) { + this.endTime = endTime; + return this; + } + + /** + * Get the correlation properties. + * + * @return the correlation value + */ + public RunActionCorrelation correlation() { + return this.correlation; + } + + /** + * Set the correlation properties. + * + * @param correlation the correlation value to set + * @return the OperationResultProperties object itself. + */ + public OperationResultProperties withCorrelation(RunActionCorrelation correlation) { + this.correlation = correlation; + return this; + } + + /** + * Get the status of the workflow scope repetition. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @return the status value + */ + public WorkflowStatus status() { + return this.status; + } + + /** + * Set the status of the workflow scope repetition. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @param status the status value to set + * @return the OperationResultProperties object itself. + */ + public OperationResultProperties withStatus(WorkflowStatus status) { + this.status = status; + return this; + } + + /** + * Get the workflow scope repetition code. + * + * @return the code value + */ + public String code() { + return this.code; + } + + /** + * Set the workflow scope repetition code. + * + * @param code the code value to set + * @return the OperationResultProperties object itself. + */ + public OperationResultProperties withCode(String code) { + this.code = code; + return this; + } + + /** + * Get the error value. + * + * @return the error value + */ + public Object error() { + return this.error; + } + + /** + * Set the error value. + * + * @param error the error value to set + * @return the OperationResultProperties object itself. + */ + public OperationResultProperties withError(Object error) { + this.error = error; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Operations.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Operations.java new file mode 100644 index 000000000000..ee4f457eac02 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Operations.java @@ -0,0 +1,27 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.OperationsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing Operations. + */ +public interface Operations extends HasInner { + /** + * Lists all of the available Logic REST API operations. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ParameterType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ParameterType.java new file mode 100644 index 000000000000..a803c0533d9f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ParameterType.java @@ -0,0 +1,62 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for ParameterType. + */ +public final class ParameterType extends ExpandableStringEnum { + /** Static value NotSpecified for ParameterType. */ + public static final ParameterType NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value String for ParameterType. */ + public static final ParameterType STRING = fromString("String"); + + /** Static value SecureString for ParameterType. */ + public static final ParameterType SECURE_STRING = fromString("SecureString"); + + /** Static value Int for ParameterType. */ + public static final ParameterType INT = fromString("Int"); + + /** Static value Float for ParameterType. */ + public static final ParameterType FLOAT = fromString("Float"); + + /** Static value Bool for ParameterType. */ + public static final ParameterType BOOL = fromString("Bool"); + + /** Static value Array for ParameterType. */ + public static final ParameterType ARRAY = fromString("Array"); + + /** Static value Object for ParameterType. */ + public static final ParameterType OBJECT = fromString("Object"); + + /** Static value SecureObject for ParameterType. */ + public static final ParameterType SECURE_OBJECT = fromString("SecureObject"); + + /** + * Creates or finds a ParameterType from its string representation. + * @param name a name to look for + * @return the corresponding ParameterType + */ + @JsonCreator + public static ParameterType fromString(String name) { + return fromString(name, ParameterType.class); + } + + /** + * @return known ParameterType values + */ + public static Collection values() { + return values(ParameterType.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/PartnerContent.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/PartnerContent.java new file mode 100644 index 000000000000..2f55bd3403eb --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/PartnerContent.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration account partner content. + */ +public class PartnerContent { + /** + * The B2B partner content. + */ + @JsonProperty(value = "b2b") + private B2BPartnerContent b2b; + + /** + * Get the B2B partner content. + * + * @return the b2b value + */ + public B2BPartnerContent b2b() { + return this.b2b; + } + + /** + * Set the B2B partner content. + * + * @param b2b the b2b value to set + * @return the PartnerContent object itself. + */ + public PartnerContent withB2b(B2BPartnerContent b2b) { + this.b2b = b2b; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/PartnerType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/PartnerType.java new file mode 100644 index 000000000000..5de5b936cfc3 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/PartnerType.java @@ -0,0 +1,41 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for PartnerType. + */ +public final class PartnerType extends ExpandableStringEnum { + /** Static value NotSpecified for PartnerType. */ + public static final PartnerType NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value B2B for PartnerType. */ + public static final PartnerType B2B = fromString("B2B"); + + /** + * Creates or finds a PartnerType from its string representation. + * @param name a name to look for + * @return the corresponding PartnerType + */ + @JsonCreator + public static PartnerType fromString(String name) { + return fromString(name, PartnerType.class); + } + + /** + * @return known PartnerType values + */ + public static Collection values() { + return values(PartnerType.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RecurrenceFrequency.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RecurrenceFrequency.java new file mode 100644 index 000000000000..c0da14275d19 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RecurrenceFrequency.java @@ -0,0 +1,59 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for RecurrenceFrequency. + */ +public final class RecurrenceFrequency extends ExpandableStringEnum { + /** Static value NotSpecified for RecurrenceFrequency. */ + public static final RecurrenceFrequency NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Second for RecurrenceFrequency. */ + public static final RecurrenceFrequency SECOND = fromString("Second"); + + /** Static value Minute for RecurrenceFrequency. */ + public static final RecurrenceFrequency MINUTE = fromString("Minute"); + + /** Static value Hour for RecurrenceFrequency. */ + public static final RecurrenceFrequency HOUR = fromString("Hour"); + + /** Static value Day for RecurrenceFrequency. */ + public static final RecurrenceFrequency DAY = fromString("Day"); + + /** Static value Week for RecurrenceFrequency. */ + public static final RecurrenceFrequency WEEK = fromString("Week"); + + /** Static value Month for RecurrenceFrequency. */ + public static final RecurrenceFrequency MONTH = fromString("Month"); + + /** Static value Year for RecurrenceFrequency. */ + public static final RecurrenceFrequency YEAR = fromString("Year"); + + /** + * Creates or finds a RecurrenceFrequency from its string representation. + * @param name a name to look for + * @return the corresponding RecurrenceFrequency + */ + @JsonCreator + public static RecurrenceFrequency fromString(String name) { + return fromString(name, RecurrenceFrequency.class); + } + + /** + * @return known RecurrenceFrequency values + */ + public static Collection values() { + return values(RecurrenceFrequency.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RecurrenceSchedule.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RecurrenceSchedule.java new file mode 100644 index 000000000000..9da56525b4d3 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RecurrenceSchedule.java @@ -0,0 +1,148 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The recurrence schedule. + */ +public class RecurrenceSchedule { + /** + * The minutes. + */ + @JsonProperty(value = "minutes") + private List minutes; + + /** + * The hours. + */ + @JsonProperty(value = "hours") + private List hours; + + /** + * The days of the week. + */ + @JsonProperty(value = "weekDays") + private List weekDays; + + /** + * The month days. + */ + @JsonProperty(value = "monthDays") + private List monthDays; + + /** + * The monthly occurrences. + */ + @JsonProperty(value = "monthlyOccurrences") + private List monthlyOccurrences; + + /** + * Get the minutes. + * + * @return the minutes value + */ + public List minutes() { + return this.minutes; + } + + /** + * Set the minutes. + * + * @param minutes the minutes value to set + * @return the RecurrenceSchedule object itself. + */ + public RecurrenceSchedule withMinutes(List minutes) { + this.minutes = minutes; + return this; + } + + /** + * Get the hours. + * + * @return the hours value + */ + public List hours() { + return this.hours; + } + + /** + * Set the hours. + * + * @param hours the hours value to set + * @return the RecurrenceSchedule object itself. + */ + public RecurrenceSchedule withHours(List hours) { + this.hours = hours; + return this; + } + + /** + * Get the days of the week. + * + * @return the weekDays value + */ + public List weekDays() { + return this.weekDays; + } + + /** + * Set the days of the week. + * + * @param weekDays the weekDays value to set + * @return the RecurrenceSchedule object itself. + */ + public RecurrenceSchedule withWeekDays(List weekDays) { + this.weekDays = weekDays; + return this; + } + + /** + * Get the month days. + * + * @return the monthDays value + */ + public List monthDays() { + return this.monthDays; + } + + /** + * Set the month days. + * + * @param monthDays the monthDays value to set + * @return the RecurrenceSchedule object itself. + */ + public RecurrenceSchedule withMonthDays(List monthDays) { + this.monthDays = monthDays; + return this; + } + + /** + * Get the monthly occurrences. + * + * @return the monthlyOccurrences value + */ + public List monthlyOccurrences() { + return this.monthlyOccurrences; + } + + /** + * Set the monthly occurrences. + * + * @param monthlyOccurrences the monthlyOccurrences value to set + * @return the RecurrenceSchedule object itself. + */ + public RecurrenceSchedule withMonthlyOccurrences(List monthlyOccurrences) { + this.monthlyOccurrences = monthlyOccurrences; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RecurrenceScheduleOccurrence.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RecurrenceScheduleOccurrence.java new file mode 100644 index 000000000000..3b8d2c1a6b24 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RecurrenceScheduleOccurrence.java @@ -0,0 +1,70 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The recurrence schedule occurrence. + */ +public class RecurrenceScheduleOccurrence { + /** + * The day of the week. Possible values include: 'Sunday', 'Monday', + * 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'. + */ + @JsonProperty(value = "day") + private DayOfWeek day; + + /** + * The occurrence. + */ + @JsonProperty(value = "occurrence") + private Integer occurrence; + + /** + * Get the day of the week. Possible values include: 'Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'. + * + * @return the day value + */ + public DayOfWeek day() { + return this.day; + } + + /** + * Set the day of the week. Possible values include: 'Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'. + * + * @param day the day value to set + * @return the RecurrenceScheduleOccurrence object itself. + */ + public RecurrenceScheduleOccurrence withDay(DayOfWeek day) { + this.day = day; + return this; + } + + /** + * Get the occurrence. + * + * @return the occurrence value + */ + public Integer occurrence() { + return this.occurrence; + } + + /** + * Set the occurrence. + * + * @param occurrence the occurrence value to set + * @return the RecurrenceScheduleOccurrence object itself. + */ + public RecurrenceScheduleOccurrence withOccurrence(Integer occurrence) { + this.occurrence = occurrence; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RegenerateActionParameter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RegenerateActionParameter.java new file mode 100644 index 000000000000..4a66d00cb681 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RegenerateActionParameter.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The access key regenerate action content. + */ +public class RegenerateActionParameter { + /** + * The key type. Possible values include: 'NotSpecified', 'Primary', + * 'Secondary'. + */ + @JsonProperty(value = "keyType") + private KeyType keyType; + + /** + * Get the key type. Possible values include: 'NotSpecified', 'Primary', 'Secondary'. + * + * @return the keyType value + */ + public KeyType keyType() { + return this.keyType; + } + + /** + * Set the key type. Possible values include: 'NotSpecified', 'Primary', 'Secondary'. + * + * @param keyType the keyType value to set + * @return the RegenerateActionParameter object itself. + */ + public RegenerateActionParameter withKeyType(KeyType keyType) { + this.keyType = keyType; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RepetitionActionRunWorkflowRequestHistory.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RepetitionActionRunWorkflowRequestHistory.java new file mode 100644 index 000000000000..200f2bbc0486 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RepetitionActionRunWorkflowRequestHistory.java @@ -0,0 +1,53 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.RequestHistoryInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import java.util.Map; + +/** + * Type representing RepetitionActionRunWorkflowRequestHistory. + */ +public interface RepetitionActionRunWorkflowRequestHistory extends HasInner, Indexable, Refreshable, HasManager { + /** + * @return the id value. + */ + String id(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the properties value. + */ + RequestHistoryProperties properties(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the type value. + */ + String type(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RepetitionIndex.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RepetitionIndex.java new file mode 100644 index 000000000000..f518eebf43c1 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RepetitionIndex.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The workflow run action repetition index. + */ +public class RepetitionIndex { + /** + * The scope. + */ + @JsonProperty(value = "scopeName") + private String scopeName; + + /** + * The index. + */ + @JsonProperty(value = "itemIndex", required = true) + private int itemIndex; + + /** + * Get the scope. + * + * @return the scopeName value + */ + public String scopeName() { + return this.scopeName; + } + + /** + * Set the scope. + * + * @param scopeName the scopeName value to set + * @return the RepetitionIndex object itself. + */ + public RepetitionIndex withScopeName(String scopeName) { + this.scopeName = scopeName; + return this; + } + + /** + * Get the index. + * + * @return the itemIndex value + */ + public int itemIndex() { + return this.itemIndex; + } + + /** + * Set the index. + * + * @param itemIndex the itemIndex value to set + * @return the RepetitionIndex object itself. + */ + public RepetitionIndex withItemIndex(int itemIndex) { + this.itemIndex = itemIndex; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Request.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Request.java new file mode 100644 index 000000000000..a6f8e61183f5 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Request.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * A request. + */ +public class Request { + /** + * A list of all the headers attached to the request. + */ + @JsonProperty(value = "headers") + private Object headers; + + /** + * The destination for the request. + */ + @JsonProperty(value = "uri") + private String uri; + + /** + * The HTTP method used for the request. + */ + @JsonProperty(value = "method") + private String method; + + /** + * Get a list of all the headers attached to the request. + * + * @return the headers value + */ + public Object headers() { + return this.headers; + } + + /** + * Set a list of all the headers attached to the request. + * + * @param headers the headers value to set + * @return the Request object itself. + */ + public Request withHeaders(Object headers) { + this.headers = headers; + return this; + } + + /** + * Get the destination for the request. + * + * @return the uri value + */ + public String uri() { + return this.uri; + } + + /** + * Set the destination for the request. + * + * @param uri the uri value to set + * @return the Request object itself. + */ + public Request withUri(String uri) { + this.uri = uri; + return this; + } + + /** + * Get the HTTP method used for the request. + * + * @return the method value + */ + public String method() { + return this.method; + } + + /** + * Set the HTTP method used for the request. + * + * @param method the method value to set + * @return the Request object itself. + */ + public Request withMethod(String method) { + this.method = method; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RequestHistoryProperties.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RequestHistoryProperties.java new file mode 100644 index 000000000000..02e4f89a8277 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RequestHistoryProperties.java @@ -0,0 +1,122 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import org.joda.time.DateTime; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The request history. + */ +public class RequestHistoryProperties { + /** + * The time the request started. + */ + @JsonProperty(value = "startTime") + private DateTime startTime; + + /** + * The time the request ended. + */ + @JsonProperty(value = "endTime") + private DateTime endTime; + + /** + * The request. + */ + @JsonProperty(value = "request") + private Request request; + + /** + * The response. + */ + @JsonProperty(value = "response") + private Response response; + + /** + * Get the time the request started. + * + * @return the startTime value + */ + public DateTime startTime() { + return this.startTime; + } + + /** + * Set the time the request started. + * + * @param startTime the startTime value to set + * @return the RequestHistoryProperties object itself. + */ + public RequestHistoryProperties withStartTime(DateTime startTime) { + this.startTime = startTime; + return this; + } + + /** + * Get the time the request ended. + * + * @return the endTime value + */ + public DateTime endTime() { + return this.endTime; + } + + /** + * Set the time the request ended. + * + * @param endTime the endTime value to set + * @return the RequestHistoryProperties object itself. + */ + public RequestHistoryProperties withEndTime(DateTime endTime) { + this.endTime = endTime; + return this; + } + + /** + * Get the request. + * + * @return the request value + */ + public Request request() { + return this.request; + } + + /** + * Set the request. + * + * @param request the request value to set + * @return the RequestHistoryProperties object itself. + */ + public RequestHistoryProperties withRequest(Request request) { + this.request = request; + return this; + } + + /** + * Get the response. + * + * @return the response value + */ + public Response response() { + return this.response; + } + + /** + * Set the response. + * + * @param response the response value to set + * @return the RequestHistoryProperties object itself. + */ + public RequestHistoryProperties withResponse(Response response) { + this.response = response; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ResourceReference.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ResourceReference.java new file mode 100644 index 000000000000..5bc3b4bc8d08 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/ResourceReference.java @@ -0,0 +1,73 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The resource reference. + */ +public class ResourceReference { + /** + * The resource id. + */ + @JsonProperty(value = "id") + private String id; + + /** + * Gets the resource name. + */ + @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY) + private String name; + + /** + * Gets the resource type. + */ + @JsonProperty(value = "type", access = JsonProperty.Access.WRITE_ONLY) + private String type; + + /** + * Get the resource id. + * + * @return the id value + */ + public String id() { + return this.id; + } + + /** + * Set the resource id. + * + * @param id the id value to set + * @return the ResourceReference object itself. + */ + public ResourceReference withId(String id) { + this.id = id; + return this; + } + + /** + * Get gets the resource name. + * + * @return the name value + */ + public String name() { + return this.name; + } + + /** + * Get gets the resource type. + * + * @return the type value + */ + public String type() { + return this.type; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Response.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Response.java new file mode 100644 index 000000000000..728508a6a962 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Response.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * A response. + */ +public class Response { + /** + * A list of all the headers attached to the response. + */ + @JsonProperty(value = "headers") + private Object headers; + + /** + * The status code of the response. + */ + @JsonProperty(value = "statusCode") + private Integer statusCode; + + /** + * Details on the location of the body content. + */ + @JsonProperty(value = "bodyLink") + private ContentLink bodyLink; + + /** + * Get a list of all the headers attached to the response. + * + * @return the headers value + */ + public Object headers() { + return this.headers; + } + + /** + * Set a list of all the headers attached to the response. + * + * @param headers the headers value to set + * @return the Response object itself. + */ + public Response withHeaders(Object headers) { + this.headers = headers; + return this; + } + + /** + * Get the status code of the response. + * + * @return the statusCode value + */ + public Integer statusCode() { + return this.statusCode; + } + + /** + * Set the status code of the response. + * + * @param statusCode the statusCode value to set + * @return the Response object itself. + */ + public Response withStatusCode(Integer statusCode) { + this.statusCode = statusCode; + return this; + } + + /** + * Get details on the location of the body content. + * + * @return the bodyLink value + */ + public ContentLink bodyLink() { + return this.bodyLink; + } + + /** + * Set details on the location of the body content. + * + * @param bodyLink the bodyLink value to set + * @return the Response object itself. + */ + public Response withBodyLink(ContentLink bodyLink) { + this.bodyLink = bodyLink; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RetryHistory.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RetryHistory.java new file mode 100644 index 000000000000..704e5a31cd9f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RetryHistory.java @@ -0,0 +1,174 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import org.joda.time.DateTime; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The retry history. + */ +public class RetryHistory { + /** + * Gets the start time. + */ + @JsonProperty(value = "startTime") + private DateTime startTime; + + /** + * Gets the end time. + */ + @JsonProperty(value = "endTime") + private DateTime endTime; + + /** + * Gets the status code. + */ + @JsonProperty(value = "code") + private String code; + + /** + * Gets the client request Id. + */ + @JsonProperty(value = "clientRequestId") + private String clientRequestId; + + /** + * Gets the service request Id. + */ + @JsonProperty(value = "serviceRequestId") + private String serviceRequestId; + + /** + * Gets the error response. + */ + @JsonProperty(value = "error") + private ErrorResponse error; + + /** + * Get gets the start time. + * + * @return the startTime value + */ + public DateTime startTime() { + return this.startTime; + } + + /** + * Set gets the start time. + * + * @param startTime the startTime value to set + * @return the RetryHistory object itself. + */ + public RetryHistory withStartTime(DateTime startTime) { + this.startTime = startTime; + return this; + } + + /** + * Get gets the end time. + * + * @return the endTime value + */ + public DateTime endTime() { + return this.endTime; + } + + /** + * Set gets the end time. + * + * @param endTime the endTime value to set + * @return the RetryHistory object itself. + */ + public RetryHistory withEndTime(DateTime endTime) { + this.endTime = endTime; + return this; + } + + /** + * Get gets the status code. + * + * @return the code value + */ + public String code() { + return this.code; + } + + /** + * Set gets the status code. + * + * @param code the code value to set + * @return the RetryHistory object itself. + */ + public RetryHistory withCode(String code) { + this.code = code; + return this; + } + + /** + * Get gets the client request Id. + * + * @return the clientRequestId value + */ + public String clientRequestId() { + return this.clientRequestId; + } + + /** + * Set gets the client request Id. + * + * @param clientRequestId the clientRequestId value to set + * @return the RetryHistory object itself. + */ + public RetryHistory withClientRequestId(String clientRequestId) { + this.clientRequestId = clientRequestId; + return this; + } + + /** + * Get gets the service request Id. + * + * @return the serviceRequestId value + */ + public String serviceRequestId() { + return this.serviceRequestId; + } + + /** + * Set gets the service request Id. + * + * @param serviceRequestId the serviceRequestId value to set + * @return the RetryHistory object itself. + */ + public RetryHistory withServiceRequestId(String serviceRequestId) { + this.serviceRequestId = serviceRequestId; + return this; + } + + /** + * Get gets the error response. + * + * @return the error value + */ + public ErrorResponse error() { + return this.error; + } + + /** + * Set gets the error response. + * + * @param error the error value to set + * @return the RetryHistory object itself. + */ + public RetryHistory withError(ErrorResponse error) { + this.error = error; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RunActionCorrelation.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RunActionCorrelation.java new file mode 100644 index 000000000000..ce8358a6a580 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RunActionCorrelation.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The workflow run action correlation properties. + */ +public class RunActionCorrelation extends RunCorrelation { + /** + * The action tracking identifier. + */ + @JsonProperty(value = "actionTrackingId") + private String actionTrackingId; + + /** + * Get the action tracking identifier. + * + * @return the actionTrackingId value + */ + public String actionTrackingId() { + return this.actionTrackingId; + } + + /** + * Set the action tracking identifier. + * + * @param actionTrackingId the actionTrackingId value to set + * @return the RunActionCorrelation object itself. + */ + public RunActionCorrelation withActionTrackingId(String actionTrackingId) { + this.actionTrackingId = actionTrackingId; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RunCorrelation.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RunCorrelation.java new file mode 100644 index 000000000000..fa4cb5514ab4 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RunCorrelation.java @@ -0,0 +1,70 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The correlation properties. + */ +public class RunCorrelation { + /** + * The client tracking identifier. + */ + @JsonProperty(value = "clientTrackingId") + private String clientTrackingId; + + /** + * The client keywords. + */ + @JsonProperty(value = "clientKeywords") + private List clientKeywords; + + /** + * Get the client tracking identifier. + * + * @return the clientTrackingId value + */ + public String clientTrackingId() { + return this.clientTrackingId; + } + + /** + * Set the client tracking identifier. + * + * @param clientTrackingId the clientTrackingId value to set + * @return the RunCorrelation object itself. + */ + public RunCorrelation withClientTrackingId(String clientTrackingId) { + this.clientTrackingId = clientTrackingId; + return this; + } + + /** + * Get the client keywords. + * + * @return the clientKeywords value + */ + public List clientKeywords() { + return this.clientKeywords; + } + + /** + * Set the client keywords. + * + * @param clientKeywords the clientKeywords value to set + * @return the RunCorrelation object itself. + */ + public RunCorrelation withClientKeywords(List clientKeywords) { + this.clientKeywords = clientKeywords; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RunWorkflowWorkflowRun.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RunWorkflowWorkflowRun.java new file mode 100644 index 000000000000..9a84b7b2d005 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/RunWorkflowWorkflowRun.java @@ -0,0 +1,99 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowRunInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import org.joda.time.DateTime; +import java.util.Map; + +/** + * Type representing RunWorkflowWorkflowRun. + */ +public interface RunWorkflowWorkflowRun extends HasInner, Indexable, Refreshable, HasManager { + /** + * @return the code value. + */ + String code(); + + /** + * @return the correlation value. + */ + Correlation correlation(); + + /** + * @return the correlationId value. + */ + String correlationId(); + + /** + * @return the endTime value. + */ + DateTime endTime(); + + /** + * @return the error value. + */ + Object error(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the outputs value. + */ + Map outputs(); + + /** + * @return the response value. + */ + WorkflowRunTrigger response(); + + /** + * @return the startTime value. + */ + DateTime startTime(); + + /** + * @return the status value. + */ + WorkflowStatus status(); + + /** + * @return the trigger value. + */ + WorkflowRunTrigger trigger(); + + /** + * @return the type value. + */ + String type(); + + /** + * @return the waitEndTime value. + */ + DateTime waitEndTime(); + + /** + * @return the workflow value. + */ + ResourceReference workflow(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SchemaType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SchemaType.java new file mode 100644 index 000000000000..bfb0f641fbb7 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SchemaType.java @@ -0,0 +1,41 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for SchemaType. + */ +public final class SchemaType extends ExpandableStringEnum { + /** Static value NotSpecified for SchemaType. */ + public static final SchemaType NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Xml for SchemaType. */ + public static final SchemaType XML = fromString("Xml"); + + /** + * Creates or finds a SchemaType from its string representation. + * @param name a name to look for + * @return the corresponding SchemaType + */ + @JsonCreator + public static SchemaType fromString(String name) { + return fromString(name, SchemaType.class); + } + + /** + * @return known SchemaType values + */ + public static Collection values() { + return values(SchemaType.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SegmentTerminatorSuffix.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SegmentTerminatorSuffix.java new file mode 100644 index 000000000000..bb7e5d7e6882 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SegmentTerminatorSuffix.java @@ -0,0 +1,62 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +/** + * Defines values for SegmentTerminatorSuffix. + */ +public enum SegmentTerminatorSuffix { + /** Enum value NotSpecified. */ + NOT_SPECIFIED("NotSpecified"), + + /** Enum value None. */ + NONE("None"), + + /** Enum value CR. */ + CR("CR"), + + /** Enum value LF. */ + LF("LF"), + + /** Enum value CRLF. */ + CRLF("CRLF"); + + /** The actual serialized value for a SegmentTerminatorSuffix instance. */ + private String value; + + SegmentTerminatorSuffix(String value) { + this.value = value; + } + + /** + * Parses a serialized value to a SegmentTerminatorSuffix instance. + * + * @param value the serialized value to parse. + * @return the parsed SegmentTerminatorSuffix object, or null if unable to parse. + */ + @JsonCreator + public static SegmentTerminatorSuffix fromString(String value) { + SegmentTerminatorSuffix[] items = SegmentTerminatorSuffix.values(); + for (SegmentTerminatorSuffix item : items) { + if (item.toString().equalsIgnoreCase(value)) { + return item; + } + } + return null; + } + + @JsonValue + @Override + public String toString() { + return this.value; + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SetTriggerStateActionDefinition.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SetTriggerStateActionDefinition.java new file mode 100644 index 000000000000..d252cd88c188 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SetTriggerStateActionDefinition.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The set trigger state action definition. + */ +public class SetTriggerStateActionDefinition { + /** + * The source. + */ + @JsonProperty(value = "source", required = true) + private WorkflowTriggerReference source; + + /** + * Get the source. + * + * @return the source value + */ + public WorkflowTriggerReference source() { + return this.source; + } + + /** + * Set the source. + * + * @param source the source value to set + * @return the SetTriggerStateActionDefinition object itself. + */ + public SetTriggerStateActionDefinition withSource(WorkflowTriggerReference source) { + this.source = source; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SigningAlgorithm.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SigningAlgorithm.java new file mode 100644 index 000000000000..3edf98f6da80 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SigningAlgorithm.java @@ -0,0 +1,53 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for SigningAlgorithm. + */ +public final class SigningAlgorithm extends ExpandableStringEnum { + /** Static value NotSpecified for SigningAlgorithm. */ + public static final SigningAlgorithm NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Default for SigningAlgorithm. */ + public static final SigningAlgorithm DEFAULT = fromString("Default"); + + /** Static value SHA1 for SigningAlgorithm. */ + public static final SigningAlgorithm SHA1 = fromString("SHA1"); + + /** Static value SHA2256 for SigningAlgorithm. */ + public static final SigningAlgorithm SHA2256 = fromString("SHA2256"); + + /** Static value SHA2384 for SigningAlgorithm. */ + public static final SigningAlgorithm SHA2384 = fromString("SHA2384"); + + /** Static value SHA2512 for SigningAlgorithm. */ + public static final SigningAlgorithm SHA2512 = fromString("SHA2512"); + + /** + * Creates or finds a SigningAlgorithm from its string representation. + * @param name a name to look for + * @return the corresponding SigningAlgorithm + */ + @JsonCreator + public static SigningAlgorithm fromString(String name) { + return fromString(name, SigningAlgorithm.class); + } + + /** + * @return known SigningAlgorithm values + */ + public static Collection values() { + return values(SigningAlgorithm.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Sku.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Sku.java new file mode 100644 index 000000000000..038ed169e24c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Sku.java @@ -0,0 +1,70 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The sku type. + */ +public class Sku { + /** + * The name. Possible values include: 'NotSpecified', 'Free', 'Shared', + * 'Basic', 'Standard', 'Premium'. + */ + @JsonProperty(value = "name", required = true) + private SkuName name; + + /** + * The reference to plan. + */ + @JsonProperty(value = "plan") + private ResourceReference plan; + + /** + * Get the name. Possible values include: 'NotSpecified', 'Free', 'Shared', 'Basic', 'Standard', 'Premium'. + * + * @return the name value + */ + public SkuName name() { + return this.name; + } + + /** + * Set the name. Possible values include: 'NotSpecified', 'Free', 'Shared', 'Basic', 'Standard', 'Premium'. + * + * @param name the name value to set + * @return the Sku object itself. + */ + public Sku withName(SkuName name) { + this.name = name; + return this; + } + + /** + * Get the reference to plan. + * + * @return the plan value + */ + public ResourceReference plan() { + return this.plan; + } + + /** + * Set the reference to plan. + * + * @param plan the plan value to set + * @return the Sku object itself. + */ + public Sku withPlan(ResourceReference plan) { + this.plan = plan; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SkuName.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SkuName.java new file mode 100644 index 000000000000..b7c0b26be555 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SkuName.java @@ -0,0 +1,53 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for SkuName. + */ +public final class SkuName extends ExpandableStringEnum { + /** Static value NotSpecified for SkuName. */ + public static final SkuName NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Free for SkuName. */ + public static final SkuName FREE = fromString("Free"); + + /** Static value Shared for SkuName. */ + public static final SkuName SHARED = fromString("Shared"); + + /** Static value Basic for SkuName. */ + public static final SkuName BASIC = fromString("Basic"); + + /** Static value Standard for SkuName. */ + public static final SkuName STANDARD = fromString("Standard"); + + /** Static value Premium for SkuName. */ + public static final SkuName PREMIUM = fromString("Premium"); + + /** + * Creates or finds a SkuName from its string representation. + * @param name a name to look for + * @return the corresponding SkuName + */ + @JsonCreator + public static SkuName fromString(String name) { + return fromString(name, SkuName.class); + } + + /** + * @return known SkuName values + */ + public static Collection values() { + return values(SkuName.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/StatusAnnotation.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/StatusAnnotation.java new file mode 100644 index 000000000000..0589a1733d55 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/StatusAnnotation.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for StatusAnnotation. + */ +public final class StatusAnnotation extends ExpandableStringEnum { + /** Static value NotSpecified for StatusAnnotation. */ + public static final StatusAnnotation NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Preview for StatusAnnotation. */ + public static final StatusAnnotation PREVIEW = fromString("Preview"); + + /** Static value Production for StatusAnnotation. */ + public static final StatusAnnotation PRODUCTION = fromString("Production"); + + /** + * Creates or finds a StatusAnnotation from its string representation. + * @param name a name to look for + * @return the corresponding StatusAnnotation + */ + @JsonCreator + public static StatusAnnotation fromString(String name) { + return fromString(name, StatusAnnotation.class); + } + + /** + * @return known StatusAnnotation values + */ + public static Collection values() { + return values(StatusAnnotation.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicList.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicList.java new file mode 100644 index 000000000000..07615120ba49 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicList.java @@ -0,0 +1,175 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The swagger custom dynamic list. + */ +public class SwaggerCustomDynamicList { + /** + * The operation id to fetch dynamic schema. + */ + @JsonProperty(value = "operationId") + private String operationId; + + /** + * The built in operation. + */ + @JsonProperty(value = "builtInOperation") + private String builtInOperation; + + /** + * The path to a response property (relative to the response object, not + * the response body) which contains an array of dynamic value items. + */ + @JsonProperty(value = "itemsPath") + private String itemsPath; + + /** + * The path to a property which defines the value which should be used. + */ + @JsonProperty(value = "itemValuePath") + private String itemValuePath; + + /** + * The path to an item property which defines the display name of the item. + */ + @JsonProperty(value = "itemTitlePath") + private String itemTitlePath; + + /** + * The parameters. + */ + @JsonProperty(value = "parameters") + private Map parameters; + + /** + * Get the operation id to fetch dynamic schema. + * + * @return the operationId value + */ + public String operationId() { + return this.operationId; + } + + /** + * Set the operation id to fetch dynamic schema. + * + * @param operationId the operationId value to set + * @return the SwaggerCustomDynamicList object itself. + */ + public SwaggerCustomDynamicList withOperationId(String operationId) { + this.operationId = operationId; + return this; + } + + /** + * Get the built in operation. + * + * @return the builtInOperation value + */ + public String builtInOperation() { + return this.builtInOperation; + } + + /** + * Set the built in operation. + * + * @param builtInOperation the builtInOperation value to set + * @return the SwaggerCustomDynamicList object itself. + */ + public SwaggerCustomDynamicList withBuiltInOperation(String builtInOperation) { + this.builtInOperation = builtInOperation; + return this; + } + + /** + * Get the path to a response property (relative to the response object, not the response body) which contains an array of dynamic value items. + * + * @return the itemsPath value + */ + public String itemsPath() { + return this.itemsPath; + } + + /** + * Set the path to a response property (relative to the response object, not the response body) which contains an array of dynamic value items. + * + * @param itemsPath the itemsPath value to set + * @return the SwaggerCustomDynamicList object itself. + */ + public SwaggerCustomDynamicList withItemsPath(String itemsPath) { + this.itemsPath = itemsPath; + return this; + } + + /** + * Get the path to a property which defines the value which should be used. + * + * @return the itemValuePath value + */ + public String itemValuePath() { + return this.itemValuePath; + } + + /** + * Set the path to a property which defines the value which should be used. + * + * @param itemValuePath the itemValuePath value to set + * @return the SwaggerCustomDynamicList object itself. + */ + public SwaggerCustomDynamicList withItemValuePath(String itemValuePath) { + this.itemValuePath = itemValuePath; + return this; + } + + /** + * Get the path to an item property which defines the display name of the item. + * + * @return the itemTitlePath value + */ + public String itemTitlePath() { + return this.itemTitlePath; + } + + /** + * Set the path to an item property which defines the display name of the item. + * + * @param itemTitlePath the itemTitlePath value to set + * @return the SwaggerCustomDynamicList object itself. + */ + public SwaggerCustomDynamicList withItemTitlePath(String itemTitlePath) { + this.itemTitlePath = itemTitlePath; + return this; + } + + /** + * Get the parameters. + * + * @return the parameters value + */ + public Map parameters() { + return this.parameters; + } + + /** + * Set the parameters. + * + * @param parameters the parameters value to set + * @return the SwaggerCustomDynamicList object itself. + */ + public SwaggerCustomDynamicList withParameters(Map parameters) { + this.parameters = parameters; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicProperties.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicProperties.java new file mode 100644 index 000000000000..f481c3f52b5a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicProperties.java @@ -0,0 +1,96 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The swagger custom dynamic properties. + */ +public class SwaggerCustomDynamicProperties { + /** + * The operation id to fetch dynamic schema. + */ + @JsonProperty(value = "operationId") + private String operationId; + + /** + * Json pointer to the dynamic schema on the response body. + */ + @JsonProperty(value = "valuePath") + private String valuePath; + + /** + * The operation parameters. + */ + @JsonProperty(value = "parameters") + private Map parameters; + + /** + * Get the operation id to fetch dynamic schema. + * + * @return the operationId value + */ + public String operationId() { + return this.operationId; + } + + /** + * Set the operation id to fetch dynamic schema. + * + * @param operationId the operationId value to set + * @return the SwaggerCustomDynamicProperties object itself. + */ + public SwaggerCustomDynamicProperties withOperationId(String operationId) { + this.operationId = operationId; + return this; + } + + /** + * Get json pointer to the dynamic schema on the response body. + * + * @return the valuePath value + */ + public String valuePath() { + return this.valuePath; + } + + /** + * Set json pointer to the dynamic schema on the response body. + * + * @param valuePath the valuePath value to set + * @return the SwaggerCustomDynamicProperties object itself. + */ + public SwaggerCustomDynamicProperties withValuePath(String valuePath) { + this.valuePath = valuePath; + return this; + } + + /** + * Get the operation parameters. + * + * @return the parameters value + */ + public Map parameters() { + return this.parameters; + } + + /** + * Set the operation parameters. + * + * @param parameters the parameters value to set + * @return the SwaggerCustomDynamicProperties object itself. + */ + public SwaggerCustomDynamicProperties withParameters(Map parameters) { + this.parameters = parameters; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicSchema.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicSchema.java new file mode 100644 index 000000000000..0e06e876a95d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicSchema.java @@ -0,0 +1,96 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The swagger custom dynamic schema. + */ +public class SwaggerCustomDynamicSchema { + /** + * The operation id to fetch dynamic schema. + */ + @JsonProperty(value = "operationId") + private String operationId; + + /** + * Json pointer to the dynamic schema on the response body. + */ + @JsonProperty(value = "valuePath") + private String valuePath; + + /** + * The operation parameters. + */ + @JsonProperty(value = "parameters") + private Map parameters; + + /** + * Get the operation id to fetch dynamic schema. + * + * @return the operationId value + */ + public String operationId() { + return this.operationId; + } + + /** + * Set the operation id to fetch dynamic schema. + * + * @param operationId the operationId value to set + * @return the SwaggerCustomDynamicSchema object itself. + */ + public SwaggerCustomDynamicSchema withOperationId(String operationId) { + this.operationId = operationId; + return this; + } + + /** + * Get json pointer to the dynamic schema on the response body. + * + * @return the valuePath value + */ + public String valuePath() { + return this.valuePath; + } + + /** + * Set json pointer to the dynamic schema on the response body. + * + * @param valuePath the valuePath value to set + * @return the SwaggerCustomDynamicSchema object itself. + */ + public SwaggerCustomDynamicSchema withValuePath(String valuePath) { + this.valuePath = valuePath; + return this; + } + + /** + * Get the operation parameters. + * + * @return the parameters value + */ + public Map parameters() { + return this.parameters; + } + + /** + * Set the operation parameters. + * + * @param parameters the parameters value to set + * @return the SwaggerCustomDynamicSchema object itself. + */ + public SwaggerCustomDynamicSchema withParameters(Map parameters) { + this.parameters = parameters; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicTree.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicTree.java new file mode 100644 index 000000000000..89ecda0df1bc --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicTree.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The swagger custom dynamic tree. + */ +public class SwaggerCustomDynamicTree { + /** + * The tree settings. + */ + @JsonProperty(value = "settings") + private SwaggerCustomDynamicTreeSettings settings; + + /** + * The tree on-open configuration. + */ + @JsonProperty(value = "open") + private SwaggerCustomDynamicTreeCommand open; + + /** + * The tree on-browse configuration. + */ + @JsonProperty(value = "browse") + private SwaggerCustomDynamicTreeCommand browse; + + /** + * Get the tree settings. + * + * @return the settings value + */ + public SwaggerCustomDynamicTreeSettings settings() { + return this.settings; + } + + /** + * Set the tree settings. + * + * @param settings the settings value to set + * @return the SwaggerCustomDynamicTree object itself. + */ + public SwaggerCustomDynamicTree withSettings(SwaggerCustomDynamicTreeSettings settings) { + this.settings = settings; + return this; + } + + /** + * Get the tree on-open configuration. + * + * @return the open value + */ + public SwaggerCustomDynamicTreeCommand open() { + return this.open; + } + + /** + * Set the tree on-open configuration. + * + * @param open the open value to set + * @return the SwaggerCustomDynamicTree object itself. + */ + public SwaggerCustomDynamicTree withOpen(SwaggerCustomDynamicTreeCommand open) { + this.open = open; + return this; + } + + /** + * Get the tree on-browse configuration. + * + * @return the browse value + */ + public SwaggerCustomDynamicTreeCommand browse() { + return this.browse; + } + + /** + * Set the tree on-browse configuration. + * + * @param browse the browse value to set + * @return the SwaggerCustomDynamicTree object itself. + */ + public SwaggerCustomDynamicTree withBrowse(SwaggerCustomDynamicTreeCommand browse) { + this.browse = browse; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicTreeCommand.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicTreeCommand.java new file mode 100644 index 000000000000..49d268ca7b77 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicTreeCommand.java @@ -0,0 +1,226 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The swagger tree command. + */ +public class SwaggerCustomDynamicTreeCommand { + /** + * The path to an item property which defines the display name of the item. + */ + @JsonProperty(value = "operationId") + private String operationId; + + /** + * The path to an item property which defines the display name of the item. + */ + @JsonProperty(value = "itemsPath") + private String itemsPath; + + /** + * The path to an item property which defines the display name of the item. + */ + @JsonProperty(value = "itemValuePath") + private String itemValuePath; + + /** + * The path to an item property which defines the display name of the item. + */ + @JsonProperty(value = "itemTitlePath") + private String itemTitlePath; + + /** + * The path to an item property which defines the display name of the item. + */ + @JsonProperty(value = "itemFullTitlePath") + private String itemFullTitlePath; + + /** + * The path to an item property which defines the display name of the item. + */ + @JsonProperty(value = "itemIsParent") + private String itemIsParent; + + /** + * The path to an item property which defines the display name of the item. + */ + @JsonProperty(value = "selectableFilter") + private String selectableFilter; + + /** + * The parameters property. + */ + @JsonProperty(value = "parameters") + private Map parameters; + + /** + * Get the path to an item property which defines the display name of the item. + * + * @return the operationId value + */ + public String operationId() { + return this.operationId; + } + + /** + * Set the path to an item property which defines the display name of the item. + * + * @param operationId the operationId value to set + * @return the SwaggerCustomDynamicTreeCommand object itself. + */ + public SwaggerCustomDynamicTreeCommand withOperationId(String operationId) { + this.operationId = operationId; + return this; + } + + /** + * Get the path to an item property which defines the display name of the item. + * + * @return the itemsPath value + */ + public String itemsPath() { + return this.itemsPath; + } + + /** + * Set the path to an item property which defines the display name of the item. + * + * @param itemsPath the itemsPath value to set + * @return the SwaggerCustomDynamicTreeCommand object itself. + */ + public SwaggerCustomDynamicTreeCommand withItemsPath(String itemsPath) { + this.itemsPath = itemsPath; + return this; + } + + /** + * Get the path to an item property which defines the display name of the item. + * + * @return the itemValuePath value + */ + public String itemValuePath() { + return this.itemValuePath; + } + + /** + * Set the path to an item property which defines the display name of the item. + * + * @param itemValuePath the itemValuePath value to set + * @return the SwaggerCustomDynamicTreeCommand object itself. + */ + public SwaggerCustomDynamicTreeCommand withItemValuePath(String itemValuePath) { + this.itemValuePath = itemValuePath; + return this; + } + + /** + * Get the path to an item property which defines the display name of the item. + * + * @return the itemTitlePath value + */ + public String itemTitlePath() { + return this.itemTitlePath; + } + + /** + * Set the path to an item property which defines the display name of the item. + * + * @param itemTitlePath the itemTitlePath value to set + * @return the SwaggerCustomDynamicTreeCommand object itself. + */ + public SwaggerCustomDynamicTreeCommand withItemTitlePath(String itemTitlePath) { + this.itemTitlePath = itemTitlePath; + return this; + } + + /** + * Get the path to an item property which defines the display name of the item. + * + * @return the itemFullTitlePath value + */ + public String itemFullTitlePath() { + return this.itemFullTitlePath; + } + + /** + * Set the path to an item property which defines the display name of the item. + * + * @param itemFullTitlePath the itemFullTitlePath value to set + * @return the SwaggerCustomDynamicTreeCommand object itself. + */ + public SwaggerCustomDynamicTreeCommand withItemFullTitlePath(String itemFullTitlePath) { + this.itemFullTitlePath = itemFullTitlePath; + return this; + } + + /** + * Get the path to an item property which defines the display name of the item. + * + * @return the itemIsParent value + */ + public String itemIsParent() { + return this.itemIsParent; + } + + /** + * Set the path to an item property which defines the display name of the item. + * + * @param itemIsParent the itemIsParent value to set + * @return the SwaggerCustomDynamicTreeCommand object itself. + */ + public SwaggerCustomDynamicTreeCommand withItemIsParent(String itemIsParent) { + this.itemIsParent = itemIsParent; + return this; + } + + /** + * Get the path to an item property which defines the display name of the item. + * + * @return the selectableFilter value + */ + public String selectableFilter() { + return this.selectableFilter; + } + + /** + * Set the path to an item property which defines the display name of the item. + * + * @param selectableFilter the selectableFilter value to set + * @return the SwaggerCustomDynamicTreeCommand object itself. + */ + public SwaggerCustomDynamicTreeCommand withSelectableFilter(String selectableFilter) { + this.selectableFilter = selectableFilter; + return this; + } + + /** + * Get the parameters value. + * + * @return the parameters value + */ + public Map parameters() { + return this.parameters; + } + + /** + * Set the parameters value. + * + * @param parameters the parameters value to set + * @return the SwaggerCustomDynamicTreeCommand object itself. + */ + public SwaggerCustomDynamicTreeCommand withParameters(Map parameters) { + this.parameters = parameters; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicTreeParameter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicTreeParameter.java new file mode 100644 index 000000000000..16c53310641d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicTreeParameter.java @@ -0,0 +1,122 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The swagger custom dynamic tree parameter. + */ +public class SwaggerCustomDynamicTreeParameter { + /** + * Gets or sets a path to a property in the currently selected item to pass + * as a value to a parameter for the given operation. + */ + @JsonProperty(value = "selectedItemValuePath") + private String selectedItemValuePath; + + /** + * The parameter value. + */ + @JsonProperty(value = "value") + private Object value; + + /** + * The parameter reference. + */ + @JsonProperty(value = "parameterReference") + private String parameterReference; + + /** + * Indicates whether the parameter is required. + */ + @JsonProperty(value = "required") + private Boolean required; + + /** + * Get gets or sets a path to a property in the currently selected item to pass as a value to a parameter for the given operation. + * + * @return the selectedItemValuePath value + */ + public String selectedItemValuePath() { + return this.selectedItemValuePath; + } + + /** + * Set gets or sets a path to a property in the currently selected item to pass as a value to a parameter for the given operation. + * + * @param selectedItemValuePath the selectedItemValuePath value to set + * @return the SwaggerCustomDynamicTreeParameter object itself. + */ + public SwaggerCustomDynamicTreeParameter withSelectedItemValuePath(String selectedItemValuePath) { + this.selectedItemValuePath = selectedItemValuePath; + return this; + } + + /** + * Get the parameter value. + * + * @return the value value + */ + public Object value() { + return this.value; + } + + /** + * Set the parameter value. + * + * @param value the value value to set + * @return the SwaggerCustomDynamicTreeParameter object itself. + */ + public SwaggerCustomDynamicTreeParameter withValue(Object value) { + this.value = value; + return this; + } + + /** + * Get the parameter reference. + * + * @return the parameterReference value + */ + public String parameterReference() { + return this.parameterReference; + } + + /** + * Set the parameter reference. + * + * @param parameterReference the parameterReference value to set + * @return the SwaggerCustomDynamicTreeParameter object itself. + */ + public SwaggerCustomDynamicTreeParameter withParameterReference(String parameterReference) { + this.parameterReference = parameterReference; + return this; + } + + /** + * Get indicates whether the parameter is required. + * + * @return the required value + */ + public Boolean required() { + return this.required; + } + + /** + * Set indicates whether the parameter is required. + * + * @param required the required value to set + * @return the SwaggerCustomDynamicTreeParameter object itself. + */ + public SwaggerCustomDynamicTreeParameter withRequired(Boolean required) { + this.required = required; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicTreeSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicTreeSettings.java new file mode 100644 index 000000000000..a6095ca6fb80 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerCustomDynamicTreeSettings.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The swagger custom dynamic tree settings. + */ +public class SwaggerCustomDynamicTreeSettings { + /** + * Indicates whether parent nodes can be selected. + */ + @JsonProperty(value = "CanSelectParentNodes") + private Boolean canSelectParentNodes; + + /** + * Indicates whether leaf nodes can be selected. + */ + @JsonProperty(value = "CanSelectLeafNodes") + private Boolean canSelectLeafNodes; + + /** + * Get indicates whether parent nodes can be selected. + * + * @return the canSelectParentNodes value + */ + public Boolean canSelectParentNodes() { + return this.canSelectParentNodes; + } + + /** + * Set indicates whether parent nodes can be selected. + * + * @param canSelectParentNodes the canSelectParentNodes value to set + * @return the SwaggerCustomDynamicTreeSettings object itself. + */ + public SwaggerCustomDynamicTreeSettings withCanSelectParentNodes(Boolean canSelectParentNodes) { + this.canSelectParentNodes = canSelectParentNodes; + return this; + } + + /** + * Get indicates whether leaf nodes can be selected. + * + * @return the canSelectLeafNodes value + */ + public Boolean canSelectLeafNodes() { + return this.canSelectLeafNodes; + } + + /** + * Set indicates whether leaf nodes can be selected. + * + * @param canSelectLeafNodes the canSelectLeafNodes value to set + * @return the SwaggerCustomDynamicTreeSettings object itself. + */ + public SwaggerCustomDynamicTreeSettings withCanSelectLeafNodes(Boolean canSelectLeafNodes) { + this.canSelectLeafNodes = canSelectLeafNodes; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerExternalDocumentation.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerExternalDocumentation.java new file mode 100644 index 000000000000..bde3706297ac --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerExternalDocumentation.java @@ -0,0 +1,96 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The swagger external documentation. + */ +public class SwaggerExternalDocumentation { + /** + * The document description. + */ + @JsonProperty(value = "description") + private String description; + + /** + * The documentation Uri. + */ + @JsonProperty(value = "uri") + private String uri; + + /** + * The vendor extensions. + */ + @JsonProperty(value = "extensions") + private Map extensions; + + /** + * Get the document description. + * + * @return the description value + */ + public String description() { + return this.description; + } + + /** + * Set the document description. + * + * @param description the description value to set + * @return the SwaggerExternalDocumentation object itself. + */ + public SwaggerExternalDocumentation withDescription(String description) { + this.description = description; + return this; + } + + /** + * Get the documentation Uri. + * + * @return the uri value + */ + public String uri() { + return this.uri; + } + + /** + * Set the documentation Uri. + * + * @param uri the uri value to set + * @return the SwaggerExternalDocumentation object itself. + */ + public SwaggerExternalDocumentation withUri(String uri) { + this.uri = uri; + return this; + } + + /** + * Get the vendor extensions. + * + * @return the extensions value + */ + public Map extensions() { + return this.extensions; + } + + /** + * Set the vendor extensions. + * + * @param extensions the extensions value to set + * @return the SwaggerExternalDocumentation object itself. + */ + public SwaggerExternalDocumentation withExtensions(Map extensions) { + this.extensions = extensions; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerSchema.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerSchema.java new file mode 100644 index 000000000000..99db1446c63e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerSchema.java @@ -0,0 +1,541 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Map; +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The swagger schema. + */ +public class SwaggerSchema { + /** + * The reference. + */ + @JsonProperty(value = "ref") + private String ref; + + /** + * The type. Possible values include: 'String', 'Number', 'Integer', + * 'Boolean', 'Array', 'File', 'Object', 'Null'. + */ + @JsonProperty(value = "type") + private SwaggerSchemaType type; + + /** + * The title. + */ + @JsonProperty(value = "title") + private String title; + + /** + * The items schema. + */ + @JsonProperty(value = "items") + private SwaggerSchema items; + + /** + * The object properties. + */ + @JsonProperty(value = "properties") + private Map properties; + + /** + * The additional properties. + */ + @JsonProperty(value = "additionalProperties") + private Object additionalProperties; + + /** + * The object required properties. + */ + @JsonProperty(value = "required") + private List required; + + /** + * The maximum number of allowed properties. + */ + @JsonProperty(value = "maxProperties") + private Integer maxProperties; + + /** + * The minimum number of allowed properties. + */ + @JsonProperty(value = "minProperties") + private Integer minProperties; + + /** + * The schemas which must pass validation when this schema is used. + */ + @JsonProperty(value = "allOf") + private List allOf; + + /** + * The discriminator. + */ + @JsonProperty(value = "discriminator") + private String discriminator; + + /** + * Indicates whether this property must be present in the a request. + */ + @JsonProperty(value = "readOnly") + private Boolean readOnly; + + /** + * The xml representation format for a property. + */ + @JsonProperty(value = "xml") + private SwaggerXml xml; + + /** + * The external documentation. + */ + @JsonProperty(value = "externalDocs") + private SwaggerExternalDocumentation externalDocs; + + /** + * The example value. + */ + @JsonProperty(value = "example") + private Object example; + + /** + * Indicates the notification url extension. If this is set, the property's + * value should be a callback url for a webhook. + */ + @JsonProperty(value = "notificationUrlExtension") + private Boolean notificationUrlExtension; + + /** + * The dynamic schema configuration. + */ + @JsonProperty(value = "dynamicSchemaOld") + private SwaggerCustomDynamicSchema dynamicSchemaOld; + + /** + * The dynamic schema configuration. + */ + @JsonProperty(value = "dynamicSchemaNew") + private SwaggerCustomDynamicProperties dynamicSchemaNew; + + /** + * The dynamic list. + */ + @JsonProperty(value = "dynamicListNew") + private SwaggerCustomDynamicList dynamicListNew; + + /** + * The dynamic values tree configuration. + */ + @JsonProperty(value = "dynamicTree") + private SwaggerCustomDynamicTree dynamicTree; + + /** + * Get the reference. + * + * @return the ref value + */ + public String ref() { + return this.ref; + } + + /** + * Set the reference. + * + * @param ref the ref value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withRef(String ref) { + this.ref = ref; + return this; + } + + /** + * Get the type. Possible values include: 'String', 'Number', 'Integer', 'Boolean', 'Array', 'File', 'Object', 'Null'. + * + * @return the type value + */ + public SwaggerSchemaType type() { + return this.type; + } + + /** + * Set the type. Possible values include: 'String', 'Number', 'Integer', 'Boolean', 'Array', 'File', 'Object', 'Null'. + * + * @param type the type value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withType(SwaggerSchemaType type) { + this.type = type; + return this; + } + + /** + * Get the title. + * + * @return the title value + */ + public String title() { + return this.title; + } + + /** + * Set the title. + * + * @param title the title value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withTitle(String title) { + this.title = title; + return this; + } + + /** + * Get the items schema. + * + * @return the items value + */ + public SwaggerSchema items() { + return this.items; + } + + /** + * Set the items schema. + * + * @param items the items value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withItems(SwaggerSchema items) { + this.items = items; + return this; + } + + /** + * Get the object properties. + * + * @return the properties value + */ + public Map properties() { + return this.properties; + } + + /** + * Set the object properties. + * + * @param properties the properties value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withProperties(Map properties) { + this.properties = properties; + return this; + } + + /** + * Get the additional properties. + * + * @return the additionalProperties value + */ + public Object additionalProperties() { + return this.additionalProperties; + } + + /** + * Set the additional properties. + * + * @param additionalProperties the additionalProperties value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withAdditionalProperties(Object additionalProperties) { + this.additionalProperties = additionalProperties; + return this; + } + + /** + * Get the object required properties. + * + * @return the required value + */ + public List required() { + return this.required; + } + + /** + * Set the object required properties. + * + * @param required the required value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withRequired(List required) { + this.required = required; + return this; + } + + /** + * Get the maximum number of allowed properties. + * + * @return the maxProperties value + */ + public Integer maxProperties() { + return this.maxProperties; + } + + /** + * Set the maximum number of allowed properties. + * + * @param maxProperties the maxProperties value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withMaxProperties(Integer maxProperties) { + this.maxProperties = maxProperties; + return this; + } + + /** + * Get the minimum number of allowed properties. + * + * @return the minProperties value + */ + public Integer minProperties() { + return this.minProperties; + } + + /** + * Set the minimum number of allowed properties. + * + * @param minProperties the minProperties value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withMinProperties(Integer minProperties) { + this.minProperties = minProperties; + return this; + } + + /** + * Get the schemas which must pass validation when this schema is used. + * + * @return the allOf value + */ + public List allOf() { + return this.allOf; + } + + /** + * Set the schemas which must pass validation when this schema is used. + * + * @param allOf the allOf value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withAllOf(List allOf) { + this.allOf = allOf; + return this; + } + + /** + * Get the discriminator. + * + * @return the discriminator value + */ + public String discriminator() { + return this.discriminator; + } + + /** + * Set the discriminator. + * + * @param discriminator the discriminator value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withDiscriminator(String discriminator) { + this.discriminator = discriminator; + return this; + } + + /** + * Get indicates whether this property must be present in the a request. + * + * @return the readOnly value + */ + public Boolean readOnly() { + return this.readOnly; + } + + /** + * Set indicates whether this property must be present in the a request. + * + * @param readOnly the readOnly value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withReadOnly(Boolean readOnly) { + this.readOnly = readOnly; + return this; + } + + /** + * Get the xml representation format for a property. + * + * @return the xml value + */ + public SwaggerXml xml() { + return this.xml; + } + + /** + * Set the xml representation format for a property. + * + * @param xml the xml value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withXml(SwaggerXml xml) { + this.xml = xml; + return this; + } + + /** + * Get the external documentation. + * + * @return the externalDocs value + */ + public SwaggerExternalDocumentation externalDocs() { + return this.externalDocs; + } + + /** + * Set the external documentation. + * + * @param externalDocs the externalDocs value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withExternalDocs(SwaggerExternalDocumentation externalDocs) { + this.externalDocs = externalDocs; + return this; + } + + /** + * Get the example value. + * + * @return the example value + */ + public Object example() { + return this.example; + } + + /** + * Set the example value. + * + * @param example the example value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withExample(Object example) { + this.example = example; + return this; + } + + /** + * Get indicates the notification url extension. If this is set, the property's value should be a callback url for a webhook. + * + * @return the notificationUrlExtension value + */ + public Boolean notificationUrlExtension() { + return this.notificationUrlExtension; + } + + /** + * Set indicates the notification url extension. If this is set, the property's value should be a callback url for a webhook. + * + * @param notificationUrlExtension the notificationUrlExtension value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withNotificationUrlExtension(Boolean notificationUrlExtension) { + this.notificationUrlExtension = notificationUrlExtension; + return this; + } + + /** + * Get the dynamic schema configuration. + * + * @return the dynamicSchemaOld value + */ + public SwaggerCustomDynamicSchema dynamicSchemaOld() { + return this.dynamicSchemaOld; + } + + /** + * Set the dynamic schema configuration. + * + * @param dynamicSchemaOld the dynamicSchemaOld value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withDynamicSchemaOld(SwaggerCustomDynamicSchema dynamicSchemaOld) { + this.dynamicSchemaOld = dynamicSchemaOld; + return this; + } + + /** + * Get the dynamic schema configuration. + * + * @return the dynamicSchemaNew value + */ + public SwaggerCustomDynamicProperties dynamicSchemaNew() { + return this.dynamicSchemaNew; + } + + /** + * Set the dynamic schema configuration. + * + * @param dynamicSchemaNew the dynamicSchemaNew value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withDynamicSchemaNew(SwaggerCustomDynamicProperties dynamicSchemaNew) { + this.dynamicSchemaNew = dynamicSchemaNew; + return this; + } + + /** + * Get the dynamic list. + * + * @return the dynamicListNew value + */ + public SwaggerCustomDynamicList dynamicListNew() { + return this.dynamicListNew; + } + + /** + * Set the dynamic list. + * + * @param dynamicListNew the dynamicListNew value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withDynamicListNew(SwaggerCustomDynamicList dynamicListNew) { + this.dynamicListNew = dynamicListNew; + return this; + } + + /** + * Get the dynamic values tree configuration. + * + * @return the dynamicTree value + */ + public SwaggerCustomDynamicTree dynamicTree() { + return this.dynamicTree; + } + + /** + * Set the dynamic values tree configuration. + * + * @param dynamicTree the dynamicTree value to set + * @return the SwaggerSchema object itself. + */ + public SwaggerSchema withDynamicTree(SwaggerCustomDynamicTree dynamicTree) { + this.dynamicTree = dynamicTree; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerSchemaType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerSchemaType.java new file mode 100644 index 000000000000..629a0483b00d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerSchemaType.java @@ -0,0 +1,59 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for SwaggerSchemaType. + */ +public final class SwaggerSchemaType extends ExpandableStringEnum { + /** Static value String for SwaggerSchemaType. */ + public static final SwaggerSchemaType STRING = fromString("String"); + + /** Static value Number for SwaggerSchemaType. */ + public static final SwaggerSchemaType NUMBER = fromString("Number"); + + /** Static value Integer for SwaggerSchemaType. */ + public static final SwaggerSchemaType INTEGER = fromString("Integer"); + + /** Static value Boolean for SwaggerSchemaType. */ + public static final SwaggerSchemaType BOOLEAN = fromString("Boolean"); + + /** Static value Array for SwaggerSchemaType. */ + public static final SwaggerSchemaType ARRAY = fromString("Array"); + + /** Static value File for SwaggerSchemaType. */ + public static final SwaggerSchemaType FILE = fromString("File"); + + /** Static value Object for SwaggerSchemaType. */ + public static final SwaggerSchemaType OBJECT = fromString("Object"); + + /** Static value Null for SwaggerSchemaType. */ + public static final SwaggerSchemaType NULL = fromString("Null"); + + /** + * Creates or finds a SwaggerSchemaType from its string representation. + * @param name a name to look for + * @return the corresponding SwaggerSchemaType + */ + @JsonCreator + public static SwaggerSchemaType fromString(String name) { + return fromString(name, SwaggerSchemaType.class); + } + + /** + * @return known SwaggerSchemaType values + */ + public static Collection values() { + return values(SwaggerSchemaType.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerXml.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerXml.java new file mode 100644 index 000000000000..0d0059b6a190 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/SwaggerXml.java @@ -0,0 +1,175 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Map; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Swagger XML. + */ +public class SwaggerXml { + /** + * The xml element or attribute name. + */ + @JsonProperty(value = "name") + private String name; + + /** + * The xml namespace. + */ + @JsonProperty(value = "namespace") + private String namespace; + + /** + * The name prefix. + */ + @JsonProperty(value = "prefix") + private String prefix; + + /** + * Indicates whether the property should be an attribute instead of an + * element. + */ + @JsonProperty(value = "attribute") + private Boolean attribute; + + /** + * Indicates whether the array elements are wrapped in a container element. + */ + @JsonProperty(value = "wrapped") + private Boolean wrapped; + + /** + * The vendor extensions. + */ + @JsonProperty(value = "extensions") + private Map extensions; + + /** + * Get the xml element or attribute name. + * + * @return the name value + */ + public String name() { + return this.name; + } + + /** + * Set the xml element or attribute name. + * + * @param name the name value to set + * @return the SwaggerXml object itself. + */ + public SwaggerXml withName(String name) { + this.name = name; + return this; + } + + /** + * Get the xml namespace. + * + * @return the namespace value + */ + public String namespace() { + return this.namespace; + } + + /** + * Set the xml namespace. + * + * @param namespace the namespace value to set + * @return the SwaggerXml object itself. + */ + public SwaggerXml withNamespace(String namespace) { + this.namespace = namespace; + return this; + } + + /** + * Get the name prefix. + * + * @return the prefix value + */ + public String prefix() { + return this.prefix; + } + + /** + * Set the name prefix. + * + * @param prefix the prefix value to set + * @return the SwaggerXml object itself. + */ + public SwaggerXml withPrefix(String prefix) { + this.prefix = prefix; + return this; + } + + /** + * Get indicates whether the property should be an attribute instead of an element. + * + * @return the attribute value + */ + public Boolean attribute() { + return this.attribute; + } + + /** + * Set indicates whether the property should be an attribute instead of an element. + * + * @param attribute the attribute value to set + * @return the SwaggerXml object itself. + */ + public SwaggerXml withAttribute(Boolean attribute) { + this.attribute = attribute; + return this; + } + + /** + * Get indicates whether the array elements are wrapped in a container element. + * + * @return the wrapped value + */ + public Boolean wrapped() { + return this.wrapped; + } + + /** + * Set indicates whether the array elements are wrapped in a container element. + * + * @param wrapped the wrapped value to set + * @return the SwaggerXml object itself. + */ + public SwaggerXml withWrapped(Boolean wrapped) { + this.wrapped = wrapped; + return this; + } + + /** + * Get the vendor extensions. + * + * @return the extensions value + */ + public Map extensions() { + return this.extensions; + } + + /** + * Set the vendor extensions. + * + * @param extensions the extensions value to set + * @return the SwaggerXml object itself. + */ + public SwaggerXml withExtensions(Map extensions) { + this.extensions = extensions; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackEventsOperationOptions.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackEventsOperationOptions.java new file mode 100644 index 000000000000..b2d1c9d6cc66 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackEventsOperationOptions.java @@ -0,0 +1,41 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for TrackEventsOperationOptions. + */ +public final class TrackEventsOperationOptions extends ExpandableStringEnum { + /** Static value None for TrackEventsOperationOptions. */ + public static final TrackEventsOperationOptions NONE = fromString("None"); + + /** Static value DisableSourceInfoEnrich for TrackEventsOperationOptions. */ + public static final TrackEventsOperationOptions DISABLE_SOURCE_INFO_ENRICH = fromString("DisableSourceInfoEnrich"); + + /** + * Creates or finds a TrackEventsOperationOptions from its string representation. + * @param name a name to look for + * @return the corresponding TrackEventsOperationOptions + */ + @JsonCreator + public static TrackEventsOperationOptions fromString(String name) { + return fromString(name, TrackEventsOperationOptions.class); + } + + /** + * @return known TrackEventsOperationOptions values + */ + public static Collection values() { + return values(TrackEventsOperationOptions.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackingEvent.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackingEvent.java new file mode 100644 index 000000000000..d4afa837aebc --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackingEvent.java @@ -0,0 +1,156 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import org.joda.time.DateTime; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The tracking event. + */ +public class TrackingEvent { + /** + * The event level. Possible values include: 'LogAlways', 'Critical', + * 'Error', 'Warning', 'Informational', 'Verbose'. + */ + @JsonProperty(value = "eventLevel", required = true) + private EventLevel eventLevel; + + /** + * The event time. + */ + @JsonProperty(value = "eventTime", required = true) + private DateTime eventTime; + + /** + * The record type. Possible values include: 'NotSpecified', 'Custom', + * 'AS2Message', 'AS2MDN', 'X12Interchange', 'X12FunctionalGroup', + * 'X12TransactionSet', 'X12InterchangeAcknowledgment', + * 'X12FunctionalGroupAcknowledgment', 'X12TransactionSetAcknowledgment', + * 'EdifactInterchange', 'EdifactFunctionalGroup', 'EdifactTransactionSet', + * 'EdifactInterchangeAcknowledgment', + * 'EdifactFunctionalGroupAcknowledgment', + * 'EdifactTransactionSetAcknowledgment'. + */ + @JsonProperty(value = "recordType", required = true) + private TrackingRecordType recordType; + + /** + * The record. + */ + @JsonProperty(value = "record") + private Object record; + + /** + * The error. + */ + @JsonProperty(value = "error") + private TrackingEventErrorInfo error; + + /** + * Get the event level. Possible values include: 'LogAlways', 'Critical', 'Error', 'Warning', 'Informational', 'Verbose'. + * + * @return the eventLevel value + */ + public EventLevel eventLevel() { + return this.eventLevel; + } + + /** + * Set the event level. Possible values include: 'LogAlways', 'Critical', 'Error', 'Warning', 'Informational', 'Verbose'. + * + * @param eventLevel the eventLevel value to set + * @return the TrackingEvent object itself. + */ + public TrackingEvent withEventLevel(EventLevel eventLevel) { + this.eventLevel = eventLevel; + return this; + } + + /** + * Get the event time. + * + * @return the eventTime value + */ + public DateTime eventTime() { + return this.eventTime; + } + + /** + * Set the event time. + * + * @param eventTime the eventTime value to set + * @return the TrackingEvent object itself. + */ + public TrackingEvent withEventTime(DateTime eventTime) { + this.eventTime = eventTime; + return this; + } + + /** + * Get the record type. Possible values include: 'NotSpecified', 'Custom', 'AS2Message', 'AS2MDN', 'X12Interchange', 'X12FunctionalGroup', 'X12TransactionSet', 'X12InterchangeAcknowledgment', 'X12FunctionalGroupAcknowledgment', 'X12TransactionSetAcknowledgment', 'EdifactInterchange', 'EdifactFunctionalGroup', 'EdifactTransactionSet', 'EdifactInterchangeAcknowledgment', 'EdifactFunctionalGroupAcknowledgment', 'EdifactTransactionSetAcknowledgment'. + * + * @return the recordType value + */ + public TrackingRecordType recordType() { + return this.recordType; + } + + /** + * Set the record type. Possible values include: 'NotSpecified', 'Custom', 'AS2Message', 'AS2MDN', 'X12Interchange', 'X12FunctionalGroup', 'X12TransactionSet', 'X12InterchangeAcknowledgment', 'X12FunctionalGroupAcknowledgment', 'X12TransactionSetAcknowledgment', 'EdifactInterchange', 'EdifactFunctionalGroup', 'EdifactTransactionSet', 'EdifactInterchangeAcknowledgment', 'EdifactFunctionalGroupAcknowledgment', 'EdifactTransactionSetAcknowledgment'. + * + * @param recordType the recordType value to set + * @return the TrackingEvent object itself. + */ + public TrackingEvent withRecordType(TrackingRecordType recordType) { + this.recordType = recordType; + return this; + } + + /** + * Get the record. + * + * @return the record value + */ + public Object record() { + return this.record; + } + + /** + * Set the record. + * + * @param record the record value to set + * @return the TrackingEvent object itself. + */ + public TrackingEvent withRecord(Object record) { + this.record = record; + return this; + } + + /** + * Get the error. + * + * @return the error value + */ + public TrackingEventErrorInfo error() { + return this.error; + } + + /** + * Set the error. + * + * @param error the error value to set + * @return the TrackingEvent object itself. + */ + public TrackingEvent withError(TrackingEventErrorInfo error) { + this.error = error; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackingEventErrorInfo.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackingEventErrorInfo.java new file mode 100644 index 000000000000..638a667e9b72 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackingEventErrorInfo.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The tracking event error info. + */ +public class TrackingEventErrorInfo { + /** + * The message. + */ + @JsonProperty(value = "message") + private String message; + + /** + * The code. + */ + @JsonProperty(value = "code") + private String code; + + /** + * Get the message. + * + * @return the message value + */ + public String message() { + return this.message; + } + + /** + * Set the message. + * + * @param message the message value to set + * @return the TrackingEventErrorInfo object itself. + */ + public TrackingEventErrorInfo withMessage(String message) { + this.message = message; + return this; + } + + /** + * Get the code. + * + * @return the code value + */ + public String code() { + return this.code; + } + + /** + * Set the code. + * + * @param code the code value to set + * @return the TrackingEventErrorInfo object itself. + */ + public TrackingEventErrorInfo withCode(String code) { + this.code = code; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackingEventsDefinition.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackingEventsDefinition.java new file mode 100644 index 000000000000..a9f89309fb89 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackingEventsDefinition.java @@ -0,0 +1,97 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The tracking events definition. + */ +public class TrackingEventsDefinition { + /** + * The source type. + */ + @JsonProperty(value = "sourceType", required = true) + private String sourceType; + + /** + * The track events options. Possible values include: 'None', + * 'DisableSourceInfoEnrich'. + */ + @JsonProperty(value = "trackEventsOptions") + private TrackEventsOperationOptions trackEventsOptions; + + /** + * The events. + */ + @JsonProperty(value = "events", required = true) + private List events; + + /** + * Get the source type. + * + * @return the sourceType value + */ + public String sourceType() { + return this.sourceType; + } + + /** + * Set the source type. + * + * @param sourceType the sourceType value to set + * @return the TrackingEventsDefinition object itself. + */ + public TrackingEventsDefinition withSourceType(String sourceType) { + this.sourceType = sourceType; + return this; + } + + /** + * Get the track events options. Possible values include: 'None', 'DisableSourceInfoEnrich'. + * + * @return the trackEventsOptions value + */ + public TrackEventsOperationOptions trackEventsOptions() { + return this.trackEventsOptions; + } + + /** + * Set the track events options. Possible values include: 'None', 'DisableSourceInfoEnrich'. + * + * @param trackEventsOptions the trackEventsOptions value to set + * @return the TrackingEventsDefinition object itself. + */ + public TrackingEventsDefinition withTrackEventsOptions(TrackEventsOperationOptions trackEventsOptions) { + this.trackEventsOptions = trackEventsOptions; + return this; + } + + /** + * Get the events. + * + * @return the events value + */ + public List events() { + return this.events; + } + + /** + * Set the events. + * + * @param events the events value to set + * @return the TrackingEventsDefinition object itself. + */ + public TrackingEventsDefinition withEvents(List events) { + this.events = events; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackingRecordType.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackingRecordType.java new file mode 100644 index 000000000000..ffeb001d1186 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrackingRecordType.java @@ -0,0 +1,83 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for TrackingRecordType. + */ +public final class TrackingRecordType extends ExpandableStringEnum { + /** Static value NotSpecified for TrackingRecordType. */ + public static final TrackingRecordType NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Custom for TrackingRecordType. */ + public static final TrackingRecordType CUSTOM = fromString("Custom"); + + /** Static value AS2Message for TrackingRecordType. */ + public static final TrackingRecordType AS2MESSAGE = fromString("AS2Message"); + + /** Static value AS2MDN for TrackingRecordType. */ + public static final TrackingRecordType AS2MDN = fromString("AS2MDN"); + + /** Static value X12Interchange for TrackingRecordType. */ + public static final TrackingRecordType X12INTERCHANGE = fromString("X12Interchange"); + + /** Static value X12FunctionalGroup for TrackingRecordType. */ + public static final TrackingRecordType X12FUNCTIONAL_GROUP = fromString("X12FunctionalGroup"); + + /** Static value X12TransactionSet for TrackingRecordType. */ + public static final TrackingRecordType X12TRANSACTION_SET = fromString("X12TransactionSet"); + + /** Static value X12InterchangeAcknowledgment for TrackingRecordType. */ + public static final TrackingRecordType X12INTERCHANGE_ACKNOWLEDGMENT = fromString("X12InterchangeAcknowledgment"); + + /** Static value X12FunctionalGroupAcknowledgment for TrackingRecordType. */ + public static final TrackingRecordType X12FUNCTIONAL_GROUP_ACKNOWLEDGMENT = fromString("X12FunctionalGroupAcknowledgment"); + + /** Static value X12TransactionSetAcknowledgment for TrackingRecordType. */ + public static final TrackingRecordType X12TRANSACTION_SET_ACKNOWLEDGMENT = fromString("X12TransactionSetAcknowledgment"); + + /** Static value EdifactInterchange for TrackingRecordType. */ + public static final TrackingRecordType EDIFACT_INTERCHANGE = fromString("EdifactInterchange"); + + /** Static value EdifactFunctionalGroup for TrackingRecordType. */ + public static final TrackingRecordType EDIFACT_FUNCTIONAL_GROUP = fromString("EdifactFunctionalGroup"); + + /** Static value EdifactTransactionSet for TrackingRecordType. */ + public static final TrackingRecordType EDIFACT_TRANSACTION_SET = fromString("EdifactTransactionSet"); + + /** Static value EdifactInterchangeAcknowledgment for TrackingRecordType. */ + public static final TrackingRecordType EDIFACT_INTERCHANGE_ACKNOWLEDGMENT = fromString("EdifactInterchangeAcknowledgment"); + + /** Static value EdifactFunctionalGroupAcknowledgment for TrackingRecordType. */ + public static final TrackingRecordType EDIFACT_FUNCTIONAL_GROUP_ACKNOWLEDGMENT = fromString("EdifactFunctionalGroupAcknowledgment"); + + /** Static value EdifactTransactionSetAcknowledgment for TrackingRecordType. */ + public static final TrackingRecordType EDIFACT_TRANSACTION_SET_ACKNOWLEDGMENT = fromString("EdifactTransactionSetAcknowledgment"); + + /** + * Creates or finds a TrackingRecordType from its string representation. + * @param name a name to look for + * @return the corresponding TrackingRecordType + */ + @JsonCreator + public static TrackingRecordType fromString(String name) { + return fromString(name, TrackingRecordType.class); + } + + /** + * @return known TrackingRecordType values + */ + public static Collection values() { + return values(TrackingRecordType.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrailingSeparatorPolicy.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrailingSeparatorPolicy.java new file mode 100644 index 000000000000..0a59ce5149a3 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/TrailingSeparatorPolicy.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for TrailingSeparatorPolicy. + */ +public final class TrailingSeparatorPolicy extends ExpandableStringEnum { + /** Static value NotSpecified for TrailingSeparatorPolicy. */ + public static final TrailingSeparatorPolicy NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value NotAllowed for TrailingSeparatorPolicy. */ + public static final TrailingSeparatorPolicy NOT_ALLOWED = fromString("NotAllowed"); + + /** Static value Optional for TrailingSeparatorPolicy. */ + public static final TrailingSeparatorPolicy OPTIONAL = fromString("Optional"); + + /** Static value Mandatory for TrailingSeparatorPolicy. */ + public static final TrailingSeparatorPolicy MANDATORY = fromString("Mandatory"); + + /** + * Creates or finds a TrailingSeparatorPolicy from its string representation. + * @param name a name to look for + * @return the corresponding TrailingSeparatorPolicy + */ + @JsonCreator + public static TrailingSeparatorPolicy fromString(String name) { + return fromString(name, TrailingSeparatorPolicy.class); + } + + /** + * @return known TrailingSeparatorPolicy values + */ + public static Collection values() { + return values(TrailingSeparatorPolicy.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/UsageIndicator.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/UsageIndicator.java new file mode 100644 index 000000000000..b1dff4e19ea6 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/UsageIndicator.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for UsageIndicator. + */ +public final class UsageIndicator extends ExpandableStringEnum { + /** Static value NotSpecified for UsageIndicator. */ + public static final UsageIndicator NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Test for UsageIndicator. */ + public static final UsageIndicator TEST = fromString("Test"); + + /** Static value Information for UsageIndicator. */ + public static final UsageIndicator INFORMATION = fromString("Information"); + + /** Static value Production for UsageIndicator. */ + public static final UsageIndicator PRODUCTION = fromString("Production"); + + /** + * Creates or finds a UsageIndicator from its string representation. + * @param name a name to look for + * @return the corresponding UsageIndicator + */ + @JsonCreator + public static UsageIndicator fromString(String name) { + return fromString(name, UsageIndicator.class); + } + + /** + * @return known UsageIndicator values + */ + public static Collection values() { + return values(UsageIndicator.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Workflow.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Workflow.java new file mode 100644 index 000000000000..7756bf908906 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Workflow.java @@ -0,0 +1,219 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.Resource; +import com.microsoft.azure.arm.resources.models.GroupableResourceCore; +import com.microsoft.azure.arm.resources.models.HasResourceGroup; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.model.Updatable; +import com.microsoft.azure.arm.model.Appliable; +import com.microsoft.azure.arm.model.Creatable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import org.joda.time.DateTime; +import java.util.Map; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowInner; + +/** + * Type representing Workflow. + */ +public interface Workflow extends HasInner, Resource, GroupableResourceCore, HasResourceGroup, Refreshable, Updatable, HasManager { + /** + * @return the accessControl value. + */ + FlowAccessControlConfiguration accessControl(); + + /** + * @return the accessEndpoint value. + */ + String accessEndpoint(); + + /** + * @return the changedTime value. + */ + DateTime changedTime(); + + /** + * @return the createdTime value. + */ + DateTime createdTime(); + + /** + * @return the definition value. + */ + Object definition(); + + /** + * @return the endpointsConfiguration value. + */ + FlowEndpointsConfiguration endpointsConfiguration(); + + /** + * @return the integrationAccount value. + */ + ResourceReference integrationAccount(); + + /** + * @return the integrationServiceEnvironment value. + */ + ResourceReference integrationServiceEnvironment(); + + /** + * @return the parameters value. + */ + Map parameters(); + + /** + * @return the provisioningState value. + */ + WorkflowProvisioningState provisioningState(); + + /** + * @return the sku value. + */ + Sku sku(); + + /** + * @return the state value. + */ + WorkflowState state(); + + /** + * @return the version value. + */ + String version(); + + /** + * The entirety of the Workflow definition. + */ + interface Definition extends DefinitionStages.Blank, DefinitionStages.WithGroup, DefinitionStages.WithCreate { + } + + /** + * Grouping of Workflow definition stages. + */ + interface DefinitionStages { + /** + * The first stage of a Workflow definition. + */ + interface Blank extends GroupableResourceCore.DefinitionWithRegion { + } + + /** + * The stage of the Workflow definition allowing to specify the resource group. + */ + interface WithGroup extends GroupableResourceCore.DefinitionStages.WithGroup { + } + + /** + * The stage of the workflow definition allowing to specify AccessControl. + */ + interface WithAccessControl { + /** + * Specifies accessControl. + * @param accessControl The access control configuration + * @return the next definition stage + */ + WithCreate withAccessControl(FlowAccessControlConfiguration accessControl); + } + + /** + * The stage of the workflow definition allowing to specify Definition. + */ + interface WithDefinition { + /** + * Specifies definition. + * @param definition The definition + * @return the next definition stage + */ + WithCreate withDefinition(Object definition); + } + + /** + * The stage of the workflow definition allowing to specify EndpointsConfiguration. + */ + interface WithEndpointsConfiguration { + /** + * Specifies endpointsConfiguration. + * @param endpointsConfiguration The endpoints configuration + * @return the next definition stage + */ + WithCreate withEndpointsConfiguration(FlowEndpointsConfiguration endpointsConfiguration); + } + + /** + * The stage of the workflow definition allowing to specify IntegrationAccount. + */ + interface WithIntegrationAccount { + /** + * Specifies integrationAccount. + * @param integrationAccount The integration account + * @return the next definition stage + */ + WithCreate withIntegrationAccount(ResourceReference integrationAccount); + } + + /** + * The stage of the workflow definition allowing to specify IntegrationServiceEnvironment. + */ + interface WithIntegrationServiceEnvironment { + /** + * Specifies integrationServiceEnvironment. + * @param integrationServiceEnvironment The integration service environment + * @return the next definition stage + */ + WithCreate withIntegrationServiceEnvironment(ResourceReference integrationServiceEnvironment); + } + + /** + * The stage of the workflow definition allowing to specify Parameters. + */ + interface WithParameters { + /** + * Specifies parameters. + * @param parameters The parameters + * @return the next definition stage + */ + WithCreate withParameters(Map parameters); + } + + /** + * The stage of the workflow definition allowing to specify State. + */ + interface WithState { + /** + * Specifies state. + * @param state The state. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended' + * @return the next definition stage + */ + WithCreate withState(WorkflowState state); + } + + /** + * The stage of the definition which contains all the minimum required inputs for + * the resource to be created (via {@link WithCreate#create()}), but also allows + * for any other optional settings to be specified. + */ + interface WithCreate extends Creatable, Resource.DefinitionWithTags, DefinitionStages.WithAccessControl, DefinitionStages.WithDefinition, DefinitionStages.WithEndpointsConfiguration, DefinitionStages.WithIntegrationAccount, DefinitionStages.WithIntegrationServiceEnvironment, DefinitionStages.WithParameters, DefinitionStages.WithState { + } + } + /** + * The template for a Workflow update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable, Resource.UpdateWithTags { + } + + /** + * Grouping of Workflow update stages. + */ + interface UpdateStages { + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowFilter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowFilter.java new file mode 100644 index 000000000000..c2a0a35832f4 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowFilter.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The workflow filter. + */ +public class WorkflowFilter { + /** + * The state of workflows. Possible values include: 'NotSpecified', + * 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + */ + @JsonProperty(value = "state") + private WorkflowState state; + + /** + * Get the state of workflows. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + * + * @return the state value + */ + public WorkflowState state() { + return this.state; + } + + /** + * Set the state of workflows. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + * + * @param state the state value to set + * @return the WorkflowFilter object itself. + */ + public WorkflowFilter withState(WorkflowState state) { + this.state = state; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowOutputParameter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowOutputParameter.java new file mode 100644 index 000000000000..3cfa9ed5a969 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowOutputParameter.java @@ -0,0 +1,32 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The workflow output parameter. + */ +public class WorkflowOutputParameter extends WorkflowParameter { + /** + * Gets the error. + */ + @JsonProperty(value = "error", access = JsonProperty.Access.WRITE_ONLY) + private Object error; + + /** + * Get gets the error. + * + * @return the error value + */ + public Object error() { + return this.error; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowParameter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowParameter.java new file mode 100644 index 000000000000..3f56f8df10e2 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowParameter.java @@ -0,0 +1,123 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The workflow parameters. + */ +public class WorkflowParameter { + /** + * The type. Possible values include: 'NotSpecified', 'String', + * 'SecureString', 'Int', 'Float', 'Bool', 'Array', 'Object', + * 'SecureObject'. + */ + @JsonProperty(value = "type") + private ParameterType type; + + /** + * The value. + */ + @JsonProperty(value = "value") + private Object value; + + /** + * The metadata. + */ + @JsonProperty(value = "metadata") + private Object metadata; + + /** + * The description. + */ + @JsonProperty(value = "description") + private String description; + + /** + * Get the type. Possible values include: 'NotSpecified', 'String', 'SecureString', 'Int', 'Float', 'Bool', 'Array', 'Object', 'SecureObject'. + * + * @return the type value + */ + public ParameterType type() { + return this.type; + } + + /** + * Set the type. Possible values include: 'NotSpecified', 'String', 'SecureString', 'Int', 'Float', 'Bool', 'Array', 'Object', 'SecureObject'. + * + * @param type the type value to set + * @return the WorkflowParameter object itself. + */ + public WorkflowParameter withType(ParameterType type) { + this.type = type; + return this; + } + + /** + * Get the value. + * + * @return the value value + */ + public Object value() { + return this.value; + } + + /** + * Set the value. + * + * @param value the value value to set + * @return the WorkflowParameter object itself. + */ + public WorkflowParameter withValue(Object value) { + this.value = value; + return this; + } + + /** + * Get the metadata. + * + * @return the metadata value + */ + public Object metadata() { + return this.metadata; + } + + /** + * Set the metadata. + * + * @param metadata the metadata value to set + * @return the WorkflowParameter object itself. + */ + public WorkflowParameter withMetadata(Object metadata) { + this.metadata = metadata; + return this; + } + + /** + * Get the description. + * + * @return the description value + */ + public String description() { + return this.description; + } + + /** + * Set the description. + * + * @param description the description value to set + * @return the WorkflowParameter object itself. + */ + public WorkflowParameter withDescription(String description) { + this.description = description; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowProvisioningState.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowProvisioningState.java new file mode 100644 index 000000000000..09a6b4ccad43 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowProvisioningState.java @@ -0,0 +1,101 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for WorkflowProvisioningState. + */ +public final class WorkflowProvisioningState extends ExpandableStringEnum { + /** Static value NotSpecified for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Accepted for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState ACCEPTED = fromString("Accepted"); + + /** Static value Running for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState RUNNING = fromString("Running"); + + /** Static value Ready for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState READY = fromString("Ready"); + + /** Static value Creating for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState CREATING = fromString("Creating"); + + /** Static value Created for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState CREATED = fromString("Created"); + + /** Static value Deleting for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState DELETING = fromString("Deleting"); + + /** Static value Deleted for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState DELETED = fromString("Deleted"); + + /** Static value Canceled for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState CANCELED = fromString("Canceled"); + + /** Static value Failed for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState FAILED = fromString("Failed"); + + /** Static value Succeeded for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState SUCCEEDED = fromString("Succeeded"); + + /** Static value Moving for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState MOVING = fromString("Moving"); + + /** Static value Updating for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState UPDATING = fromString("Updating"); + + /** Static value Registering for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState REGISTERING = fromString("Registering"); + + /** Static value Registered for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState REGISTERED = fromString("Registered"); + + /** Static value Unregistering for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState UNREGISTERING = fromString("Unregistering"); + + /** Static value Unregistered for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState UNREGISTERED = fromString("Unregistered"); + + /** Static value Completed for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState COMPLETED = fromString("Completed"); + + /** Static value Renewing for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState RENEWING = fromString("Renewing"); + + /** Static value Pending for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState PENDING = fromString("Pending"); + + /** Static value Waiting for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState WAITING = fromString("Waiting"); + + /** Static value InProgress for WorkflowProvisioningState. */ + public static final WorkflowProvisioningState IN_PROGRESS = fromString("InProgress"); + + /** + * Creates or finds a WorkflowProvisioningState from its string representation. + * @param name a name to look for + * @return the corresponding WorkflowProvisioningState + */ + @JsonCreator + public static WorkflowProvisioningState fromString(String name) { + return fromString(name, WorkflowProvisioningState.class); + } + + /** + * @return known WorkflowProvisioningState values + */ + public static Collection values() { + return values(WorkflowProvisioningState.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowReference.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowReference.java new file mode 100644 index 000000000000..b402356eb589 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowReference.java @@ -0,0 +1,16 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + + +/** + * The workflow reference. + */ +public class WorkflowReference extends ResourceReference { +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunAction.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunAction.java new file mode 100644 index 000000000000..342bea9f857f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunAction.java @@ -0,0 +1,94 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowRunActionInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import org.joda.time.DateTime; +import java.util.List; + +/** + * Type representing WorkflowRunAction. + */ +public interface WorkflowRunAction extends HasInner, Indexable, Refreshable, HasManager { + /** + * @return the code value. + */ + String code(); + + /** + * @return the correlation value. + */ + RunActionCorrelation correlation(); + + /** + * @return the endTime value. + */ + DateTime endTime(); + + /** + * @return the error value. + */ + Object error(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the inputsLink value. + */ + ContentLink inputsLink(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the outputsLink value. + */ + ContentLink outputsLink(); + + /** + * @return the retryHistory value. + */ + List retryHistory(); + + /** + * @return the startTime value. + */ + DateTime startTime(); + + /** + * @return the status value. + */ + WorkflowStatus status(); + + /** + * @return the trackedProperties value. + */ + Object trackedProperties(); + + /** + * @return the trackingId value. + */ + String trackingId(); + + /** + * @return the type value. + */ + String type(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionFilter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionFilter.java new file mode 100644 index 000000000000..c5569a58b85c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionFilter.java @@ -0,0 +1,46 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The workflow run action filter. + */ +public class WorkflowRunActionFilter { + /** + * The status of workflow run action. Possible values include: + * 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', + * 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', + * 'Ignored'. + */ + @JsonProperty(value = "status") + private WorkflowStatus status; + + /** + * Get the status of workflow run action. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @return the status value + */ + public WorkflowStatus status() { + return this.status; + } + + /** + * Set the status of workflow run action. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @param status the status value to set + * @return the WorkflowRunActionFilter object itself. + */ + public WorkflowRunActionFilter withStatus(WorkflowStatus status) { + this.status = status; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionRepetitions.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionRepetitions.java new file mode 100644 index 000000000000..a3768e2b81f6 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionRepetitions.java @@ -0,0 +1,57 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowRunActionRepetitionsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing WorkflowRunActionRepetitions. + */ +public interface WorkflowRunActionRepetitions extends HasInner { + /** + * Lists a workflow run expression trace. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listExpressionTracesAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName); + + /** + * Get a workflow run action repetition. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName); + + /** + * Get all of a workflow run action repetitions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(String resourceGroupName, String workflowName, String runName, String actionName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionRepetitionsRequestHistories.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionRepetitionsRequestHistories.java new file mode 100644 index 000000000000..a45a868e0b8a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionRepetitionsRequestHistories.java @@ -0,0 +1,46 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowRunActionRepetitionsRequestHistoriesInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing WorkflowRunActionRepetitionsRequestHistories. + */ +public interface WorkflowRunActionRepetitionsRequestHistories extends HasInner { + /** + * Gets a workflow run repetition request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @param requestHistoryName The request history name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName, String requestHistoryName); + + /** + * List a workflow run repetition request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroupName, final String workflowName, final String runName, final String actionName, final String repetitionName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionRequestHistories.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionRequestHistories.java new file mode 100644 index 000000000000..a83f1a91660d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionRequestHistories.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowRunActionRequestHistoriesInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing WorkflowRunActionRequestHistories. + */ +public interface WorkflowRunActionRequestHistories extends HasInner { + /** + * Gets a workflow run request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param requestHistoryName The request history name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String requestHistoryName); + + /** + * List a workflow run request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroupName, final String workflowName, final String runName, final String actionName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionScopeRepetitions.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionScopeRepetitions.java new file mode 100644 index 000000000000..9e15e49f8fb7 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActionScopeRepetitions.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowRunActionScopeRepetitionsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing WorkflowRunActionScopeRepetitions. + */ +public interface WorkflowRunActionScopeRepetitions extends HasInner { + /** + * Get a workflow run action scoped repetition. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName); + + /** + * List the workflow run action scoped repetitions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(String resourceGroupName, String workflowName, String runName, String actionName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActions.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActions.java new file mode 100644 index 000000000000..3c6d2f055f64 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunActions.java @@ -0,0 +1,54 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowRunActionsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing WorkflowRunActions. + */ +public interface WorkflowRunActions extends HasInner { + /** + * Lists a workflow run expression trace. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listExpressionTracesAsync(String resourceGroupName, String workflowName, String runName, String actionName); + + /** + * Gets a workflow run action. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName); + + /** + * Gets a list of workflow run actions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroupName, final String workflowName, final String runName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunFilter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunFilter.java new file mode 100644 index 000000000000..9d40405c96cb --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunFilter.java @@ -0,0 +1,45 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The workflow run filter. + */ +public class WorkflowRunFilter { + /** + * The status of workflow run. Possible values include: 'NotSpecified', + * 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', + * 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + */ + @JsonProperty(value = "status") + private WorkflowStatus status; + + /** + * Get the status of workflow run. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @return the status value + */ + public WorkflowStatus status() { + return this.status; + } + + /** + * Set the status of workflow run. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @param status the status value to set + * @return the WorkflowRunFilter object itself. + */ + public WorkflowRunFilter withStatus(WorkflowStatus status) { + this.status = status; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunOperations.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunOperations.java new file mode 100644 index 000000000000..aaeb53f0c458 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunOperations.java @@ -0,0 +1,31 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowRunOperationsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing WorkflowRunOperations. + */ +public interface WorkflowRunOperations extends HasInner { + /** + * Gets an operation for a run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param operationId The workflow operation id. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String workflowName, String runName, String operationId); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunTrigger.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunTrigger.java new file mode 100644 index 000000000000..2c42e7a37096 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRunTrigger.java @@ -0,0 +1,241 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import org.joda.time.DateTime; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The workflow run trigger. + */ +public class WorkflowRunTrigger { + /** + * Gets the name. + */ + @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY) + private String name; + + /** + * Gets the inputs. + */ + @JsonProperty(value = "inputs", access = JsonProperty.Access.WRITE_ONLY) + private Object inputs; + + /** + * Gets the link to inputs. + */ + @JsonProperty(value = "inputsLink", access = JsonProperty.Access.WRITE_ONLY) + private ContentLink inputsLink; + + /** + * Gets the outputs. + */ + @JsonProperty(value = "outputs", access = JsonProperty.Access.WRITE_ONLY) + private Object outputs; + + /** + * Gets the link to outputs. + */ + @JsonProperty(value = "outputsLink", access = JsonProperty.Access.WRITE_ONLY) + private ContentLink outputsLink; + + /** + * Gets the scheduled time. + */ + @JsonProperty(value = "scheduledTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime scheduledTime; + + /** + * Gets the start time. + */ + @JsonProperty(value = "startTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime startTime; + + /** + * Gets the end time. + */ + @JsonProperty(value = "endTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime endTime; + + /** + * Gets the tracking id. + */ + @JsonProperty(value = "trackingId", access = JsonProperty.Access.WRITE_ONLY) + private String trackingId; + + /** + * The run correlation. + */ + @JsonProperty(value = "correlation") + private Correlation correlation; + + /** + * Gets the code. + */ + @JsonProperty(value = "code", access = JsonProperty.Access.WRITE_ONLY) + private String code; + + /** + * Gets the status. Possible values include: 'NotSpecified', 'Paused', + * 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', + * 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + */ + @JsonProperty(value = "status", access = JsonProperty.Access.WRITE_ONLY) + private WorkflowStatus status; + + /** + * Gets the error. + */ + @JsonProperty(value = "error", access = JsonProperty.Access.WRITE_ONLY) + private Object error; + + /** + * Gets the tracked properties. + */ + @JsonProperty(value = "trackedProperties", access = JsonProperty.Access.WRITE_ONLY) + private Object trackedProperties; + + /** + * Get gets the name. + * + * @return the name value + */ + public String name() { + return this.name; + } + + /** + * Get gets the inputs. + * + * @return the inputs value + */ + public Object inputs() { + return this.inputs; + } + + /** + * Get gets the link to inputs. + * + * @return the inputsLink value + */ + public ContentLink inputsLink() { + return this.inputsLink; + } + + /** + * Get gets the outputs. + * + * @return the outputs value + */ + public Object outputs() { + return this.outputs; + } + + /** + * Get gets the link to outputs. + * + * @return the outputsLink value + */ + public ContentLink outputsLink() { + return this.outputsLink; + } + + /** + * Get gets the scheduled time. + * + * @return the scheduledTime value + */ + public DateTime scheduledTime() { + return this.scheduledTime; + } + + /** + * Get gets the start time. + * + * @return the startTime value + */ + public DateTime startTime() { + return this.startTime; + } + + /** + * Get gets the end time. + * + * @return the endTime value + */ + public DateTime endTime() { + return this.endTime; + } + + /** + * Get gets the tracking id. + * + * @return the trackingId value + */ + public String trackingId() { + return this.trackingId; + } + + /** + * Get the run correlation. + * + * @return the correlation value + */ + public Correlation correlation() { + return this.correlation; + } + + /** + * Set the run correlation. + * + * @param correlation the correlation value to set + * @return the WorkflowRunTrigger object itself. + */ + public WorkflowRunTrigger withCorrelation(Correlation correlation) { + this.correlation = correlation; + return this; + } + + /** + * Get gets the code. + * + * @return the code value + */ + public String code() { + return this.code; + } + + /** + * Get gets the status. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @return the status value + */ + public WorkflowStatus status() { + return this.status; + } + + /** + * Get gets the error. + * + * @return the error value + */ + public Object error() { + return this.error; + } + + /** + * Get gets the tracked properties. + * + * @return the trackedProperties value + */ + public Object trackedProperties() { + return this.trackedProperties; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRuns.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRuns.java new file mode 100644 index 000000000000..2c236840f322 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowRuns.java @@ -0,0 +1,52 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import rx.Completable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowRunsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing WorkflowRuns. + */ +public interface WorkflowRuns extends HasInner { + /** + * Cancels a workflow run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable cancelAsync(String resourceGroupName, String workflowName, String runName); + + /** + * Gets a workflow run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String workflowName, String runName); + + /** + * Gets a list of workflow runs. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroupName, final String workflowName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowState.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowState.java new file mode 100644 index 000000000000..cdabed6e7827 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowState.java @@ -0,0 +1,53 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for WorkflowState. + */ +public final class WorkflowState extends ExpandableStringEnum { + /** Static value NotSpecified for WorkflowState. */ + public static final WorkflowState NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Completed for WorkflowState. */ + public static final WorkflowState COMPLETED = fromString("Completed"); + + /** Static value Enabled for WorkflowState. */ + public static final WorkflowState ENABLED = fromString("Enabled"); + + /** Static value Disabled for WorkflowState. */ + public static final WorkflowState DISABLED = fromString("Disabled"); + + /** Static value Deleted for WorkflowState. */ + public static final WorkflowState DELETED = fromString("Deleted"); + + /** Static value Suspended for WorkflowState. */ + public static final WorkflowState SUSPENDED = fromString("Suspended"); + + /** + * Creates or finds a WorkflowState from its string representation. + * @param name a name to look for + * @return the corresponding WorkflowState + */ + @JsonCreator + public static WorkflowState fromString(String name) { + return fromString(name, WorkflowState.class); + } + + /** + * @return known WorkflowState values + */ + public static Collection values() { + return values(WorkflowState.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowStatus.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowStatus.java new file mode 100644 index 000000000000..9afd75fb4bec --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowStatus.java @@ -0,0 +1,74 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for WorkflowStatus. + */ +public final class WorkflowStatus extends ExpandableStringEnum { + /** Static value NotSpecified for WorkflowStatus. */ + public static final WorkflowStatus NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Paused for WorkflowStatus. */ + public static final WorkflowStatus PAUSED = fromString("Paused"); + + /** Static value Running for WorkflowStatus. */ + public static final WorkflowStatus RUNNING = fromString("Running"); + + /** Static value Waiting for WorkflowStatus. */ + public static final WorkflowStatus WAITING = fromString("Waiting"); + + /** Static value Succeeded for WorkflowStatus. */ + public static final WorkflowStatus SUCCEEDED = fromString("Succeeded"); + + /** Static value Skipped for WorkflowStatus. */ + public static final WorkflowStatus SKIPPED = fromString("Skipped"); + + /** Static value Suspended for WorkflowStatus. */ + public static final WorkflowStatus SUSPENDED = fromString("Suspended"); + + /** Static value Cancelled for WorkflowStatus. */ + public static final WorkflowStatus CANCELLED = fromString("Cancelled"); + + /** Static value Failed for WorkflowStatus. */ + public static final WorkflowStatus FAILED = fromString("Failed"); + + /** Static value Faulted for WorkflowStatus. */ + public static final WorkflowStatus FAULTED = fromString("Faulted"); + + /** Static value TimedOut for WorkflowStatus. */ + public static final WorkflowStatus TIMED_OUT = fromString("TimedOut"); + + /** Static value Aborted for WorkflowStatus. */ + public static final WorkflowStatus ABORTED = fromString("Aborted"); + + /** Static value Ignored for WorkflowStatus. */ + public static final WorkflowStatus IGNORED = fromString("Ignored"); + + /** + * Creates or finds a WorkflowStatus from its string representation. + * @param name a name to look for + * @return the corresponding WorkflowStatus + */ + @JsonCreator + public static WorkflowStatus fromString(String name) { + return fromString(name, WorkflowStatus.class); + } + + /** + * @return known WorkflowStatus values + */ + public static Collection values() { + return values(WorkflowStatus.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTrigger.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTrigger.java new file mode 100644 index 000000000000..3511bc85e2b9 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTrigger.java @@ -0,0 +1,83 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowTriggerInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import org.joda.time.DateTime; + +/** + * Type representing WorkflowTrigger. + */ +public interface WorkflowTrigger extends HasInner, Indexable, Refreshable, HasManager { + /** + * @return the changedTime value. + */ + DateTime changedTime(); + + /** + * @return the createdTime value. + */ + DateTime createdTime(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the lastExecutionTime value. + */ + DateTime lastExecutionTime(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the nextExecutionTime value. + */ + DateTime nextExecutionTime(); + + /** + * @return the provisioningState value. + */ + WorkflowTriggerProvisioningState provisioningState(); + + /** + * @return the recurrence value. + */ + WorkflowTriggerRecurrence recurrence(); + + /** + * @return the state value. + */ + WorkflowState state(); + + /** + * @return the status value. + */ + WorkflowStatus status(); + + /** + * @return the type value. + */ + String type(); + + /** + * @return the workflow value. + */ + ResourceReference workflow(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerCallbackUrl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerCallbackUrl.java new file mode 100644 index 000000000000..cb9e506f1da4 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerCallbackUrl.java @@ -0,0 +1,51 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowTriggerCallbackUrlInner; +import java.util.List; + +/** + * Type representing WorkflowTriggerCallbackUrl. + */ +public interface WorkflowTriggerCallbackUrl extends HasInner, HasManager { + /** + * @return the basePath value. + */ + String basePath(); + + /** + * @return the method value. + */ + String method(); + + /** + * @return the queries value. + */ + WorkflowTriggerListCallbackUrlQueries queries(); + + /** + * @return the relativePath value. + */ + String relativePath(); + + /** + * @return the relativePathParameters value. + */ + List relativePathParameters(); + + /** + * @return the value value. + */ + String value(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerFilter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerFilter.java new file mode 100644 index 000000000000..a6d001fc880d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerFilter.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The workflow trigger filter. + */ +public class WorkflowTriggerFilter { + /** + * The state of workflow trigger. Possible values include: 'NotSpecified', + * 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + */ + @JsonProperty(value = "state") + private WorkflowState state; + + /** + * Get the state of workflow trigger. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + * + * @return the state value + */ + public WorkflowState state() { + return this.state; + } + + /** + * Set the state of workflow trigger. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + * + * @param state the state value to set + * @return the WorkflowTriggerFilter object itself. + */ + public WorkflowTriggerFilter withState(WorkflowState state) { + this.state = state; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerHistories.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerHistories.java new file mode 100644 index 000000000000..31a551f1e078 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerHistories.java @@ -0,0 +1,55 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import rx.Completable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowTriggerHistoriesInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing WorkflowTriggerHistories. + */ +public interface WorkflowTriggerHistories extends HasInner { + /** + * Resubmits a workflow run based on the trigger history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param historyName The workflow trigger history name. Corresponds to the run name for triggers that resulted in a run. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable resubmitAsync(String resourceGroupName, String workflowName, String triggerName, String historyName); + + /** + * Gets a workflow trigger history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param historyName The workflow trigger history name. Corresponds to the run name for triggers that resulted in a run. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String workflowName, String triggerName, String historyName); + + /** + * Gets a list of workflow trigger histories. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroupName, final String workflowName, final String triggerName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerHistory.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerHistory.java new file mode 100644 index 000000000000..8e7eadbf384b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerHistory.java @@ -0,0 +1,98 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowTriggerHistoryInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import org.joda.time.DateTime; + +/** + * Type representing WorkflowTriggerHistory. + */ +public interface WorkflowTriggerHistory extends HasInner, Indexable, Refreshable, HasManager { + /** + * @return the code value. + */ + String code(); + + /** + * @return the correlation value. + */ + Correlation correlation(); + + /** + * @return the endTime value. + */ + DateTime endTime(); + + /** + * @return the error value. + */ + Object error(); + + /** + * @return the fired value. + */ + Boolean fired(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the inputsLink value. + */ + ContentLink inputsLink(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the outputsLink value. + */ + ContentLink outputsLink(); + + /** + * @return the run value. + */ + ResourceReference run(); + + /** + * @return the scheduledTime value. + */ + DateTime scheduledTime(); + + /** + * @return the startTime value. + */ + DateTime startTime(); + + /** + * @return the status value. + */ + WorkflowStatus status(); + + /** + * @return the trackingId value. + */ + String trackingId(); + + /** + * @return the type value. + */ + String type(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerHistoryFilter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerHistoryFilter.java new file mode 100644 index 000000000000..00e247f0d191 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerHistoryFilter.java @@ -0,0 +1,46 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The workflow trigger history filter. + */ +public class WorkflowTriggerHistoryFilter { + /** + * The status of workflow trigger history. Possible values include: + * 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', + * 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', + * 'Ignored'. + */ + @JsonProperty(value = "status") + private WorkflowStatus status; + + /** + * Get the status of workflow trigger history. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @return the status value + */ + public WorkflowStatus status() { + return this.status; + } + + /** + * Set the status of workflow trigger history. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @param status the status value to set + * @return the WorkflowTriggerHistoryFilter object itself. + */ + public WorkflowTriggerHistoryFilter withStatus(WorkflowStatus status) { + this.status = status; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerListCallbackUrlQueries.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerListCallbackUrlQueries.java new file mode 100644 index 000000000000..58e7c3c8ac6d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerListCallbackUrlQueries.java @@ -0,0 +1,147 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Gets the workflow trigger callback URL query parameters. + */ +public class WorkflowTriggerListCallbackUrlQueries { + /** + * The api version. + */ + @JsonProperty(value = "api-version") + private String apiVersion; + + /** + * The SAS permissions. + */ + @JsonProperty(value = "sp") + private String sp; + + /** + * The SAS version. + */ + @JsonProperty(value = "sv") + private String sv; + + /** + * The SAS signature. + */ + @JsonProperty(value = "sig") + private String sig; + + /** + * The SAS timestamp. + */ + @JsonProperty(value = "se") + private String se; + + /** + * Get the api version. + * + * @return the apiVersion value + */ + public String apiVersion() { + return this.apiVersion; + } + + /** + * Set the api version. + * + * @param apiVersion the apiVersion value to set + * @return the WorkflowTriggerListCallbackUrlQueries object itself. + */ + public WorkflowTriggerListCallbackUrlQueries withApiVersion(String apiVersion) { + this.apiVersion = apiVersion; + return this; + } + + /** + * Get the SAS permissions. + * + * @return the sp value + */ + public String sp() { + return this.sp; + } + + /** + * Set the SAS permissions. + * + * @param sp the sp value to set + * @return the WorkflowTriggerListCallbackUrlQueries object itself. + */ + public WorkflowTriggerListCallbackUrlQueries withSp(String sp) { + this.sp = sp; + return this; + } + + /** + * Get the SAS version. + * + * @return the sv value + */ + public String sv() { + return this.sv; + } + + /** + * Set the SAS version. + * + * @param sv the sv value to set + * @return the WorkflowTriggerListCallbackUrlQueries object itself. + */ + public WorkflowTriggerListCallbackUrlQueries withSv(String sv) { + this.sv = sv; + return this; + } + + /** + * Get the SAS signature. + * + * @return the sig value + */ + public String sig() { + return this.sig; + } + + /** + * Set the SAS signature. + * + * @param sig the sig value to set + * @return the WorkflowTriggerListCallbackUrlQueries object itself. + */ + public WorkflowTriggerListCallbackUrlQueries withSig(String sig) { + this.sig = sig; + return this; + } + + /** + * Get the SAS timestamp. + * + * @return the se value + */ + public String se() { + return this.se; + } + + /** + * Set the SAS timestamp. + * + * @param se the se value to set + * @return the WorkflowTriggerListCallbackUrlQueries object itself. + */ + public WorkflowTriggerListCallbackUrlQueries withSe(String se) { + this.se = se; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerProvisioningState.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerProvisioningState.java new file mode 100644 index 000000000000..e289aca35a51 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerProvisioningState.java @@ -0,0 +1,89 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for WorkflowTriggerProvisioningState. + */ +public final class WorkflowTriggerProvisioningState extends ExpandableStringEnum { + /** Static value NotSpecified for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Accepted for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState ACCEPTED = fromString("Accepted"); + + /** Static value Running for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState RUNNING = fromString("Running"); + + /** Static value Ready for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState READY = fromString("Ready"); + + /** Static value Creating for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState CREATING = fromString("Creating"); + + /** Static value Created for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState CREATED = fromString("Created"); + + /** Static value Deleting for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState DELETING = fromString("Deleting"); + + /** Static value Deleted for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState DELETED = fromString("Deleted"); + + /** Static value Canceled for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState CANCELED = fromString("Canceled"); + + /** Static value Failed for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState FAILED = fromString("Failed"); + + /** Static value Succeeded for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState SUCCEEDED = fromString("Succeeded"); + + /** Static value Moving for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState MOVING = fromString("Moving"); + + /** Static value Updating for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState UPDATING = fromString("Updating"); + + /** Static value Registering for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState REGISTERING = fromString("Registering"); + + /** Static value Registered for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState REGISTERED = fromString("Registered"); + + /** Static value Unregistering for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState UNREGISTERING = fromString("Unregistering"); + + /** Static value Unregistered for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState UNREGISTERED = fromString("Unregistered"); + + /** Static value Completed for WorkflowTriggerProvisioningState. */ + public static final WorkflowTriggerProvisioningState COMPLETED = fromString("Completed"); + + /** + * Creates or finds a WorkflowTriggerProvisioningState from its string representation. + * @param name a name to look for + * @return the corresponding WorkflowTriggerProvisioningState + */ + @JsonCreator + public static WorkflowTriggerProvisioningState fromString(String name) { + return fromString(name, WorkflowTriggerProvisioningState.class); + } + + /** + * @return known WorkflowTriggerProvisioningState values + */ + public static Collection values() { + return values(WorkflowTriggerProvisioningState.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerRecurrence.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerRecurrence.java new file mode 100644 index 000000000000..410bd98fe1ab --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerRecurrence.java @@ -0,0 +1,174 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The workflow trigger recurrence. + */ +public class WorkflowTriggerRecurrence { + /** + * The frequency. Possible values include: 'NotSpecified', 'Second', + * 'Minute', 'Hour', 'Day', 'Week', 'Month', 'Year'. + */ + @JsonProperty(value = "frequency") + private RecurrenceFrequency frequency; + + /** + * The interval. + */ + @JsonProperty(value = "interval") + private Integer interval; + + /** + * The start time. + */ + @JsonProperty(value = "startTime") + private String startTime; + + /** + * The end time. + */ + @JsonProperty(value = "endTime") + private String endTime; + + /** + * The time zone. + */ + @JsonProperty(value = "timeZone") + private String timeZone; + + /** + * The recurrence schedule. + */ + @JsonProperty(value = "schedule") + private RecurrenceSchedule schedule; + + /** + * Get the frequency. Possible values include: 'NotSpecified', 'Second', 'Minute', 'Hour', 'Day', 'Week', 'Month', 'Year'. + * + * @return the frequency value + */ + public RecurrenceFrequency frequency() { + return this.frequency; + } + + /** + * Set the frequency. Possible values include: 'NotSpecified', 'Second', 'Minute', 'Hour', 'Day', 'Week', 'Month', 'Year'. + * + * @param frequency the frequency value to set + * @return the WorkflowTriggerRecurrence object itself. + */ + public WorkflowTriggerRecurrence withFrequency(RecurrenceFrequency frequency) { + this.frequency = frequency; + return this; + } + + /** + * Get the interval. + * + * @return the interval value + */ + public Integer interval() { + return this.interval; + } + + /** + * Set the interval. + * + * @param interval the interval value to set + * @return the WorkflowTriggerRecurrence object itself. + */ + public WorkflowTriggerRecurrence withInterval(Integer interval) { + this.interval = interval; + return this; + } + + /** + * Get the start time. + * + * @return the startTime value + */ + public String startTime() { + return this.startTime; + } + + /** + * Set the start time. + * + * @param startTime the startTime value to set + * @return the WorkflowTriggerRecurrence object itself. + */ + public WorkflowTriggerRecurrence withStartTime(String startTime) { + this.startTime = startTime; + return this; + } + + /** + * Get the end time. + * + * @return the endTime value + */ + public String endTime() { + return this.endTime; + } + + /** + * Set the end time. + * + * @param endTime the endTime value to set + * @return the WorkflowTriggerRecurrence object itself. + */ + public WorkflowTriggerRecurrence withEndTime(String endTime) { + this.endTime = endTime; + return this; + } + + /** + * Get the time zone. + * + * @return the timeZone value + */ + public String timeZone() { + return this.timeZone; + } + + /** + * Set the time zone. + * + * @param timeZone the timeZone value to set + * @return the WorkflowTriggerRecurrence object itself. + */ + public WorkflowTriggerRecurrence withTimeZone(String timeZone) { + this.timeZone = timeZone; + return this; + } + + /** + * Get the recurrence schedule. + * + * @return the schedule value + */ + public RecurrenceSchedule schedule() { + return this.schedule; + } + + /** + * Set the recurrence schedule. + * + * @param schedule the schedule value to set + * @return the WorkflowTriggerRecurrence object itself. + */ + public WorkflowTriggerRecurrence withSchedule(RecurrenceSchedule schedule) { + this.schedule = schedule; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerReference.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerReference.java new file mode 100644 index 000000000000..eff39d29555f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggerReference.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The workflow trigger reference. + */ +public class WorkflowTriggerReference extends ResourceReference { + /** + * The workflow name. + */ + @JsonProperty(value = "flowName") + private String flowName; + + /** + * The workflow trigger name. + */ + @JsonProperty(value = "triggerName") + private String triggerName; + + /** + * Get the workflow name. + * + * @return the flowName value + */ + public String flowName() { + return this.flowName; + } + + /** + * Set the workflow name. + * + * @param flowName the flowName value to set + * @return the WorkflowTriggerReference object itself. + */ + public WorkflowTriggerReference withFlowName(String flowName) { + this.flowName = flowName; + return this; + } + + /** + * Get the workflow trigger name. + * + * @return the triggerName value + */ + public String triggerName() { + return this.triggerName; + } + + /** + * Set the workflow trigger name. + * + * @param triggerName the triggerName value to set + * @return the WorkflowTriggerReference object itself. + */ + public WorkflowTriggerReference withTriggerName(String triggerName) { + this.triggerName = triggerName; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggers.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggers.java new file mode 100644 index 000000000000..3ed35ec818a0 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowTriggers.java @@ -0,0 +1,96 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTrigger; +import rx.Completable; + +/** + * Type representing WorkflowTriggers. + */ +public interface WorkflowTriggers { + /** + * Gets a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String workflowName, String triggerName); + + /** + * Gets a list of workflow triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroupName, final String workflowName); + + /** + * Resets a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable resetAsync(String resourceGroupName, String workflowName, String triggerName); + + /** + * Runs a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable runAsync(String resourceGroupName, String workflowName, String triggerName); + + /** + * Sets the state of a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param source The source. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable setStateAsync(String resourceGroupName, String workflowName, String triggerName, WorkflowTriggerReference source); + + /** + * Get the callback URL for a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listCallbackUrlAsync(String resourceGroupName, String workflowName, String triggerName); + + /** + * Get the trigger schema as JSON. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getSchemaJsonAsync(String resourceGroupName, String workflowName, String triggerName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowVersion.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowVersion.java new file mode 100644 index 000000000000..280e8fa16879 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowVersion.java @@ -0,0 +1,109 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowVersionInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import org.joda.time.DateTime; +import java.util.Map; + +/** + * Type representing WorkflowVersion. + */ +public interface WorkflowVersion extends HasInner, Indexable, Refreshable, HasManager { + /** + * @return the accessControl value. + */ + FlowAccessControlConfiguration accessControl(); + + /** + * @return the accessEndpoint value. + */ + String accessEndpoint(); + + /** + * @return the changedTime value. + */ + DateTime changedTime(); + + /** + * @return the createdTime value. + */ + DateTime createdTime(); + + /** + * @return the definition value. + */ + Object definition(); + + /** + * @return the endpointsConfiguration value. + */ + FlowEndpointsConfiguration endpointsConfiguration(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the integrationAccount value. + */ + ResourceReference integrationAccount(); + + /** + * @return the location value. + */ + String location(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the parameters value. + */ + Map parameters(); + + /** + * @return the provisioningState value. + */ + WorkflowProvisioningState provisioningState(); + + /** + * @return the sku value. + */ + Sku sku(); + + /** + * @return the state value. + */ + WorkflowState state(); + + /** + * @return the tags value. + */ + Map tags(); + + /** + * @return the type value. + */ + String type(); + + /** + * @return the version value. + */ + String version(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowVersionTriggers.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowVersionTriggers.java new file mode 100644 index 000000000000..91e5c54a557e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowVersionTriggers.java @@ -0,0 +1,31 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowVersionTriggersInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing WorkflowVersionTriggers. + */ +public interface WorkflowVersionTriggers extends HasInner { + /** + * Get the callback url for a trigger of a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listCallbackUrlAsync(String resourceGroupName, String workflowName, String versionId, String triggerName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowVersions.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowVersions.java new file mode 100644 index 000000000000..cfb7ccf1d2eb --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowVersions.java @@ -0,0 +1,40 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowVersionsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing WorkflowVersions. + */ +public interface WorkflowVersions extends HasInner { + /** + * Gets a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable getAsync(String resourceGroupName, String workflowName, String versionId); + + /** + * Gets a list of workflow versions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listAsync(final String resourceGroupName, final String workflowName); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowWorkflowRun.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowWorkflowRun.java new file mode 100644 index 000000000000..63f3946ee24c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WorkflowWorkflowRun.java @@ -0,0 +1,99 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowRunInner; +import com.microsoft.azure.arm.model.Indexable; +import com.microsoft.azure.arm.model.Refreshable; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.LogicManager; +import org.joda.time.DateTime; +import java.util.Map; + +/** + * Type representing WorkflowWorkflowRun. + */ +public interface WorkflowWorkflowRun extends HasInner, Indexable, Refreshable, HasManager { + /** + * @return the code value. + */ + String code(); + + /** + * @return the correlation value. + */ + Correlation correlation(); + + /** + * @return the correlationId value. + */ + String correlationId(); + + /** + * @return the endTime value. + */ + DateTime endTime(); + + /** + * @return the error value. + */ + Object error(); + + /** + * @return the id value. + */ + String id(); + + /** + * @return the name value. + */ + String name(); + + /** + * @return the outputs value. + */ + Map outputs(); + + /** + * @return the response value. + */ + WorkflowRunTrigger response(); + + /** + * @return the startTime value. + */ + DateTime startTime(); + + /** + * @return the status value. + */ + WorkflowStatus status(); + + /** + * @return the trigger value. + */ + WorkflowRunTrigger trigger(); + + /** + * @return the type value. + */ + String type(); + + /** + * @return the waitEndTime value. + */ + DateTime waitEndTime(); + + /** + * @return the workflow value. + */ + ResourceReference workflow(); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Workflows.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Workflows.java new file mode 100644 index 000000000000..bc71722f2280 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/Workflows.java @@ -0,0 +1,121 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import com.microsoft.azure.arm.resources.collection.SupportsDeletingByResourceGroup; +import com.microsoft.azure.arm.resources.collection.SupportsBatchDeletion; +import com.microsoft.azure.arm.resources.collection.SupportsGettingByResourceGroup; +import rx.Observable; +import com.microsoft.azure.arm.resources.collection.SupportsListingByResourceGroup; +import com.microsoft.azure.arm.collection.SupportsListing; +import rx.Completable; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowInner; +import com.microsoft.azure.management.logic.v2019_05_01.implementation.WorkflowsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing Workflows. + */ +public interface Workflows extends SupportsCreating, SupportsDeletingByResourceGroup, SupportsBatchDeletion, SupportsGettingByResourceGroup, SupportsListingByResourceGroup, SupportsListing, HasInner { + /** + * Disables a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable disableAsync(String resourceGroupName, String workflowName); + + /** + * Enables a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable enableAsync(String resourceGroupName, String workflowName); + + /** + * Generates the upgraded definition for a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable generateUpgradedDefinitionAsync(String resourceGroupName, String workflowName); + + /** + * Get the workflow callback Url. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param listCallbackUrl Which callback url to list. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listCallbackUrlAsync(String resourceGroupName, String workflowName, GetCallbackUrlParameters listCallbackUrl); + + /** + * Gets an OpenAPI definition for the workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Observable listSwaggerAsync(String resourceGroupName, String workflowName); + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable moveAsync(String resourceGroupName, String workflowName); + + /** + * Regenerates the callback URL access key for request triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable regenerateAccessKeyAsync(String resourceGroupName, String workflowName); + + /** + * Validates the workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param validate The workflow. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable validateByResourceGroupAsync(String resourceGroupName, String workflowName, WorkflowInner validate); + + /** + * Validates the workflow definition. + * + * @param resourceGroupName The resource group name. + * @param location The workflow location. + * @param workflowName The workflow name. + * @param validate The workflow. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable validateByLocationAsync(String resourceGroupName, String location, String workflowName, WorkflowInner validate); + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WsdlImportMethod.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WsdlImportMethod.java new file mode 100644 index 000000000000..0ca3e4267535 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WsdlImportMethod.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for WsdlImportMethod. + */ +public final class WsdlImportMethod extends ExpandableStringEnum { + /** Static value NotSpecified for WsdlImportMethod. */ + public static final WsdlImportMethod NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value SoapToRest for WsdlImportMethod. */ + public static final WsdlImportMethod SOAP_TO_REST = fromString("SoapToRest"); + + /** Static value SoapPassThrough for WsdlImportMethod. */ + public static final WsdlImportMethod SOAP_PASS_THROUGH = fromString("SoapPassThrough"); + + /** + * Creates or finds a WsdlImportMethod from its string representation. + * @param name a name to look for + * @return the corresponding WsdlImportMethod + */ + @JsonCreator + public static WsdlImportMethod fromString(String name) { + return fromString(name, WsdlImportMethod.class); + } + + /** + * @return known WsdlImportMethod values + */ + public static Collection values() { + return values(WsdlImportMethod.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WsdlService.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WsdlService.java new file mode 100644 index 000000000000..e67047062dd4 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/WsdlService.java @@ -0,0 +1,70 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The WSDL service. + */ +public class WsdlService { + /** + * The qualified name. + */ + @JsonProperty(value = "qualifiedName") + private String qualifiedName; + + /** + * The list of endpoints' qualified names. + */ + @JsonProperty(value = "EndpointQualifiedNames") + private List endpointQualifiedNames; + + /** + * Get the qualified name. + * + * @return the qualifiedName value + */ + public String qualifiedName() { + return this.qualifiedName; + } + + /** + * Set the qualified name. + * + * @param qualifiedName the qualifiedName value to set + * @return the WsdlService object itself. + */ + public WsdlService withQualifiedName(String qualifiedName) { + this.qualifiedName = qualifiedName; + return this; + } + + /** + * Get the list of endpoints' qualified names. + * + * @return the endpointQualifiedNames value + */ + public List endpointQualifiedNames() { + return this.endpointQualifiedNames; + } + + /** + * Set the list of endpoints' qualified names. + * + * @param endpointQualifiedNames the endpointQualifiedNames value to set + * @return the WsdlService object itself. + */ + public WsdlService withEndpointQualifiedNames(List endpointQualifiedNames) { + this.endpointQualifiedNames = endpointQualifiedNames; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12AcknowledgementSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12AcknowledgementSettings.java new file mode 100644 index 000000000000..2062bc38e9d1 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12AcknowledgementSettings.java @@ -0,0 +1,407 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 agreement acknowledgement settings. + */ +public class X12AcknowledgementSettings { + /** + * The value indicating whether technical acknowledgement is needed. + */ + @JsonProperty(value = "needTechnicalAcknowledgement", required = true) + private boolean needTechnicalAcknowledgement; + + /** + * The value indicating whether to batch the technical acknowledgements. + */ + @JsonProperty(value = "batchTechnicalAcknowledgements", required = true) + private boolean batchTechnicalAcknowledgements; + + /** + * The value indicating whether functional acknowledgement is needed. + */ + @JsonProperty(value = "needFunctionalAcknowledgement", required = true) + private boolean needFunctionalAcknowledgement; + + /** + * The functional acknowledgement version. + */ + @JsonProperty(value = "functionalAcknowledgementVersion") + private String functionalAcknowledgementVersion; + + /** + * The value indicating whether to batch functional acknowledgements. + */ + @JsonProperty(value = "batchFunctionalAcknowledgements", required = true) + private boolean batchFunctionalAcknowledgements; + + /** + * The value indicating whether implementation acknowledgement is needed. + */ + @JsonProperty(value = "needImplementationAcknowledgement", required = true) + private boolean needImplementationAcknowledgement; + + /** + * The implementation acknowledgement version. + */ + @JsonProperty(value = "implementationAcknowledgementVersion") + private String implementationAcknowledgementVersion; + + /** + * The value indicating whether to batch implementation acknowledgements. + */ + @JsonProperty(value = "batchImplementationAcknowledgements", required = true) + private boolean batchImplementationAcknowledgements; + + /** + * The value indicating whether a loop is needed for valid messages. + */ + @JsonProperty(value = "needLoopForValidMessages", required = true) + private boolean needLoopForValidMessages; + + /** + * The value indicating whether to send synchronous acknowledgement. + */ + @JsonProperty(value = "sendSynchronousAcknowledgement", required = true) + private boolean sendSynchronousAcknowledgement; + + /** + * The acknowledgement control number prefix. + */ + @JsonProperty(value = "acknowledgementControlNumberPrefix") + private String acknowledgementControlNumberPrefix; + + /** + * The acknowledgement control number suffix. + */ + @JsonProperty(value = "acknowledgementControlNumberSuffix") + private String acknowledgementControlNumberSuffix; + + /** + * The acknowledgement control number lower bound. + */ + @JsonProperty(value = "acknowledgementControlNumberLowerBound", required = true) + private int acknowledgementControlNumberLowerBound; + + /** + * The acknowledgement control number upper bound. + */ + @JsonProperty(value = "acknowledgementControlNumberUpperBound", required = true) + private int acknowledgementControlNumberUpperBound; + + /** + * The value indicating whether to rollover acknowledgement control number. + */ + @JsonProperty(value = "rolloverAcknowledgementControlNumber", required = true) + private boolean rolloverAcknowledgementControlNumber; + + /** + * Get the value indicating whether technical acknowledgement is needed. + * + * @return the needTechnicalAcknowledgement value + */ + public boolean needTechnicalAcknowledgement() { + return this.needTechnicalAcknowledgement; + } + + /** + * Set the value indicating whether technical acknowledgement is needed. + * + * @param needTechnicalAcknowledgement the needTechnicalAcknowledgement value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withNeedTechnicalAcknowledgement(boolean needTechnicalAcknowledgement) { + this.needTechnicalAcknowledgement = needTechnicalAcknowledgement; + return this; + } + + /** + * Get the value indicating whether to batch the technical acknowledgements. + * + * @return the batchTechnicalAcknowledgements value + */ + public boolean batchTechnicalAcknowledgements() { + return this.batchTechnicalAcknowledgements; + } + + /** + * Set the value indicating whether to batch the technical acknowledgements. + * + * @param batchTechnicalAcknowledgements the batchTechnicalAcknowledgements value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withBatchTechnicalAcknowledgements(boolean batchTechnicalAcknowledgements) { + this.batchTechnicalAcknowledgements = batchTechnicalAcknowledgements; + return this; + } + + /** + * Get the value indicating whether functional acknowledgement is needed. + * + * @return the needFunctionalAcknowledgement value + */ + public boolean needFunctionalAcknowledgement() { + return this.needFunctionalAcknowledgement; + } + + /** + * Set the value indicating whether functional acknowledgement is needed. + * + * @param needFunctionalAcknowledgement the needFunctionalAcknowledgement value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withNeedFunctionalAcknowledgement(boolean needFunctionalAcknowledgement) { + this.needFunctionalAcknowledgement = needFunctionalAcknowledgement; + return this; + } + + /** + * Get the functional acknowledgement version. + * + * @return the functionalAcknowledgementVersion value + */ + public String functionalAcknowledgementVersion() { + return this.functionalAcknowledgementVersion; + } + + /** + * Set the functional acknowledgement version. + * + * @param functionalAcknowledgementVersion the functionalAcknowledgementVersion value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withFunctionalAcknowledgementVersion(String functionalAcknowledgementVersion) { + this.functionalAcknowledgementVersion = functionalAcknowledgementVersion; + return this; + } + + /** + * Get the value indicating whether to batch functional acknowledgements. + * + * @return the batchFunctionalAcknowledgements value + */ + public boolean batchFunctionalAcknowledgements() { + return this.batchFunctionalAcknowledgements; + } + + /** + * Set the value indicating whether to batch functional acknowledgements. + * + * @param batchFunctionalAcknowledgements the batchFunctionalAcknowledgements value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withBatchFunctionalAcknowledgements(boolean batchFunctionalAcknowledgements) { + this.batchFunctionalAcknowledgements = batchFunctionalAcknowledgements; + return this; + } + + /** + * Get the value indicating whether implementation acknowledgement is needed. + * + * @return the needImplementationAcknowledgement value + */ + public boolean needImplementationAcknowledgement() { + return this.needImplementationAcknowledgement; + } + + /** + * Set the value indicating whether implementation acknowledgement is needed. + * + * @param needImplementationAcknowledgement the needImplementationAcknowledgement value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withNeedImplementationAcknowledgement(boolean needImplementationAcknowledgement) { + this.needImplementationAcknowledgement = needImplementationAcknowledgement; + return this; + } + + /** + * Get the implementation acknowledgement version. + * + * @return the implementationAcknowledgementVersion value + */ + public String implementationAcknowledgementVersion() { + return this.implementationAcknowledgementVersion; + } + + /** + * Set the implementation acknowledgement version. + * + * @param implementationAcknowledgementVersion the implementationAcknowledgementVersion value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withImplementationAcknowledgementVersion(String implementationAcknowledgementVersion) { + this.implementationAcknowledgementVersion = implementationAcknowledgementVersion; + return this; + } + + /** + * Get the value indicating whether to batch implementation acknowledgements. + * + * @return the batchImplementationAcknowledgements value + */ + public boolean batchImplementationAcknowledgements() { + return this.batchImplementationAcknowledgements; + } + + /** + * Set the value indicating whether to batch implementation acknowledgements. + * + * @param batchImplementationAcknowledgements the batchImplementationAcknowledgements value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withBatchImplementationAcknowledgements(boolean batchImplementationAcknowledgements) { + this.batchImplementationAcknowledgements = batchImplementationAcknowledgements; + return this; + } + + /** + * Get the value indicating whether a loop is needed for valid messages. + * + * @return the needLoopForValidMessages value + */ + public boolean needLoopForValidMessages() { + return this.needLoopForValidMessages; + } + + /** + * Set the value indicating whether a loop is needed for valid messages. + * + * @param needLoopForValidMessages the needLoopForValidMessages value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withNeedLoopForValidMessages(boolean needLoopForValidMessages) { + this.needLoopForValidMessages = needLoopForValidMessages; + return this; + } + + /** + * Get the value indicating whether to send synchronous acknowledgement. + * + * @return the sendSynchronousAcknowledgement value + */ + public boolean sendSynchronousAcknowledgement() { + return this.sendSynchronousAcknowledgement; + } + + /** + * Set the value indicating whether to send synchronous acknowledgement. + * + * @param sendSynchronousAcknowledgement the sendSynchronousAcknowledgement value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withSendSynchronousAcknowledgement(boolean sendSynchronousAcknowledgement) { + this.sendSynchronousAcknowledgement = sendSynchronousAcknowledgement; + return this; + } + + /** + * Get the acknowledgement control number prefix. + * + * @return the acknowledgementControlNumberPrefix value + */ + public String acknowledgementControlNumberPrefix() { + return this.acknowledgementControlNumberPrefix; + } + + /** + * Set the acknowledgement control number prefix. + * + * @param acknowledgementControlNumberPrefix the acknowledgementControlNumberPrefix value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withAcknowledgementControlNumberPrefix(String acknowledgementControlNumberPrefix) { + this.acknowledgementControlNumberPrefix = acknowledgementControlNumberPrefix; + return this; + } + + /** + * Get the acknowledgement control number suffix. + * + * @return the acknowledgementControlNumberSuffix value + */ + public String acknowledgementControlNumberSuffix() { + return this.acknowledgementControlNumberSuffix; + } + + /** + * Set the acknowledgement control number suffix. + * + * @param acknowledgementControlNumberSuffix the acknowledgementControlNumberSuffix value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withAcknowledgementControlNumberSuffix(String acknowledgementControlNumberSuffix) { + this.acknowledgementControlNumberSuffix = acknowledgementControlNumberSuffix; + return this; + } + + /** + * Get the acknowledgement control number lower bound. + * + * @return the acknowledgementControlNumberLowerBound value + */ + public int acknowledgementControlNumberLowerBound() { + return this.acknowledgementControlNumberLowerBound; + } + + /** + * Set the acknowledgement control number lower bound. + * + * @param acknowledgementControlNumberLowerBound the acknowledgementControlNumberLowerBound value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withAcknowledgementControlNumberLowerBound(int acknowledgementControlNumberLowerBound) { + this.acknowledgementControlNumberLowerBound = acknowledgementControlNumberLowerBound; + return this; + } + + /** + * Get the acknowledgement control number upper bound. + * + * @return the acknowledgementControlNumberUpperBound value + */ + public int acknowledgementControlNumberUpperBound() { + return this.acknowledgementControlNumberUpperBound; + } + + /** + * Set the acknowledgement control number upper bound. + * + * @param acknowledgementControlNumberUpperBound the acknowledgementControlNumberUpperBound value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withAcknowledgementControlNumberUpperBound(int acknowledgementControlNumberUpperBound) { + this.acknowledgementControlNumberUpperBound = acknowledgementControlNumberUpperBound; + return this; + } + + /** + * Get the value indicating whether to rollover acknowledgement control number. + * + * @return the rolloverAcknowledgementControlNumber value + */ + public boolean rolloverAcknowledgementControlNumber() { + return this.rolloverAcknowledgementControlNumber; + } + + /** + * Set the value indicating whether to rollover acknowledgement control number. + * + * @param rolloverAcknowledgementControlNumber the rolloverAcknowledgementControlNumber value to set + * @return the X12AcknowledgementSettings object itself. + */ + public X12AcknowledgementSettings withRolloverAcknowledgementControlNumber(boolean rolloverAcknowledgementControlNumber) { + this.rolloverAcknowledgementControlNumber = rolloverAcknowledgementControlNumber; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12AgreementContent.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12AgreementContent.java new file mode 100644 index 000000000000..a893e89cac4b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12AgreementContent.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 agreement content. + */ +public class X12AgreementContent { + /** + * The X12 one-way receive agreement. + */ + @JsonProperty(value = "receiveAgreement", required = true) + private X12OneWayAgreement receiveAgreement; + + /** + * The X12 one-way send agreement. + */ + @JsonProperty(value = "sendAgreement", required = true) + private X12OneWayAgreement sendAgreement; + + /** + * Get the X12 one-way receive agreement. + * + * @return the receiveAgreement value + */ + public X12OneWayAgreement receiveAgreement() { + return this.receiveAgreement; + } + + /** + * Set the X12 one-way receive agreement. + * + * @param receiveAgreement the receiveAgreement value to set + * @return the X12AgreementContent object itself. + */ + public X12AgreementContent withReceiveAgreement(X12OneWayAgreement receiveAgreement) { + this.receiveAgreement = receiveAgreement; + return this; + } + + /** + * Get the X12 one-way send agreement. + * + * @return the sendAgreement value + */ + public X12OneWayAgreement sendAgreement() { + return this.sendAgreement; + } + + /** + * Set the X12 one-way send agreement. + * + * @param sendAgreement the sendAgreement value to set + * @return the X12AgreementContent object itself. + */ + public X12AgreementContent withSendAgreement(X12OneWayAgreement sendAgreement) { + this.sendAgreement = sendAgreement; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12CharacterSet.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12CharacterSet.java new file mode 100644 index 000000000000..4e338a0464f5 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12CharacterSet.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for X12CharacterSet. + */ +public final class X12CharacterSet extends ExpandableStringEnum { + /** Static value NotSpecified for X12CharacterSet. */ + public static final X12CharacterSet NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Basic for X12CharacterSet. */ + public static final X12CharacterSet BASIC = fromString("Basic"); + + /** Static value Extended for X12CharacterSet. */ + public static final X12CharacterSet EXTENDED = fromString("Extended"); + + /** Static value UTF8 for X12CharacterSet. */ + public static final X12CharacterSet UTF8 = fromString("UTF8"); + + /** + * Creates or finds a X12CharacterSet from its string representation. + * @param name a name to look for + * @return the corresponding X12CharacterSet + */ + @JsonCreator + public static X12CharacterSet fromString(String name) { + return fromString(name, X12CharacterSet.class); + } + + /** + * @return known X12CharacterSet values + */ + public static Collection values() { + return values(X12CharacterSet.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12DateFormat.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12DateFormat.java new file mode 100644 index 000000000000..fed32d66fa66 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12DateFormat.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for X12DateFormat. + */ +public final class X12DateFormat extends ExpandableStringEnum { + /** Static value NotSpecified for X12DateFormat. */ + public static final X12DateFormat NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value CCYYMMDD for X12DateFormat. */ + public static final X12DateFormat CCYYMMDD = fromString("CCYYMMDD"); + + /** Static value YYMMDD for X12DateFormat. */ + public static final X12DateFormat YYMMDD = fromString("YYMMDD"); + + /** + * Creates or finds a X12DateFormat from its string representation. + * @param name a name to look for + * @return the corresponding X12DateFormat + */ + @JsonCreator + public static X12DateFormat fromString(String name) { + return fromString(name, X12DateFormat.class); + } + + /** + * @return known X12DateFormat values + */ + public static Collection values() { + return values(X12DateFormat.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12DelimiterOverrides.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12DelimiterOverrides.java new file mode 100644 index 000000000000..9381288cea31 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12DelimiterOverrides.java @@ -0,0 +1,252 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 delimiter override settings. + */ +public class X12DelimiterOverrides { + /** + * The protocol version. + */ + @JsonProperty(value = "protocolVersion") + private String protocolVersion; + + /** + * The message id. + */ + @JsonProperty(value = "messageId") + private String messageId; + + /** + * The data element separator. + */ + @JsonProperty(value = "dataElementSeparator", required = true) + private int dataElementSeparator; + + /** + * The component separator. + */ + @JsonProperty(value = "componentSeparator", required = true) + private int componentSeparator; + + /** + * The segment terminator. + */ + @JsonProperty(value = "segmentTerminator", required = true) + private int segmentTerminator; + + /** + * The segment terminator suffix. Possible values include: 'NotSpecified', + * 'None', 'CR', 'LF', 'CRLF'. + */ + @JsonProperty(value = "segmentTerminatorSuffix", required = true) + private SegmentTerminatorSuffix segmentTerminatorSuffix; + + /** + * The replacement character. + */ + @JsonProperty(value = "replaceCharacter", required = true) + private int replaceCharacter; + + /** + * The value indicating whether to replace separators in payload. + */ + @JsonProperty(value = "replaceSeparatorsInPayload", required = true) + private boolean replaceSeparatorsInPayload; + + /** + * The target namespace on which this delimiter settings has to be applied. + */ + @JsonProperty(value = "targetNamespace") + private String targetNamespace; + + /** + * Get the protocol version. + * + * @return the protocolVersion value + */ + public String protocolVersion() { + return this.protocolVersion; + } + + /** + * Set the protocol version. + * + * @param protocolVersion the protocolVersion value to set + * @return the X12DelimiterOverrides object itself. + */ + public X12DelimiterOverrides withProtocolVersion(String protocolVersion) { + this.protocolVersion = protocolVersion; + return this; + } + + /** + * Get the message id. + * + * @return the messageId value + */ + public String messageId() { + return this.messageId; + } + + /** + * Set the message id. + * + * @param messageId the messageId value to set + * @return the X12DelimiterOverrides object itself. + */ + public X12DelimiterOverrides withMessageId(String messageId) { + this.messageId = messageId; + return this; + } + + /** + * Get the data element separator. + * + * @return the dataElementSeparator value + */ + public int dataElementSeparator() { + return this.dataElementSeparator; + } + + /** + * Set the data element separator. + * + * @param dataElementSeparator the dataElementSeparator value to set + * @return the X12DelimiterOverrides object itself. + */ + public X12DelimiterOverrides withDataElementSeparator(int dataElementSeparator) { + this.dataElementSeparator = dataElementSeparator; + return this; + } + + /** + * Get the component separator. + * + * @return the componentSeparator value + */ + public int componentSeparator() { + return this.componentSeparator; + } + + /** + * Set the component separator. + * + * @param componentSeparator the componentSeparator value to set + * @return the X12DelimiterOverrides object itself. + */ + public X12DelimiterOverrides withComponentSeparator(int componentSeparator) { + this.componentSeparator = componentSeparator; + return this; + } + + /** + * Get the segment terminator. + * + * @return the segmentTerminator value + */ + public int segmentTerminator() { + return this.segmentTerminator; + } + + /** + * Set the segment terminator. + * + * @param segmentTerminator the segmentTerminator value to set + * @return the X12DelimiterOverrides object itself. + */ + public X12DelimiterOverrides withSegmentTerminator(int segmentTerminator) { + this.segmentTerminator = segmentTerminator; + return this; + } + + /** + * Get the segment terminator suffix. Possible values include: 'NotSpecified', 'None', 'CR', 'LF', 'CRLF'. + * + * @return the segmentTerminatorSuffix value + */ + public SegmentTerminatorSuffix segmentTerminatorSuffix() { + return this.segmentTerminatorSuffix; + } + + /** + * Set the segment terminator suffix. Possible values include: 'NotSpecified', 'None', 'CR', 'LF', 'CRLF'. + * + * @param segmentTerminatorSuffix the segmentTerminatorSuffix value to set + * @return the X12DelimiterOverrides object itself. + */ + public X12DelimiterOverrides withSegmentTerminatorSuffix(SegmentTerminatorSuffix segmentTerminatorSuffix) { + this.segmentTerminatorSuffix = segmentTerminatorSuffix; + return this; + } + + /** + * Get the replacement character. + * + * @return the replaceCharacter value + */ + public int replaceCharacter() { + return this.replaceCharacter; + } + + /** + * Set the replacement character. + * + * @param replaceCharacter the replaceCharacter value to set + * @return the X12DelimiterOverrides object itself. + */ + public X12DelimiterOverrides withReplaceCharacter(int replaceCharacter) { + this.replaceCharacter = replaceCharacter; + return this; + } + + /** + * Get the value indicating whether to replace separators in payload. + * + * @return the replaceSeparatorsInPayload value + */ + public boolean replaceSeparatorsInPayload() { + return this.replaceSeparatorsInPayload; + } + + /** + * Set the value indicating whether to replace separators in payload. + * + * @param replaceSeparatorsInPayload the replaceSeparatorsInPayload value to set + * @return the X12DelimiterOverrides object itself. + */ + public X12DelimiterOverrides withReplaceSeparatorsInPayload(boolean replaceSeparatorsInPayload) { + this.replaceSeparatorsInPayload = replaceSeparatorsInPayload; + return this; + } + + /** + * Get the target namespace on which this delimiter settings has to be applied. + * + * @return the targetNamespace value + */ + public String targetNamespace() { + return this.targetNamespace; + } + + /** + * Set the target namespace on which this delimiter settings has to be applied. + * + * @param targetNamespace the targetNamespace value to set + * @return the X12DelimiterOverrides object itself. + */ + public X12DelimiterOverrides withTargetNamespace(String targetNamespace) { + this.targetNamespace = targetNamespace; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12EnvelopeOverride.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12EnvelopeOverride.java new file mode 100644 index 000000000000..cc630901ba77 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12EnvelopeOverride.java @@ -0,0 +1,279 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 envelope override settings. + */ +public class X12EnvelopeOverride { + /** + * The target namespace on which this envelope settings has to be applied. + */ + @JsonProperty(value = "targetNamespace", required = true) + private String targetNamespace; + + /** + * The protocol version on which this envelope settings has to be applied. + */ + @JsonProperty(value = "protocolVersion", required = true) + private String protocolVersion; + + /** + * The message id on which this envelope settings has to be applied. + */ + @JsonProperty(value = "messageId", required = true) + private String messageId; + + /** + * The responsible agency code. + */ + @JsonProperty(value = "responsibleAgencyCode", required = true) + private String responsibleAgencyCode; + + /** + * The header version. + */ + @JsonProperty(value = "headerVersion", required = true) + private String headerVersion; + + /** + * The sender application id. + */ + @JsonProperty(value = "senderApplicationId", required = true) + private String senderApplicationId; + + /** + * The receiver application id. + */ + @JsonProperty(value = "receiverApplicationId", required = true) + private String receiverApplicationId; + + /** + * The functional identifier code. + */ + @JsonProperty(value = "functionalIdentifierCode") + private String functionalIdentifierCode; + + /** + * The date format. Possible values include: 'NotSpecified', 'CCYYMMDD', + * 'YYMMDD'. + */ + @JsonProperty(value = "dateFormat", required = true) + private X12DateFormat dateFormat; + + /** + * The time format. Possible values include: 'NotSpecified', 'HHMM', + * 'HHMMSS', 'HHMMSSdd', 'HHMMSSd'. + */ + @JsonProperty(value = "timeFormat", required = true) + private X12TimeFormat timeFormat; + + /** + * Get the target namespace on which this envelope settings has to be applied. + * + * @return the targetNamespace value + */ + public String targetNamespace() { + return this.targetNamespace; + } + + /** + * Set the target namespace on which this envelope settings has to be applied. + * + * @param targetNamespace the targetNamespace value to set + * @return the X12EnvelopeOverride object itself. + */ + public X12EnvelopeOverride withTargetNamespace(String targetNamespace) { + this.targetNamespace = targetNamespace; + return this; + } + + /** + * Get the protocol version on which this envelope settings has to be applied. + * + * @return the protocolVersion value + */ + public String protocolVersion() { + return this.protocolVersion; + } + + /** + * Set the protocol version on which this envelope settings has to be applied. + * + * @param protocolVersion the protocolVersion value to set + * @return the X12EnvelopeOverride object itself. + */ + public X12EnvelopeOverride withProtocolVersion(String protocolVersion) { + this.protocolVersion = protocolVersion; + return this; + } + + /** + * Get the message id on which this envelope settings has to be applied. + * + * @return the messageId value + */ + public String messageId() { + return this.messageId; + } + + /** + * Set the message id on which this envelope settings has to be applied. + * + * @param messageId the messageId value to set + * @return the X12EnvelopeOverride object itself. + */ + public X12EnvelopeOverride withMessageId(String messageId) { + this.messageId = messageId; + return this; + } + + /** + * Get the responsible agency code. + * + * @return the responsibleAgencyCode value + */ + public String responsibleAgencyCode() { + return this.responsibleAgencyCode; + } + + /** + * Set the responsible agency code. + * + * @param responsibleAgencyCode the responsibleAgencyCode value to set + * @return the X12EnvelopeOverride object itself. + */ + public X12EnvelopeOverride withResponsibleAgencyCode(String responsibleAgencyCode) { + this.responsibleAgencyCode = responsibleAgencyCode; + return this; + } + + /** + * Get the header version. + * + * @return the headerVersion value + */ + public String headerVersion() { + return this.headerVersion; + } + + /** + * Set the header version. + * + * @param headerVersion the headerVersion value to set + * @return the X12EnvelopeOverride object itself. + */ + public X12EnvelopeOverride withHeaderVersion(String headerVersion) { + this.headerVersion = headerVersion; + return this; + } + + /** + * Get the sender application id. + * + * @return the senderApplicationId value + */ + public String senderApplicationId() { + return this.senderApplicationId; + } + + /** + * Set the sender application id. + * + * @param senderApplicationId the senderApplicationId value to set + * @return the X12EnvelopeOverride object itself. + */ + public X12EnvelopeOverride withSenderApplicationId(String senderApplicationId) { + this.senderApplicationId = senderApplicationId; + return this; + } + + /** + * Get the receiver application id. + * + * @return the receiverApplicationId value + */ + public String receiverApplicationId() { + return this.receiverApplicationId; + } + + /** + * Set the receiver application id. + * + * @param receiverApplicationId the receiverApplicationId value to set + * @return the X12EnvelopeOverride object itself. + */ + public X12EnvelopeOverride withReceiverApplicationId(String receiverApplicationId) { + this.receiverApplicationId = receiverApplicationId; + return this; + } + + /** + * Get the functional identifier code. + * + * @return the functionalIdentifierCode value + */ + public String functionalIdentifierCode() { + return this.functionalIdentifierCode; + } + + /** + * Set the functional identifier code. + * + * @param functionalIdentifierCode the functionalIdentifierCode value to set + * @return the X12EnvelopeOverride object itself. + */ + public X12EnvelopeOverride withFunctionalIdentifierCode(String functionalIdentifierCode) { + this.functionalIdentifierCode = functionalIdentifierCode; + return this; + } + + /** + * Get the date format. Possible values include: 'NotSpecified', 'CCYYMMDD', 'YYMMDD'. + * + * @return the dateFormat value + */ + public X12DateFormat dateFormat() { + return this.dateFormat; + } + + /** + * Set the date format. Possible values include: 'NotSpecified', 'CCYYMMDD', 'YYMMDD'. + * + * @param dateFormat the dateFormat value to set + * @return the X12EnvelopeOverride object itself. + */ + public X12EnvelopeOverride withDateFormat(X12DateFormat dateFormat) { + this.dateFormat = dateFormat; + return this; + } + + /** + * Get the time format. Possible values include: 'NotSpecified', 'HHMM', 'HHMMSS', 'HHMMSSdd', 'HHMMSSd'. + * + * @return the timeFormat value + */ + public X12TimeFormat timeFormat() { + return this.timeFormat; + } + + /** + * Set the time format. Possible values include: 'NotSpecified', 'HHMM', 'HHMMSS', 'HHMMSSdd', 'HHMMSSd'. + * + * @param timeFormat the timeFormat value to set + * @return the X12EnvelopeOverride object itself. + */ + public X12EnvelopeOverride withTimeFormat(X12TimeFormat timeFormat) { + this.timeFormat = timeFormat; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12EnvelopeSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12EnvelopeSettings.java new file mode 100644 index 000000000000..c8eb1f6d7490 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12EnvelopeSettings.java @@ -0,0 +1,646 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 agreement envelope settings. + */ +public class X12EnvelopeSettings { + /** + * The controls standards id. + */ + @JsonProperty(value = "controlStandardsId", required = true) + private int controlStandardsId; + + /** + * The value indicating whether to use control standards id as repetition + * character. + */ + @JsonProperty(value = "useControlStandardsIdAsRepetitionCharacter", required = true) + private boolean useControlStandardsIdAsRepetitionCharacter; + + /** + * The sender application id. + */ + @JsonProperty(value = "senderApplicationId", required = true) + private String senderApplicationId; + + /** + * The receiver application id. + */ + @JsonProperty(value = "receiverApplicationId", required = true) + private String receiverApplicationId; + + /** + * The control version number. + */ + @JsonProperty(value = "controlVersionNumber", required = true) + private String controlVersionNumber; + + /** + * The interchange control number lower bound. + */ + @JsonProperty(value = "interchangeControlNumberLowerBound", required = true) + private int interchangeControlNumberLowerBound; + + /** + * The interchange control number upper bound. + */ + @JsonProperty(value = "interchangeControlNumberUpperBound", required = true) + private int interchangeControlNumberUpperBound; + + /** + * The value indicating whether to rollover interchange control number. + */ + @JsonProperty(value = "rolloverInterchangeControlNumber", required = true) + private boolean rolloverInterchangeControlNumber; + + /** + * The value indicating whether to enable default group headers. + */ + @JsonProperty(value = "enableDefaultGroupHeaders", required = true) + private boolean enableDefaultGroupHeaders; + + /** + * The functional group id. + */ + @JsonProperty(value = "functionalGroupId") + private String functionalGroupId; + + /** + * The group control number lower bound. + */ + @JsonProperty(value = "groupControlNumberLowerBound", required = true) + private int groupControlNumberLowerBound; + + /** + * The group control number upper bound. + */ + @JsonProperty(value = "groupControlNumberUpperBound", required = true) + private int groupControlNumberUpperBound; + + /** + * The value indicating whether to rollover group control number. + */ + @JsonProperty(value = "rolloverGroupControlNumber", required = true) + private boolean rolloverGroupControlNumber; + + /** + * The group header agency code. + */ + @JsonProperty(value = "groupHeaderAgencyCode", required = true) + private String groupHeaderAgencyCode; + + /** + * The group header version. + */ + @JsonProperty(value = "groupHeaderVersion", required = true) + private String groupHeaderVersion; + + /** + * The transaction set control number lower bound. + */ + @JsonProperty(value = "transactionSetControlNumberLowerBound", required = true) + private int transactionSetControlNumberLowerBound; + + /** + * The transaction set control number upper bound. + */ + @JsonProperty(value = "transactionSetControlNumberUpperBound", required = true) + private int transactionSetControlNumberUpperBound; + + /** + * The value indicating whether to rollover transaction set control number. + */ + @JsonProperty(value = "rolloverTransactionSetControlNumber", required = true) + private boolean rolloverTransactionSetControlNumber; + + /** + * The transaction set control number prefix. + */ + @JsonProperty(value = "transactionSetControlNumberPrefix") + private String transactionSetControlNumberPrefix; + + /** + * The transaction set control number suffix. + */ + @JsonProperty(value = "transactionSetControlNumberSuffix") + private String transactionSetControlNumberSuffix; + + /** + * The value indicating whether to overwrite existing transaction set + * control number. + */ + @JsonProperty(value = "overwriteExistingTransactionSetControlNumber", required = true) + private boolean overwriteExistingTransactionSetControlNumber; + + /** + * The group header date format. Possible values include: 'NotSpecified', + * 'CCYYMMDD', 'YYMMDD'. + */ + @JsonProperty(value = "groupHeaderDateFormat", required = true) + private X12DateFormat groupHeaderDateFormat; + + /** + * The group header time format. Possible values include: 'NotSpecified', + * 'HHMM', 'HHMMSS', 'HHMMSSdd', 'HHMMSSd'. + */ + @JsonProperty(value = "groupHeaderTimeFormat", required = true) + private X12TimeFormat groupHeaderTimeFormat; + + /** + * The usage indicator. Possible values include: 'NotSpecified', 'Test', + * 'Information', 'Production'. + */ + @JsonProperty(value = "usageIndicator", required = true) + private UsageIndicator usageIndicator; + + /** + * Get the controls standards id. + * + * @return the controlStandardsId value + */ + public int controlStandardsId() { + return this.controlStandardsId; + } + + /** + * Set the controls standards id. + * + * @param controlStandardsId the controlStandardsId value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withControlStandardsId(int controlStandardsId) { + this.controlStandardsId = controlStandardsId; + return this; + } + + /** + * Get the value indicating whether to use control standards id as repetition character. + * + * @return the useControlStandardsIdAsRepetitionCharacter value + */ + public boolean useControlStandardsIdAsRepetitionCharacter() { + return this.useControlStandardsIdAsRepetitionCharacter; + } + + /** + * Set the value indicating whether to use control standards id as repetition character. + * + * @param useControlStandardsIdAsRepetitionCharacter the useControlStandardsIdAsRepetitionCharacter value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withUseControlStandardsIdAsRepetitionCharacter(boolean useControlStandardsIdAsRepetitionCharacter) { + this.useControlStandardsIdAsRepetitionCharacter = useControlStandardsIdAsRepetitionCharacter; + return this; + } + + /** + * Get the sender application id. + * + * @return the senderApplicationId value + */ + public String senderApplicationId() { + return this.senderApplicationId; + } + + /** + * Set the sender application id. + * + * @param senderApplicationId the senderApplicationId value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withSenderApplicationId(String senderApplicationId) { + this.senderApplicationId = senderApplicationId; + return this; + } + + /** + * Get the receiver application id. + * + * @return the receiverApplicationId value + */ + public String receiverApplicationId() { + return this.receiverApplicationId; + } + + /** + * Set the receiver application id. + * + * @param receiverApplicationId the receiverApplicationId value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withReceiverApplicationId(String receiverApplicationId) { + this.receiverApplicationId = receiverApplicationId; + return this; + } + + /** + * Get the control version number. + * + * @return the controlVersionNumber value + */ + public String controlVersionNumber() { + return this.controlVersionNumber; + } + + /** + * Set the control version number. + * + * @param controlVersionNumber the controlVersionNumber value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withControlVersionNumber(String controlVersionNumber) { + this.controlVersionNumber = controlVersionNumber; + return this; + } + + /** + * Get the interchange control number lower bound. + * + * @return the interchangeControlNumberLowerBound value + */ + public int interchangeControlNumberLowerBound() { + return this.interchangeControlNumberLowerBound; + } + + /** + * Set the interchange control number lower bound. + * + * @param interchangeControlNumberLowerBound the interchangeControlNumberLowerBound value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withInterchangeControlNumberLowerBound(int interchangeControlNumberLowerBound) { + this.interchangeControlNumberLowerBound = interchangeControlNumberLowerBound; + return this; + } + + /** + * Get the interchange control number upper bound. + * + * @return the interchangeControlNumberUpperBound value + */ + public int interchangeControlNumberUpperBound() { + return this.interchangeControlNumberUpperBound; + } + + /** + * Set the interchange control number upper bound. + * + * @param interchangeControlNumberUpperBound the interchangeControlNumberUpperBound value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withInterchangeControlNumberUpperBound(int interchangeControlNumberUpperBound) { + this.interchangeControlNumberUpperBound = interchangeControlNumberUpperBound; + return this; + } + + /** + * Get the value indicating whether to rollover interchange control number. + * + * @return the rolloverInterchangeControlNumber value + */ + public boolean rolloverInterchangeControlNumber() { + return this.rolloverInterchangeControlNumber; + } + + /** + * Set the value indicating whether to rollover interchange control number. + * + * @param rolloverInterchangeControlNumber the rolloverInterchangeControlNumber value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withRolloverInterchangeControlNumber(boolean rolloverInterchangeControlNumber) { + this.rolloverInterchangeControlNumber = rolloverInterchangeControlNumber; + return this; + } + + /** + * Get the value indicating whether to enable default group headers. + * + * @return the enableDefaultGroupHeaders value + */ + public boolean enableDefaultGroupHeaders() { + return this.enableDefaultGroupHeaders; + } + + /** + * Set the value indicating whether to enable default group headers. + * + * @param enableDefaultGroupHeaders the enableDefaultGroupHeaders value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withEnableDefaultGroupHeaders(boolean enableDefaultGroupHeaders) { + this.enableDefaultGroupHeaders = enableDefaultGroupHeaders; + return this; + } + + /** + * Get the functional group id. + * + * @return the functionalGroupId value + */ + public String functionalGroupId() { + return this.functionalGroupId; + } + + /** + * Set the functional group id. + * + * @param functionalGroupId the functionalGroupId value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withFunctionalGroupId(String functionalGroupId) { + this.functionalGroupId = functionalGroupId; + return this; + } + + /** + * Get the group control number lower bound. + * + * @return the groupControlNumberLowerBound value + */ + public int groupControlNumberLowerBound() { + return this.groupControlNumberLowerBound; + } + + /** + * Set the group control number lower bound. + * + * @param groupControlNumberLowerBound the groupControlNumberLowerBound value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withGroupControlNumberLowerBound(int groupControlNumberLowerBound) { + this.groupControlNumberLowerBound = groupControlNumberLowerBound; + return this; + } + + /** + * Get the group control number upper bound. + * + * @return the groupControlNumberUpperBound value + */ + public int groupControlNumberUpperBound() { + return this.groupControlNumberUpperBound; + } + + /** + * Set the group control number upper bound. + * + * @param groupControlNumberUpperBound the groupControlNumberUpperBound value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withGroupControlNumberUpperBound(int groupControlNumberUpperBound) { + this.groupControlNumberUpperBound = groupControlNumberUpperBound; + return this; + } + + /** + * Get the value indicating whether to rollover group control number. + * + * @return the rolloverGroupControlNumber value + */ + public boolean rolloverGroupControlNumber() { + return this.rolloverGroupControlNumber; + } + + /** + * Set the value indicating whether to rollover group control number. + * + * @param rolloverGroupControlNumber the rolloverGroupControlNumber value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withRolloverGroupControlNumber(boolean rolloverGroupControlNumber) { + this.rolloverGroupControlNumber = rolloverGroupControlNumber; + return this; + } + + /** + * Get the group header agency code. + * + * @return the groupHeaderAgencyCode value + */ + public String groupHeaderAgencyCode() { + return this.groupHeaderAgencyCode; + } + + /** + * Set the group header agency code. + * + * @param groupHeaderAgencyCode the groupHeaderAgencyCode value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withGroupHeaderAgencyCode(String groupHeaderAgencyCode) { + this.groupHeaderAgencyCode = groupHeaderAgencyCode; + return this; + } + + /** + * Get the group header version. + * + * @return the groupHeaderVersion value + */ + public String groupHeaderVersion() { + return this.groupHeaderVersion; + } + + /** + * Set the group header version. + * + * @param groupHeaderVersion the groupHeaderVersion value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withGroupHeaderVersion(String groupHeaderVersion) { + this.groupHeaderVersion = groupHeaderVersion; + return this; + } + + /** + * Get the transaction set control number lower bound. + * + * @return the transactionSetControlNumberLowerBound value + */ + public int transactionSetControlNumberLowerBound() { + return this.transactionSetControlNumberLowerBound; + } + + /** + * Set the transaction set control number lower bound. + * + * @param transactionSetControlNumberLowerBound the transactionSetControlNumberLowerBound value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withTransactionSetControlNumberLowerBound(int transactionSetControlNumberLowerBound) { + this.transactionSetControlNumberLowerBound = transactionSetControlNumberLowerBound; + return this; + } + + /** + * Get the transaction set control number upper bound. + * + * @return the transactionSetControlNumberUpperBound value + */ + public int transactionSetControlNumberUpperBound() { + return this.transactionSetControlNumberUpperBound; + } + + /** + * Set the transaction set control number upper bound. + * + * @param transactionSetControlNumberUpperBound the transactionSetControlNumberUpperBound value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withTransactionSetControlNumberUpperBound(int transactionSetControlNumberUpperBound) { + this.transactionSetControlNumberUpperBound = transactionSetControlNumberUpperBound; + return this; + } + + /** + * Get the value indicating whether to rollover transaction set control number. + * + * @return the rolloverTransactionSetControlNumber value + */ + public boolean rolloverTransactionSetControlNumber() { + return this.rolloverTransactionSetControlNumber; + } + + /** + * Set the value indicating whether to rollover transaction set control number. + * + * @param rolloverTransactionSetControlNumber the rolloverTransactionSetControlNumber value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withRolloverTransactionSetControlNumber(boolean rolloverTransactionSetControlNumber) { + this.rolloverTransactionSetControlNumber = rolloverTransactionSetControlNumber; + return this; + } + + /** + * Get the transaction set control number prefix. + * + * @return the transactionSetControlNumberPrefix value + */ + public String transactionSetControlNumberPrefix() { + return this.transactionSetControlNumberPrefix; + } + + /** + * Set the transaction set control number prefix. + * + * @param transactionSetControlNumberPrefix the transactionSetControlNumberPrefix value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withTransactionSetControlNumberPrefix(String transactionSetControlNumberPrefix) { + this.transactionSetControlNumberPrefix = transactionSetControlNumberPrefix; + return this; + } + + /** + * Get the transaction set control number suffix. + * + * @return the transactionSetControlNumberSuffix value + */ + public String transactionSetControlNumberSuffix() { + return this.transactionSetControlNumberSuffix; + } + + /** + * Set the transaction set control number suffix. + * + * @param transactionSetControlNumberSuffix the transactionSetControlNumberSuffix value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withTransactionSetControlNumberSuffix(String transactionSetControlNumberSuffix) { + this.transactionSetControlNumberSuffix = transactionSetControlNumberSuffix; + return this; + } + + /** + * Get the value indicating whether to overwrite existing transaction set control number. + * + * @return the overwriteExistingTransactionSetControlNumber value + */ + public boolean overwriteExistingTransactionSetControlNumber() { + return this.overwriteExistingTransactionSetControlNumber; + } + + /** + * Set the value indicating whether to overwrite existing transaction set control number. + * + * @param overwriteExistingTransactionSetControlNumber the overwriteExistingTransactionSetControlNumber value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withOverwriteExistingTransactionSetControlNumber(boolean overwriteExistingTransactionSetControlNumber) { + this.overwriteExistingTransactionSetControlNumber = overwriteExistingTransactionSetControlNumber; + return this; + } + + /** + * Get the group header date format. Possible values include: 'NotSpecified', 'CCYYMMDD', 'YYMMDD'. + * + * @return the groupHeaderDateFormat value + */ + public X12DateFormat groupHeaderDateFormat() { + return this.groupHeaderDateFormat; + } + + /** + * Set the group header date format. Possible values include: 'NotSpecified', 'CCYYMMDD', 'YYMMDD'. + * + * @param groupHeaderDateFormat the groupHeaderDateFormat value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withGroupHeaderDateFormat(X12DateFormat groupHeaderDateFormat) { + this.groupHeaderDateFormat = groupHeaderDateFormat; + return this; + } + + /** + * Get the group header time format. Possible values include: 'NotSpecified', 'HHMM', 'HHMMSS', 'HHMMSSdd', 'HHMMSSd'. + * + * @return the groupHeaderTimeFormat value + */ + public X12TimeFormat groupHeaderTimeFormat() { + return this.groupHeaderTimeFormat; + } + + /** + * Set the group header time format. Possible values include: 'NotSpecified', 'HHMM', 'HHMMSS', 'HHMMSSdd', 'HHMMSSd'. + * + * @param groupHeaderTimeFormat the groupHeaderTimeFormat value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withGroupHeaderTimeFormat(X12TimeFormat groupHeaderTimeFormat) { + this.groupHeaderTimeFormat = groupHeaderTimeFormat; + return this; + } + + /** + * Get the usage indicator. Possible values include: 'NotSpecified', 'Test', 'Information', 'Production'. + * + * @return the usageIndicator value + */ + public UsageIndicator usageIndicator() { + return this.usageIndicator; + } + + /** + * Set the usage indicator. Possible values include: 'NotSpecified', 'Test', 'Information', 'Production'. + * + * @param usageIndicator the usageIndicator value to set + * @return the X12EnvelopeSettings object itself. + */ + public X12EnvelopeSettings withUsageIndicator(UsageIndicator usageIndicator) { + this.usageIndicator = usageIndicator; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12FramingSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12FramingSettings.java new file mode 100644 index 000000000000..c32e22b5fc05 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12FramingSettings.java @@ -0,0 +1,201 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 agreement framing settings. + */ +public class X12FramingSettings { + /** + * The data element separator. + */ + @JsonProperty(value = "dataElementSeparator", required = true) + private int dataElementSeparator; + + /** + * The component separator. + */ + @JsonProperty(value = "componentSeparator", required = true) + private int componentSeparator; + + /** + * The value indicating whether to replace separators in payload. + */ + @JsonProperty(value = "replaceSeparatorsInPayload", required = true) + private boolean replaceSeparatorsInPayload; + + /** + * The replacement character. + */ + @JsonProperty(value = "replaceCharacter", required = true) + private int replaceCharacter; + + /** + * The segment terminator. + */ + @JsonProperty(value = "segmentTerminator", required = true) + private int segmentTerminator; + + /** + * The X12 character set. Possible values include: 'NotSpecified', 'Basic', + * 'Extended', 'UTF8'. + */ + @JsonProperty(value = "characterSet", required = true) + private X12CharacterSet characterSet; + + /** + * The segment terminator suffix. Possible values include: 'NotSpecified', + * 'None', 'CR', 'LF', 'CRLF'. + */ + @JsonProperty(value = "segmentTerminatorSuffix", required = true) + private SegmentTerminatorSuffix segmentTerminatorSuffix; + + /** + * Get the data element separator. + * + * @return the dataElementSeparator value + */ + public int dataElementSeparator() { + return this.dataElementSeparator; + } + + /** + * Set the data element separator. + * + * @param dataElementSeparator the dataElementSeparator value to set + * @return the X12FramingSettings object itself. + */ + public X12FramingSettings withDataElementSeparator(int dataElementSeparator) { + this.dataElementSeparator = dataElementSeparator; + return this; + } + + /** + * Get the component separator. + * + * @return the componentSeparator value + */ + public int componentSeparator() { + return this.componentSeparator; + } + + /** + * Set the component separator. + * + * @param componentSeparator the componentSeparator value to set + * @return the X12FramingSettings object itself. + */ + public X12FramingSettings withComponentSeparator(int componentSeparator) { + this.componentSeparator = componentSeparator; + return this; + } + + /** + * Get the value indicating whether to replace separators in payload. + * + * @return the replaceSeparatorsInPayload value + */ + public boolean replaceSeparatorsInPayload() { + return this.replaceSeparatorsInPayload; + } + + /** + * Set the value indicating whether to replace separators in payload. + * + * @param replaceSeparatorsInPayload the replaceSeparatorsInPayload value to set + * @return the X12FramingSettings object itself. + */ + public X12FramingSettings withReplaceSeparatorsInPayload(boolean replaceSeparatorsInPayload) { + this.replaceSeparatorsInPayload = replaceSeparatorsInPayload; + return this; + } + + /** + * Get the replacement character. + * + * @return the replaceCharacter value + */ + public int replaceCharacter() { + return this.replaceCharacter; + } + + /** + * Set the replacement character. + * + * @param replaceCharacter the replaceCharacter value to set + * @return the X12FramingSettings object itself. + */ + public X12FramingSettings withReplaceCharacter(int replaceCharacter) { + this.replaceCharacter = replaceCharacter; + return this; + } + + /** + * Get the segment terminator. + * + * @return the segmentTerminator value + */ + public int segmentTerminator() { + return this.segmentTerminator; + } + + /** + * Set the segment terminator. + * + * @param segmentTerminator the segmentTerminator value to set + * @return the X12FramingSettings object itself. + */ + public X12FramingSettings withSegmentTerminator(int segmentTerminator) { + this.segmentTerminator = segmentTerminator; + return this; + } + + /** + * Get the X12 character set. Possible values include: 'NotSpecified', 'Basic', 'Extended', 'UTF8'. + * + * @return the characterSet value + */ + public X12CharacterSet characterSet() { + return this.characterSet; + } + + /** + * Set the X12 character set. Possible values include: 'NotSpecified', 'Basic', 'Extended', 'UTF8'. + * + * @param characterSet the characterSet value to set + * @return the X12FramingSettings object itself. + */ + public X12FramingSettings withCharacterSet(X12CharacterSet characterSet) { + this.characterSet = characterSet; + return this; + } + + /** + * Get the segment terminator suffix. Possible values include: 'NotSpecified', 'None', 'CR', 'LF', 'CRLF'. + * + * @return the segmentTerminatorSuffix value + */ + public SegmentTerminatorSuffix segmentTerminatorSuffix() { + return this.segmentTerminatorSuffix; + } + + /** + * Set the segment terminator suffix. Possible values include: 'NotSpecified', 'None', 'CR', 'LF', 'CRLF'. + * + * @param segmentTerminatorSuffix the segmentTerminatorSuffix value to set + * @return the X12FramingSettings object itself. + */ + public X12FramingSettings withSegmentTerminatorSuffix(SegmentTerminatorSuffix segmentTerminatorSuffix) { + this.segmentTerminatorSuffix = segmentTerminatorSuffix; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12MessageFilter.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12MessageFilter.java new file mode 100644 index 000000000000..afe6f7be0329 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12MessageFilter.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 message filter for odata query. + */ +public class X12MessageFilter { + /** + * The message filter type. Possible values include: 'NotSpecified', + * 'Include', 'Exclude'. + */ + @JsonProperty(value = "messageFilterType", required = true) + private MessageFilterType messageFilterType; + + /** + * Get the message filter type. Possible values include: 'NotSpecified', 'Include', 'Exclude'. + * + * @return the messageFilterType value + */ + public MessageFilterType messageFilterType() { + return this.messageFilterType; + } + + /** + * Set the message filter type. Possible values include: 'NotSpecified', 'Include', 'Exclude'. + * + * @param messageFilterType the messageFilterType value to set + * @return the X12MessageFilter object itself. + */ + public X12MessageFilter withMessageFilterType(MessageFilterType messageFilterType) { + this.messageFilterType = messageFilterType; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12MessageIdentifier.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12MessageIdentifier.java new file mode 100644 index 000000000000..4e924b918866 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12MessageIdentifier.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 message identifier. + */ +public class X12MessageIdentifier { + /** + * The message id. + */ + @JsonProperty(value = "messageId", required = true) + private String messageId; + + /** + * Get the message id. + * + * @return the messageId value + */ + public String messageId() { + return this.messageId; + } + + /** + * Set the message id. + * + * @param messageId the messageId value to set + * @return the X12MessageIdentifier object itself. + */ + public X12MessageIdentifier withMessageId(String messageId) { + this.messageId = messageId; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12OneWayAgreement.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12OneWayAgreement.java new file mode 100644 index 000000000000..26ad5af59d0f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12OneWayAgreement.java @@ -0,0 +1,95 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 one-way agreement. + */ +public class X12OneWayAgreement { + /** + * The sender business identity. + */ + @JsonProperty(value = "senderBusinessIdentity", required = true) + private BusinessIdentity senderBusinessIdentity; + + /** + * The receiver business identity. + */ + @JsonProperty(value = "receiverBusinessIdentity", required = true) + private BusinessIdentity receiverBusinessIdentity; + + /** + * The X12 protocol settings. + */ + @JsonProperty(value = "protocolSettings", required = true) + private X12ProtocolSettings protocolSettings; + + /** + * Get the sender business identity. + * + * @return the senderBusinessIdentity value + */ + public BusinessIdentity senderBusinessIdentity() { + return this.senderBusinessIdentity; + } + + /** + * Set the sender business identity. + * + * @param senderBusinessIdentity the senderBusinessIdentity value to set + * @return the X12OneWayAgreement object itself. + */ + public X12OneWayAgreement withSenderBusinessIdentity(BusinessIdentity senderBusinessIdentity) { + this.senderBusinessIdentity = senderBusinessIdentity; + return this; + } + + /** + * Get the receiver business identity. + * + * @return the receiverBusinessIdentity value + */ + public BusinessIdentity receiverBusinessIdentity() { + return this.receiverBusinessIdentity; + } + + /** + * Set the receiver business identity. + * + * @param receiverBusinessIdentity the receiverBusinessIdentity value to set + * @return the X12OneWayAgreement object itself. + */ + public X12OneWayAgreement withReceiverBusinessIdentity(BusinessIdentity receiverBusinessIdentity) { + this.receiverBusinessIdentity = receiverBusinessIdentity; + return this; + } + + /** + * Get the X12 protocol settings. + * + * @return the protocolSettings value + */ + public X12ProtocolSettings protocolSettings() { + return this.protocolSettings; + } + + /** + * Set the X12 protocol settings. + * + * @param protocolSettings the protocolSettings value to set + * @return the X12OneWayAgreement object itself. + */ + public X12OneWayAgreement withProtocolSettings(X12ProtocolSettings protocolSettings) { + this.protocolSettings = protocolSettings; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12ProcessingSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12ProcessingSettings.java new file mode 100644 index 000000000000..53a6806d57fd --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12ProcessingSettings.java @@ -0,0 +1,175 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 processing settings. + */ +public class X12ProcessingSettings { + /** + * The value indicating whether to mask security information. + */ + @JsonProperty(value = "maskSecurityInfo", required = true) + private boolean maskSecurityInfo; + + /** + * The value indicating whether to convert numerical type to implied + * decimal. + */ + @JsonProperty(value = "convertImpliedDecimal", required = true) + private boolean convertImpliedDecimal; + + /** + * The value indicating whether to preserve interchange. + */ + @JsonProperty(value = "preserveInterchange", required = true) + private boolean preserveInterchange; + + /** + * The value indicating whether to suspend interchange on error. + */ + @JsonProperty(value = "suspendInterchangeOnError", required = true) + private boolean suspendInterchangeOnError; + + /** + * The value indicating whether to create empty xml tags for trailing + * separators. + */ + @JsonProperty(value = "createEmptyXmlTagsForTrailingSeparators", required = true) + private boolean createEmptyXmlTagsForTrailingSeparators; + + /** + * The value indicating whether to use dot as decimal separator. + */ + @JsonProperty(value = "useDotAsDecimalSeparator", required = true) + private boolean useDotAsDecimalSeparator; + + /** + * Get the value indicating whether to mask security information. + * + * @return the maskSecurityInfo value + */ + public boolean maskSecurityInfo() { + return this.maskSecurityInfo; + } + + /** + * Set the value indicating whether to mask security information. + * + * @param maskSecurityInfo the maskSecurityInfo value to set + * @return the X12ProcessingSettings object itself. + */ + public X12ProcessingSettings withMaskSecurityInfo(boolean maskSecurityInfo) { + this.maskSecurityInfo = maskSecurityInfo; + return this; + } + + /** + * Get the value indicating whether to convert numerical type to implied decimal. + * + * @return the convertImpliedDecimal value + */ + public boolean convertImpliedDecimal() { + return this.convertImpliedDecimal; + } + + /** + * Set the value indicating whether to convert numerical type to implied decimal. + * + * @param convertImpliedDecimal the convertImpliedDecimal value to set + * @return the X12ProcessingSettings object itself. + */ + public X12ProcessingSettings withConvertImpliedDecimal(boolean convertImpliedDecimal) { + this.convertImpliedDecimal = convertImpliedDecimal; + return this; + } + + /** + * Get the value indicating whether to preserve interchange. + * + * @return the preserveInterchange value + */ + public boolean preserveInterchange() { + return this.preserveInterchange; + } + + /** + * Set the value indicating whether to preserve interchange. + * + * @param preserveInterchange the preserveInterchange value to set + * @return the X12ProcessingSettings object itself. + */ + public X12ProcessingSettings withPreserveInterchange(boolean preserveInterchange) { + this.preserveInterchange = preserveInterchange; + return this; + } + + /** + * Get the value indicating whether to suspend interchange on error. + * + * @return the suspendInterchangeOnError value + */ + public boolean suspendInterchangeOnError() { + return this.suspendInterchangeOnError; + } + + /** + * Set the value indicating whether to suspend interchange on error. + * + * @param suspendInterchangeOnError the suspendInterchangeOnError value to set + * @return the X12ProcessingSettings object itself. + */ + public X12ProcessingSettings withSuspendInterchangeOnError(boolean suspendInterchangeOnError) { + this.suspendInterchangeOnError = suspendInterchangeOnError; + return this; + } + + /** + * Get the value indicating whether to create empty xml tags for trailing separators. + * + * @return the createEmptyXmlTagsForTrailingSeparators value + */ + public boolean createEmptyXmlTagsForTrailingSeparators() { + return this.createEmptyXmlTagsForTrailingSeparators; + } + + /** + * Set the value indicating whether to create empty xml tags for trailing separators. + * + * @param createEmptyXmlTagsForTrailingSeparators the createEmptyXmlTagsForTrailingSeparators value to set + * @return the X12ProcessingSettings object itself. + */ + public X12ProcessingSettings withCreateEmptyXmlTagsForTrailingSeparators(boolean createEmptyXmlTagsForTrailingSeparators) { + this.createEmptyXmlTagsForTrailingSeparators = createEmptyXmlTagsForTrailingSeparators; + return this; + } + + /** + * Get the value indicating whether to use dot as decimal separator. + * + * @return the useDotAsDecimalSeparator value + */ + public boolean useDotAsDecimalSeparator() { + return this.useDotAsDecimalSeparator; + } + + /** + * Set the value indicating whether to use dot as decimal separator. + * + * @param useDotAsDecimalSeparator the useDotAsDecimalSeparator value to set + * @return the X12ProcessingSettings object itself. + */ + public X12ProcessingSettings withUseDotAsDecimalSeparator(boolean useDotAsDecimalSeparator) { + this.useDotAsDecimalSeparator = useDotAsDecimalSeparator; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12ProtocolSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12ProtocolSettings.java new file mode 100644 index 000000000000..704e21798f29 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12ProtocolSettings.java @@ -0,0 +1,330 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 agreement protocol settings. + */ +public class X12ProtocolSettings { + /** + * The X12 validation settings. + */ + @JsonProperty(value = "validationSettings", required = true) + private X12ValidationSettings validationSettings; + + /** + * The X12 framing settings. + */ + @JsonProperty(value = "framingSettings", required = true) + private X12FramingSettings framingSettings; + + /** + * The X12 envelope settings. + */ + @JsonProperty(value = "envelopeSettings", required = true) + private X12EnvelopeSettings envelopeSettings; + + /** + * The X12 acknowledgment settings. + */ + @JsonProperty(value = "acknowledgementSettings", required = true) + private X12AcknowledgementSettings acknowledgementSettings; + + /** + * The X12 message filter. + */ + @JsonProperty(value = "messageFilter", required = true) + private X12MessageFilter messageFilter; + + /** + * The X12 security settings. + */ + @JsonProperty(value = "securitySettings", required = true) + private X12SecuritySettings securitySettings; + + /** + * The X12 processing settings. + */ + @JsonProperty(value = "processingSettings", required = true) + private X12ProcessingSettings processingSettings; + + /** + * The X12 envelope override settings. + */ + @JsonProperty(value = "envelopeOverrides") + private List envelopeOverrides; + + /** + * The X12 validation override settings. + */ + @JsonProperty(value = "validationOverrides") + private List validationOverrides; + + /** + * The X12 message filter list. + */ + @JsonProperty(value = "messageFilterList") + private List messageFilterList; + + /** + * The X12 schema references. + */ + @JsonProperty(value = "schemaReferences", required = true) + private List schemaReferences; + + /** + * The X12 delimiter override settings. + */ + @JsonProperty(value = "x12DelimiterOverrides") + private List x12DelimiterOverrides; + + /** + * Get the X12 validation settings. + * + * @return the validationSettings value + */ + public X12ValidationSettings validationSettings() { + return this.validationSettings; + } + + /** + * Set the X12 validation settings. + * + * @param validationSettings the validationSettings value to set + * @return the X12ProtocolSettings object itself. + */ + public X12ProtocolSettings withValidationSettings(X12ValidationSettings validationSettings) { + this.validationSettings = validationSettings; + return this; + } + + /** + * Get the X12 framing settings. + * + * @return the framingSettings value + */ + public X12FramingSettings framingSettings() { + return this.framingSettings; + } + + /** + * Set the X12 framing settings. + * + * @param framingSettings the framingSettings value to set + * @return the X12ProtocolSettings object itself. + */ + public X12ProtocolSettings withFramingSettings(X12FramingSettings framingSettings) { + this.framingSettings = framingSettings; + return this; + } + + /** + * Get the X12 envelope settings. + * + * @return the envelopeSettings value + */ + public X12EnvelopeSettings envelopeSettings() { + return this.envelopeSettings; + } + + /** + * Set the X12 envelope settings. + * + * @param envelopeSettings the envelopeSettings value to set + * @return the X12ProtocolSettings object itself. + */ + public X12ProtocolSettings withEnvelopeSettings(X12EnvelopeSettings envelopeSettings) { + this.envelopeSettings = envelopeSettings; + return this; + } + + /** + * Get the X12 acknowledgment settings. + * + * @return the acknowledgementSettings value + */ + public X12AcknowledgementSettings acknowledgementSettings() { + return this.acknowledgementSettings; + } + + /** + * Set the X12 acknowledgment settings. + * + * @param acknowledgementSettings the acknowledgementSettings value to set + * @return the X12ProtocolSettings object itself. + */ + public X12ProtocolSettings withAcknowledgementSettings(X12AcknowledgementSettings acknowledgementSettings) { + this.acknowledgementSettings = acknowledgementSettings; + return this; + } + + /** + * Get the X12 message filter. + * + * @return the messageFilter value + */ + public X12MessageFilter messageFilter() { + return this.messageFilter; + } + + /** + * Set the X12 message filter. + * + * @param messageFilter the messageFilter value to set + * @return the X12ProtocolSettings object itself. + */ + public X12ProtocolSettings withMessageFilter(X12MessageFilter messageFilter) { + this.messageFilter = messageFilter; + return this; + } + + /** + * Get the X12 security settings. + * + * @return the securitySettings value + */ + public X12SecuritySettings securitySettings() { + return this.securitySettings; + } + + /** + * Set the X12 security settings. + * + * @param securitySettings the securitySettings value to set + * @return the X12ProtocolSettings object itself. + */ + public X12ProtocolSettings withSecuritySettings(X12SecuritySettings securitySettings) { + this.securitySettings = securitySettings; + return this; + } + + /** + * Get the X12 processing settings. + * + * @return the processingSettings value + */ + public X12ProcessingSettings processingSettings() { + return this.processingSettings; + } + + /** + * Set the X12 processing settings. + * + * @param processingSettings the processingSettings value to set + * @return the X12ProtocolSettings object itself. + */ + public X12ProtocolSettings withProcessingSettings(X12ProcessingSettings processingSettings) { + this.processingSettings = processingSettings; + return this; + } + + /** + * Get the X12 envelope override settings. + * + * @return the envelopeOverrides value + */ + public List envelopeOverrides() { + return this.envelopeOverrides; + } + + /** + * Set the X12 envelope override settings. + * + * @param envelopeOverrides the envelopeOverrides value to set + * @return the X12ProtocolSettings object itself. + */ + public X12ProtocolSettings withEnvelopeOverrides(List envelopeOverrides) { + this.envelopeOverrides = envelopeOverrides; + return this; + } + + /** + * Get the X12 validation override settings. + * + * @return the validationOverrides value + */ + public List validationOverrides() { + return this.validationOverrides; + } + + /** + * Set the X12 validation override settings. + * + * @param validationOverrides the validationOverrides value to set + * @return the X12ProtocolSettings object itself. + */ + public X12ProtocolSettings withValidationOverrides(List validationOverrides) { + this.validationOverrides = validationOverrides; + return this; + } + + /** + * Get the X12 message filter list. + * + * @return the messageFilterList value + */ + public List messageFilterList() { + return this.messageFilterList; + } + + /** + * Set the X12 message filter list. + * + * @param messageFilterList the messageFilterList value to set + * @return the X12ProtocolSettings object itself. + */ + public X12ProtocolSettings withMessageFilterList(List messageFilterList) { + this.messageFilterList = messageFilterList; + return this; + } + + /** + * Get the X12 schema references. + * + * @return the schemaReferences value + */ + public List schemaReferences() { + return this.schemaReferences; + } + + /** + * Set the X12 schema references. + * + * @param schemaReferences the schemaReferences value to set + * @return the X12ProtocolSettings object itself. + */ + public X12ProtocolSettings withSchemaReferences(List schemaReferences) { + this.schemaReferences = schemaReferences; + return this; + } + + /** + * Get the X12 delimiter override settings. + * + * @return the x12DelimiterOverrides value + */ + public List x12DelimiterOverrides() { + return this.x12DelimiterOverrides; + } + + /** + * Set the X12 delimiter override settings. + * + * @param x12DelimiterOverrides the x12DelimiterOverrides value to set + * @return the X12ProtocolSettings object itself. + */ + public X12ProtocolSettings withX12DelimiterOverrides(List x12DelimiterOverrides) { + this.x12DelimiterOverrides = x12DelimiterOverrides; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12SchemaReference.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12SchemaReference.java new file mode 100644 index 000000000000..54afc0ff522b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12SchemaReference.java @@ -0,0 +1,121 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 schema reference. + */ +public class X12SchemaReference { + /** + * The message id. + */ + @JsonProperty(value = "messageId", required = true) + private String messageId; + + /** + * The sender application id. + */ + @JsonProperty(value = "senderApplicationId") + private String senderApplicationId; + + /** + * The schema version. + */ + @JsonProperty(value = "schemaVersion", required = true) + private String schemaVersion; + + /** + * The schema name. + */ + @JsonProperty(value = "schemaName", required = true) + private String schemaName; + + /** + * Get the message id. + * + * @return the messageId value + */ + public String messageId() { + return this.messageId; + } + + /** + * Set the message id. + * + * @param messageId the messageId value to set + * @return the X12SchemaReference object itself. + */ + public X12SchemaReference withMessageId(String messageId) { + this.messageId = messageId; + return this; + } + + /** + * Get the sender application id. + * + * @return the senderApplicationId value + */ + public String senderApplicationId() { + return this.senderApplicationId; + } + + /** + * Set the sender application id. + * + * @param senderApplicationId the senderApplicationId value to set + * @return the X12SchemaReference object itself. + */ + public X12SchemaReference withSenderApplicationId(String senderApplicationId) { + this.senderApplicationId = senderApplicationId; + return this; + } + + /** + * Get the schema version. + * + * @return the schemaVersion value + */ + public String schemaVersion() { + return this.schemaVersion; + } + + /** + * Set the schema version. + * + * @param schemaVersion the schemaVersion value to set + * @return the X12SchemaReference object itself. + */ + public X12SchemaReference withSchemaVersion(String schemaVersion) { + this.schemaVersion = schemaVersion; + return this; + } + + /** + * Get the schema name. + * + * @return the schemaName value + */ + public String schemaName() { + return this.schemaName; + } + + /** + * Set the schema name. + * + * @param schemaName the schemaName value to set + * @return the X12SchemaReference object itself. + */ + public X12SchemaReference withSchemaName(String schemaName) { + this.schemaName = schemaName; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12SecuritySettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12SecuritySettings.java new file mode 100644 index 000000000000..2b53476ba61b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12SecuritySettings.java @@ -0,0 +1,121 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 agreement security settings. + */ +public class X12SecuritySettings { + /** + * The authorization qualifier. + */ + @JsonProperty(value = "authorizationQualifier", required = true) + private String authorizationQualifier; + + /** + * The authorization value. + */ + @JsonProperty(value = "authorizationValue") + private String authorizationValue; + + /** + * The security qualifier. + */ + @JsonProperty(value = "securityQualifier", required = true) + private String securityQualifier; + + /** + * The password value. + */ + @JsonProperty(value = "passwordValue") + private String passwordValue; + + /** + * Get the authorization qualifier. + * + * @return the authorizationQualifier value + */ + public String authorizationQualifier() { + return this.authorizationQualifier; + } + + /** + * Set the authorization qualifier. + * + * @param authorizationQualifier the authorizationQualifier value to set + * @return the X12SecuritySettings object itself. + */ + public X12SecuritySettings withAuthorizationQualifier(String authorizationQualifier) { + this.authorizationQualifier = authorizationQualifier; + return this; + } + + /** + * Get the authorization value. + * + * @return the authorizationValue value + */ + public String authorizationValue() { + return this.authorizationValue; + } + + /** + * Set the authorization value. + * + * @param authorizationValue the authorizationValue value to set + * @return the X12SecuritySettings object itself. + */ + public X12SecuritySettings withAuthorizationValue(String authorizationValue) { + this.authorizationValue = authorizationValue; + return this; + } + + /** + * Get the security qualifier. + * + * @return the securityQualifier value + */ + public String securityQualifier() { + return this.securityQualifier; + } + + /** + * Set the security qualifier. + * + * @param securityQualifier the securityQualifier value to set + * @return the X12SecuritySettings object itself. + */ + public X12SecuritySettings withSecurityQualifier(String securityQualifier) { + this.securityQualifier = securityQualifier; + return this; + } + + /** + * Get the password value. + * + * @return the passwordValue value + */ + public String passwordValue() { + return this.passwordValue; + } + + /** + * Set the password value. + * + * @param passwordValue the passwordValue value to set + * @return the X12SecuritySettings object itself. + */ + public X12SecuritySettings withPasswordValue(String passwordValue) { + this.passwordValue = passwordValue; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12TimeFormat.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12TimeFormat.java new file mode 100644 index 000000000000..00d5446d5add --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12TimeFormat.java @@ -0,0 +1,50 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for X12TimeFormat. + */ +public final class X12TimeFormat extends ExpandableStringEnum { + /** Static value NotSpecified for X12TimeFormat. */ + public static final X12TimeFormat NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value HHMM for X12TimeFormat. */ + public static final X12TimeFormat HHMM = fromString("HHMM"); + + /** Static value HHMMSS for X12TimeFormat. */ + public static final X12TimeFormat HHMMSS = fromString("HHMMSS"); + + /** Static value HHMMSSdd for X12TimeFormat. */ + public static final X12TimeFormat HHMMSSDD = fromString("HHMMSSdd"); + + /** Static value HHMMSSd for X12TimeFormat. */ + public static final X12TimeFormat HHMMSSD = fromString("HHMMSSd"); + + /** + * Creates or finds a X12TimeFormat from its string representation. + * @param name a name to look for + * @return the corresponding X12TimeFormat + */ + @JsonCreator + public static X12TimeFormat fromString(String name) { + return fromString(name, X12TimeFormat.class); + } + + /** + * @return known X12TimeFormat values + */ + public static Collection values() { + return values(X12TimeFormat.class); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12ValidationOverride.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12ValidationOverride.java new file mode 100644 index 000000000000..d318ba92e1ce --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12ValidationOverride.java @@ -0,0 +1,202 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 validation override settings. + */ +public class X12ValidationOverride { + /** + * The message id on which the validation settings has to be applied. + */ + @JsonProperty(value = "messageId", required = true) + private String messageId; + + /** + * The value indicating whether to validate EDI types. + */ + @JsonProperty(value = "validateEDITypes", required = true) + private boolean validateEDITypes; + + /** + * The value indicating whether to validate XSD types. + */ + @JsonProperty(value = "validateXSDTypes", required = true) + private boolean validateXSDTypes; + + /** + * The value indicating whether to allow leading and trailing spaces and + * zeroes. + */ + @JsonProperty(value = "allowLeadingAndTrailingSpacesAndZeroes", required = true) + private boolean allowLeadingAndTrailingSpacesAndZeroes; + + /** + * The value indicating whether to validate character Set. + */ + @JsonProperty(value = "validateCharacterSet", required = true) + private boolean validateCharacterSet; + + /** + * The value indicating whether to trim leading and trailing spaces and + * zeroes. + */ + @JsonProperty(value = "trimLeadingAndTrailingSpacesAndZeroes", required = true) + private boolean trimLeadingAndTrailingSpacesAndZeroes; + + /** + * The trailing separator policy. Possible values include: 'NotSpecified', + * 'NotAllowed', 'Optional', 'Mandatory'. + */ + @JsonProperty(value = "trailingSeparatorPolicy", required = true) + private TrailingSeparatorPolicy trailingSeparatorPolicy; + + /** + * Get the message id on which the validation settings has to be applied. + * + * @return the messageId value + */ + public String messageId() { + return this.messageId; + } + + /** + * Set the message id on which the validation settings has to be applied. + * + * @param messageId the messageId value to set + * @return the X12ValidationOverride object itself. + */ + public X12ValidationOverride withMessageId(String messageId) { + this.messageId = messageId; + return this; + } + + /** + * Get the value indicating whether to validate EDI types. + * + * @return the validateEDITypes value + */ + public boolean validateEDITypes() { + return this.validateEDITypes; + } + + /** + * Set the value indicating whether to validate EDI types. + * + * @param validateEDITypes the validateEDITypes value to set + * @return the X12ValidationOverride object itself. + */ + public X12ValidationOverride withValidateEDITypes(boolean validateEDITypes) { + this.validateEDITypes = validateEDITypes; + return this; + } + + /** + * Get the value indicating whether to validate XSD types. + * + * @return the validateXSDTypes value + */ + public boolean validateXSDTypes() { + return this.validateXSDTypes; + } + + /** + * Set the value indicating whether to validate XSD types. + * + * @param validateXSDTypes the validateXSDTypes value to set + * @return the X12ValidationOverride object itself. + */ + public X12ValidationOverride withValidateXSDTypes(boolean validateXSDTypes) { + this.validateXSDTypes = validateXSDTypes; + return this; + } + + /** + * Get the value indicating whether to allow leading and trailing spaces and zeroes. + * + * @return the allowLeadingAndTrailingSpacesAndZeroes value + */ + public boolean allowLeadingAndTrailingSpacesAndZeroes() { + return this.allowLeadingAndTrailingSpacesAndZeroes; + } + + /** + * Set the value indicating whether to allow leading and trailing spaces and zeroes. + * + * @param allowLeadingAndTrailingSpacesAndZeroes the allowLeadingAndTrailingSpacesAndZeroes value to set + * @return the X12ValidationOverride object itself. + */ + public X12ValidationOverride withAllowLeadingAndTrailingSpacesAndZeroes(boolean allowLeadingAndTrailingSpacesAndZeroes) { + this.allowLeadingAndTrailingSpacesAndZeroes = allowLeadingAndTrailingSpacesAndZeroes; + return this; + } + + /** + * Get the value indicating whether to validate character Set. + * + * @return the validateCharacterSet value + */ + public boolean validateCharacterSet() { + return this.validateCharacterSet; + } + + /** + * Set the value indicating whether to validate character Set. + * + * @param validateCharacterSet the validateCharacterSet value to set + * @return the X12ValidationOverride object itself. + */ + public X12ValidationOverride withValidateCharacterSet(boolean validateCharacterSet) { + this.validateCharacterSet = validateCharacterSet; + return this; + } + + /** + * Get the value indicating whether to trim leading and trailing spaces and zeroes. + * + * @return the trimLeadingAndTrailingSpacesAndZeroes value + */ + public boolean trimLeadingAndTrailingSpacesAndZeroes() { + return this.trimLeadingAndTrailingSpacesAndZeroes; + } + + /** + * Set the value indicating whether to trim leading and trailing spaces and zeroes. + * + * @param trimLeadingAndTrailingSpacesAndZeroes the trimLeadingAndTrailingSpacesAndZeroes value to set + * @return the X12ValidationOverride object itself. + */ + public X12ValidationOverride withTrimLeadingAndTrailingSpacesAndZeroes(boolean trimLeadingAndTrailingSpacesAndZeroes) { + this.trimLeadingAndTrailingSpacesAndZeroes = trimLeadingAndTrailingSpacesAndZeroes; + return this; + } + + /** + * Get the trailing separator policy. Possible values include: 'NotSpecified', 'NotAllowed', 'Optional', 'Mandatory'. + * + * @return the trailingSeparatorPolicy value + */ + public TrailingSeparatorPolicy trailingSeparatorPolicy() { + return this.trailingSeparatorPolicy; + } + + /** + * Set the trailing separator policy. Possible values include: 'NotSpecified', 'NotAllowed', 'Optional', 'Mandatory'. + * + * @param trailingSeparatorPolicy the trailingSeparatorPolicy value to set + * @return the X12ValidationOverride object itself. + */ + public X12ValidationOverride withTrailingSeparatorPolicy(TrailingSeparatorPolicy trailingSeparatorPolicy) { + this.trailingSeparatorPolicy = trailingSeparatorPolicy; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12ValidationSettings.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12ValidationSettings.java new file mode 100644 index 000000000000..6f0c646b3f2c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/X12ValidationSettings.java @@ -0,0 +1,283 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The X12 agreement validation settings. + */ +public class X12ValidationSettings { + /** + * The value indicating whether to validate character set in the message. + */ + @JsonProperty(value = "validateCharacterSet", required = true) + private boolean validateCharacterSet; + + /** + * The value indicating whether to check for duplicate interchange control + * number. + */ + @JsonProperty(value = "checkDuplicateInterchangeControlNumber", required = true) + private boolean checkDuplicateInterchangeControlNumber; + + /** + * The validity period of interchange control number. + */ + @JsonProperty(value = "interchangeControlNumberValidityDays", required = true) + private int interchangeControlNumberValidityDays; + + /** + * The value indicating whether to check for duplicate group control + * number. + */ + @JsonProperty(value = "checkDuplicateGroupControlNumber", required = true) + private boolean checkDuplicateGroupControlNumber; + + /** + * The value indicating whether to check for duplicate transaction set + * control number. + */ + @JsonProperty(value = "checkDuplicateTransactionSetControlNumber", required = true) + private boolean checkDuplicateTransactionSetControlNumber; + + /** + * The value indicating whether to Whether to validate EDI types. + */ + @JsonProperty(value = "validateEDITypes", required = true) + private boolean validateEDITypes; + + /** + * The value indicating whether to Whether to validate XSD types. + */ + @JsonProperty(value = "validateXSDTypes", required = true) + private boolean validateXSDTypes; + + /** + * The value indicating whether to allow leading and trailing spaces and + * zeroes. + */ + @JsonProperty(value = "allowLeadingAndTrailingSpacesAndZeroes", required = true) + private boolean allowLeadingAndTrailingSpacesAndZeroes; + + /** + * The value indicating whether to trim leading and trailing spaces and + * zeroes. + */ + @JsonProperty(value = "trimLeadingAndTrailingSpacesAndZeroes", required = true) + private boolean trimLeadingAndTrailingSpacesAndZeroes; + + /** + * The trailing separator policy. Possible values include: 'NotSpecified', + * 'NotAllowed', 'Optional', 'Mandatory'. + */ + @JsonProperty(value = "trailingSeparatorPolicy", required = true) + private TrailingSeparatorPolicy trailingSeparatorPolicy; + + /** + * Get the value indicating whether to validate character set in the message. + * + * @return the validateCharacterSet value + */ + public boolean validateCharacterSet() { + return this.validateCharacterSet; + } + + /** + * Set the value indicating whether to validate character set in the message. + * + * @param validateCharacterSet the validateCharacterSet value to set + * @return the X12ValidationSettings object itself. + */ + public X12ValidationSettings withValidateCharacterSet(boolean validateCharacterSet) { + this.validateCharacterSet = validateCharacterSet; + return this; + } + + /** + * Get the value indicating whether to check for duplicate interchange control number. + * + * @return the checkDuplicateInterchangeControlNumber value + */ + public boolean checkDuplicateInterchangeControlNumber() { + return this.checkDuplicateInterchangeControlNumber; + } + + /** + * Set the value indicating whether to check for duplicate interchange control number. + * + * @param checkDuplicateInterchangeControlNumber the checkDuplicateInterchangeControlNumber value to set + * @return the X12ValidationSettings object itself. + */ + public X12ValidationSettings withCheckDuplicateInterchangeControlNumber(boolean checkDuplicateInterchangeControlNumber) { + this.checkDuplicateInterchangeControlNumber = checkDuplicateInterchangeControlNumber; + return this; + } + + /** + * Get the validity period of interchange control number. + * + * @return the interchangeControlNumberValidityDays value + */ + public int interchangeControlNumberValidityDays() { + return this.interchangeControlNumberValidityDays; + } + + /** + * Set the validity period of interchange control number. + * + * @param interchangeControlNumberValidityDays the interchangeControlNumberValidityDays value to set + * @return the X12ValidationSettings object itself. + */ + public X12ValidationSettings withInterchangeControlNumberValidityDays(int interchangeControlNumberValidityDays) { + this.interchangeControlNumberValidityDays = interchangeControlNumberValidityDays; + return this; + } + + /** + * Get the value indicating whether to check for duplicate group control number. + * + * @return the checkDuplicateGroupControlNumber value + */ + public boolean checkDuplicateGroupControlNumber() { + return this.checkDuplicateGroupControlNumber; + } + + /** + * Set the value indicating whether to check for duplicate group control number. + * + * @param checkDuplicateGroupControlNumber the checkDuplicateGroupControlNumber value to set + * @return the X12ValidationSettings object itself. + */ + public X12ValidationSettings withCheckDuplicateGroupControlNumber(boolean checkDuplicateGroupControlNumber) { + this.checkDuplicateGroupControlNumber = checkDuplicateGroupControlNumber; + return this; + } + + /** + * Get the value indicating whether to check for duplicate transaction set control number. + * + * @return the checkDuplicateTransactionSetControlNumber value + */ + public boolean checkDuplicateTransactionSetControlNumber() { + return this.checkDuplicateTransactionSetControlNumber; + } + + /** + * Set the value indicating whether to check for duplicate transaction set control number. + * + * @param checkDuplicateTransactionSetControlNumber the checkDuplicateTransactionSetControlNumber value to set + * @return the X12ValidationSettings object itself. + */ + public X12ValidationSettings withCheckDuplicateTransactionSetControlNumber(boolean checkDuplicateTransactionSetControlNumber) { + this.checkDuplicateTransactionSetControlNumber = checkDuplicateTransactionSetControlNumber; + return this; + } + + /** + * Get the value indicating whether to Whether to validate EDI types. + * + * @return the validateEDITypes value + */ + public boolean validateEDITypes() { + return this.validateEDITypes; + } + + /** + * Set the value indicating whether to Whether to validate EDI types. + * + * @param validateEDITypes the validateEDITypes value to set + * @return the X12ValidationSettings object itself. + */ + public X12ValidationSettings withValidateEDITypes(boolean validateEDITypes) { + this.validateEDITypes = validateEDITypes; + return this; + } + + /** + * Get the value indicating whether to Whether to validate XSD types. + * + * @return the validateXSDTypes value + */ + public boolean validateXSDTypes() { + return this.validateXSDTypes; + } + + /** + * Set the value indicating whether to Whether to validate XSD types. + * + * @param validateXSDTypes the validateXSDTypes value to set + * @return the X12ValidationSettings object itself. + */ + public X12ValidationSettings withValidateXSDTypes(boolean validateXSDTypes) { + this.validateXSDTypes = validateXSDTypes; + return this; + } + + /** + * Get the value indicating whether to allow leading and trailing spaces and zeroes. + * + * @return the allowLeadingAndTrailingSpacesAndZeroes value + */ + public boolean allowLeadingAndTrailingSpacesAndZeroes() { + return this.allowLeadingAndTrailingSpacesAndZeroes; + } + + /** + * Set the value indicating whether to allow leading and trailing spaces and zeroes. + * + * @param allowLeadingAndTrailingSpacesAndZeroes the allowLeadingAndTrailingSpacesAndZeroes value to set + * @return the X12ValidationSettings object itself. + */ + public X12ValidationSettings withAllowLeadingAndTrailingSpacesAndZeroes(boolean allowLeadingAndTrailingSpacesAndZeroes) { + this.allowLeadingAndTrailingSpacesAndZeroes = allowLeadingAndTrailingSpacesAndZeroes; + return this; + } + + /** + * Get the value indicating whether to trim leading and trailing spaces and zeroes. + * + * @return the trimLeadingAndTrailingSpacesAndZeroes value + */ + public boolean trimLeadingAndTrailingSpacesAndZeroes() { + return this.trimLeadingAndTrailingSpacesAndZeroes; + } + + /** + * Set the value indicating whether to trim leading and trailing spaces and zeroes. + * + * @param trimLeadingAndTrailingSpacesAndZeroes the trimLeadingAndTrailingSpacesAndZeroes value to set + * @return the X12ValidationSettings object itself. + */ + public X12ValidationSettings withTrimLeadingAndTrailingSpacesAndZeroes(boolean trimLeadingAndTrailingSpacesAndZeroes) { + this.trimLeadingAndTrailingSpacesAndZeroes = trimLeadingAndTrailingSpacesAndZeroes; + return this; + } + + /** + * Get the trailing separator policy. Possible values include: 'NotSpecified', 'NotAllowed', 'Optional', 'Mandatory'. + * + * @return the trailingSeparatorPolicy value + */ + public TrailingSeparatorPolicy trailingSeparatorPolicy() { + return this.trailingSeparatorPolicy; + } + + /** + * Set the trailing separator policy. Possible values include: 'NotSpecified', 'NotAllowed', 'Optional', 'Mandatory'. + * + * @param trailingSeparatorPolicy the trailingSeparatorPolicy value to set + * @return the X12ValidationSettings object itself. + */ + public X12ValidationSettings withTrailingSeparatorPolicy(TrailingSeparatorPolicy trailingSeparatorPolicy) { + this.trailingSeparatorPolicy = trailingSeparatorPolicy; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ActionRunWorkflowRequestHistoryImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ActionRunWorkflowRequestHistoryImpl.java new file mode 100644 index 000000000000..ba92f0369349 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ActionRunWorkflowRequestHistoryImpl.java @@ -0,0 +1,79 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.ActionRunWorkflowRequestHistory; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.RequestHistoryProperties; +import java.util.Map; + +class ActionRunWorkflowRequestHistoryImpl extends IndexableRefreshableWrapperImpl implements ActionRunWorkflowRequestHistory { + private final LogicManager manager; + private String resourceGroupName; + private String workflowName; + private String runName; + private String actionName; + private String requestHistoryName; + + ActionRunWorkflowRequestHistoryImpl(RequestHistoryInner inner, LogicManager manager) { + super(null, inner); + this.manager = manager; + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.workflowName = IdParsingUtils.getValueFromIdByName(inner.id(), "workflows"); + this.runName = IdParsingUtils.getValueFromIdByName(inner.id(), "runs"); + this.actionName = IdParsingUtils.getValueFromIdByName(inner.id(), "actions"); + this.requestHistoryName = IdParsingUtils.getValueFromIdByName(inner.id(), "requestHistories"); + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + protected Observable getInnerAsync() { + WorkflowRunActionRequestHistoriesInner client = this.manager().inner().workflowRunActionRequestHistories(); + return client.getAsync(this.resourceGroupName, this.workflowName, this.runName, this.actionName, this.requestHistoryName); + } + + + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public RequestHistoryProperties properties() { + return this.inner().properties(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public String type() { + return this.inner().type(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionImpl.java new file mode 100644 index 000000000000..332bf18027f9 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionImpl.java @@ -0,0 +1,155 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.ActionRunWorkflowWorkflowRunActionRepetitionDefinition; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.RunActionCorrelation; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.ContentLink; +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.RepetitionIndex; +import com.microsoft.azure.management.logic.v2019_05_01.RetryHistory; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowStatus; +import java.util.Map; + +class ActionRunWorkflowWorkflowRunActionRepetitionDefinitionImpl extends IndexableRefreshableWrapperImpl implements ActionRunWorkflowWorkflowRunActionRepetitionDefinition { + private final LogicManager manager; + private String resourceGroupName; + private String workflowName; + private String runName; + private String actionName; + private String repetitionName; + + ActionRunWorkflowWorkflowRunActionRepetitionDefinitionImpl(WorkflowRunActionRepetitionDefinitionInner inner, LogicManager manager) { + super(null, inner); + this.manager = manager; + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.workflowName = IdParsingUtils.getValueFromIdByName(inner.id(), "workflows"); + this.runName = IdParsingUtils.getValueFromIdByName(inner.id(), "runs"); + this.actionName = IdParsingUtils.getValueFromIdByName(inner.id(), "actions"); + this.repetitionName = IdParsingUtils.getValueFromIdByName(inner.id(), "repetitions"); + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + protected Observable getInnerAsync() { + WorkflowRunActionRepetitionsInner client = this.manager().inner().workflowRunActionRepetitions(); + return client.getAsync(this.resourceGroupName, this.workflowName, this.runName, this.actionName, this.repetitionName); + } + + + + @Override + public String code() { + return this.inner().code(); + } + + @Override + public RunActionCorrelation correlation() { + return this.inner().correlation(); + } + + @Override + public DateTime endTime() { + return this.inner().endTime(); + } + + @Override + public Object error() { + return this.inner().error(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public Object inputs() { + return this.inner().inputs(); + } + + @Override + public ContentLink inputsLink() { + return this.inner().inputsLink(); + } + + @Override + public Integer iterationCount() { + return this.inner().iterationCount(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public Object outputs() { + return this.inner().outputs(); + } + + @Override + public ContentLink outputsLink() { + return this.inner().outputsLink(); + } + + @Override + public List repetitionIndexes() { + return this.inner().repetitionIndexes(); + } + + @Override + public List retryHistory() { + return this.inner().retryHistory(); + } + + @Override + public DateTime startTime() { + return this.inner().startTime(); + } + + @Override + public WorkflowStatus status() { + return this.inner().status(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public Object trackedProperties() { + return this.inner().trackedProperties(); + } + + @Override + public String trackingId() { + return this.inner().trackingId(); + } + + @Override + public String type() { + return this.inner().type(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModelImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModelImpl.java new file mode 100644 index 000000000000..681b42f355d4 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModelImpl.java @@ -0,0 +1,155 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.RunActionCorrelation; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.ContentLink; +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.RepetitionIndex; +import com.microsoft.azure.management.logic.v2019_05_01.RetryHistory; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowStatus; +import java.util.Map; + +class ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModelImpl extends IndexableRefreshableWrapperImpl implements ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel { + private final LogicManager manager; + private String resourceGroupName; + private String workflowName; + private String runName; + private String actionName; + private String repetitionName; + + ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModelImpl(WorkflowRunActionRepetitionDefinitionInner inner, LogicManager manager) { + super(null, inner); + this.manager = manager; + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.workflowName = IdParsingUtils.getValueFromIdByName(inner.id(), "workflows"); + this.runName = IdParsingUtils.getValueFromIdByName(inner.id(), "runs"); + this.actionName = IdParsingUtils.getValueFromIdByName(inner.id(), "actions"); + this.repetitionName = IdParsingUtils.getValueFromIdByName(inner.id(), "scopeRepetitions"); + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + protected Observable getInnerAsync() { + WorkflowRunActionScopeRepetitionsInner client = this.manager().inner().workflowRunActionScopeRepetitions(); + return client.getAsync(this.resourceGroupName, this.workflowName, this.runName, this.actionName, this.repetitionName); + } + + + + @Override + public String code() { + return this.inner().code(); + } + + @Override + public RunActionCorrelation correlation() { + return this.inner().correlation(); + } + + @Override + public DateTime endTime() { + return this.inner().endTime(); + } + + @Override + public Object error() { + return this.inner().error(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public Object inputs() { + return this.inner().inputs(); + } + + @Override + public ContentLink inputsLink() { + return this.inner().inputsLink(); + } + + @Override + public Integer iterationCount() { + return this.inner().iterationCount(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public Object outputs() { + return this.inner().outputs(); + } + + @Override + public ContentLink outputsLink() { + return this.inner().outputsLink(); + } + + @Override + public List repetitionIndexes() { + return this.inner().repetitionIndexes(); + } + + @Override + public List retryHistory() { + return this.inner().retryHistory(); + } + + @Override + public DateTime startTime() { + return this.inner().startTime(); + } + + @Override + public WorkflowStatus status() { + return this.inner().status(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public Object trackedProperties() { + return this.inner().trackedProperties(); + } + + @Override + public String trackingId() { + return this.inner().trackingId(); + } + + @Override + public String type() { + return this.inner().type(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ApiOperationImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ApiOperationImpl.java new file mode 100644 index 000000000000..23f85b0b7366 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ApiOperationImpl.java @@ -0,0 +1,62 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.ApiOperation; +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.ApiOperationPropertiesDefinition; +import java.util.Map; + +class ApiOperationImpl extends WrapperImpl implements ApiOperation { + private final LogicManager manager; + + ApiOperationImpl(ApiOperationInner inner, LogicManager manager) { + super(inner); + this.manager = manager; + } + + @Override + public LogicManager manager() { + return this.manager; + } + + + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public ApiOperationPropertiesDefinition properties() { + return this.inner().properties(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public String type() { + return this.inner().type(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ApiOperationInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ApiOperationInner.java new file mode 100644 index 000000000000..c633392982dd --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ApiOperationInner.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.ApiOperationPropertiesDefinition; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The api operation. + */ +@SkipParentValidation +public class ApiOperationInner extends Resource { + /** + * The properties property. + */ + @JsonProperty(value = "properties") + private ApiOperationPropertiesDefinition properties; + + /** + * Get the properties value. + * + * @return the properties value + */ + public ApiOperationPropertiesDefinition properties() { + return this.properties; + } + + /** + * Set the properties value. + * + * @param properties the properties value to set + * @return the ApiOperationInner object itself. + */ + public ApiOperationInner withProperties(ApiOperationPropertiesDefinition properties) { + this.properties = properties; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/AssemblyDefinitionImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/AssemblyDefinitionImpl.java new file mode 100644 index 000000000000..5870651e3fae --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/AssemblyDefinitionImpl.java @@ -0,0 +1,129 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.AssemblyDefinition; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import java.util.Map; +import com.microsoft.azure.management.logic.v2019_05_01.AssemblyProperties; + +class AssemblyDefinitionImpl extends CreatableUpdatableImpl implements AssemblyDefinition, AssemblyDefinition.Definition, AssemblyDefinition.Update { + private final LogicManager manager; + private String resourceGroupName; + private String integrationAccountName; + private String assemblyArtifactName; + + AssemblyDefinitionImpl(String name, LogicManager manager) { + super(name, new AssemblyDefinitionInner()); + this.manager = manager; + // Set resource name + this.assemblyArtifactName = name; + // + } + + AssemblyDefinitionImpl(AssemblyDefinitionInner inner, LogicManager manager) { + super(inner.name(), inner); + this.manager = manager; + // Set resource name + this.assemblyArtifactName = inner.name(); + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.integrationAccountName = IdParsingUtils.getValueFromIdByName(inner.id(), "integrationAccounts"); + this.assemblyArtifactName = IdParsingUtils.getValueFromIdByName(inner.id(), "assemblies"); + // + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public Observable createResourceAsync() { + IntegrationAccountAssembliesInner client = this.manager().inner().integrationAccountAssemblies(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.assemblyArtifactName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + public Observable updateResourceAsync() { + IntegrationAccountAssembliesInner client = this.manager().inner().integrationAccountAssemblies(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.assemblyArtifactName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + protected Observable getInnerAsync() { + IntegrationAccountAssembliesInner client = this.manager().inner().integrationAccountAssemblies(); + return client.getAsync(this.resourceGroupName, this.integrationAccountName, this.assemblyArtifactName); + } + + @Override + public boolean isInCreateMode() { + return this.inner().id() == null; + } + + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public AssemblyProperties properties() { + return this.inner().properties(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public String type() { + return this.inner().type(); + } + + @Override + public AssemblyDefinitionImpl withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName) { + this.resourceGroupName = resourceGroupName; + this.integrationAccountName = integrationAccountName; + return this; + } + + @Override + public AssemblyDefinitionImpl withProperties(AssemblyProperties properties) { + this.inner().withProperties(properties); + return this; + } + + @Override + public AssemblyDefinitionImpl withLocation(String location) { + this.inner().withLocation(location); + return this; + } + + @Override + public AssemblyDefinitionImpl withTags(Map tags) { + this.inner().withTags(tags); + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/AssemblyDefinitionInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/AssemblyDefinitionInner.java new file mode 100644 index 000000000000..0f663f6b9300 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/AssemblyDefinitionInner.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.AssemblyProperties; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The assembly definition. + */ +@SkipParentValidation +public class AssemblyDefinitionInner extends Resource { + /** + * The assembly properties. + */ + @JsonProperty(value = "properties", required = true) + private AssemblyProperties properties; + + /** + * Get the assembly properties. + * + * @return the properties value + */ + public AssemblyProperties properties() { + return this.properties; + } + + /** + * Set the assembly properties. + * + * @param properties the properties value to set + * @return the AssemblyDefinitionInner object itself. + */ + public AssemblyDefinitionInner withProperties(AssemblyProperties properties) { + this.properties = properties; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/BatchConfigurationImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/BatchConfigurationImpl.java new file mode 100644 index 000000000000..be66accfd6b0 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/BatchConfigurationImpl.java @@ -0,0 +1,129 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.BatchConfiguration; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import java.util.Map; +import com.microsoft.azure.management.logic.v2019_05_01.BatchConfigurationProperties; + +class BatchConfigurationImpl extends CreatableUpdatableImpl implements BatchConfiguration, BatchConfiguration.Definition, BatchConfiguration.Update { + private final LogicManager manager; + private String resourceGroupName; + private String integrationAccountName; + private String batchConfigurationName; + + BatchConfigurationImpl(String name, LogicManager manager) { + super(name, new BatchConfigurationInner()); + this.manager = manager; + // Set resource name + this.batchConfigurationName = name; + // + } + + BatchConfigurationImpl(BatchConfigurationInner inner, LogicManager manager) { + super(inner.name(), inner); + this.manager = manager; + // Set resource name + this.batchConfigurationName = inner.name(); + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.integrationAccountName = IdParsingUtils.getValueFromIdByName(inner.id(), "integrationAccounts"); + this.batchConfigurationName = IdParsingUtils.getValueFromIdByName(inner.id(), "batchConfigurations"); + // + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public Observable createResourceAsync() { + IntegrationAccountBatchConfigurationsInner client = this.manager().inner().integrationAccountBatchConfigurations(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.batchConfigurationName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + public Observable updateResourceAsync() { + IntegrationAccountBatchConfigurationsInner client = this.manager().inner().integrationAccountBatchConfigurations(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.batchConfigurationName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + protected Observable getInnerAsync() { + IntegrationAccountBatchConfigurationsInner client = this.manager().inner().integrationAccountBatchConfigurations(); + return client.getAsync(this.resourceGroupName, this.integrationAccountName, this.batchConfigurationName); + } + + @Override + public boolean isInCreateMode() { + return this.inner().id() == null; + } + + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public BatchConfigurationProperties properties() { + return this.inner().properties(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public String type() { + return this.inner().type(); + } + + @Override + public BatchConfigurationImpl withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName) { + this.resourceGroupName = resourceGroupName; + this.integrationAccountName = integrationAccountName; + return this; + } + + @Override + public BatchConfigurationImpl withProperties(BatchConfigurationProperties properties) { + this.inner().withProperties(properties); + return this; + } + + @Override + public BatchConfigurationImpl withLocation(String location) { + this.inner().withLocation(location); + return this; + } + + @Override + public BatchConfigurationImpl withTags(Map tags) { + this.inner().withTags(tags); + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/BatchConfigurationInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/BatchConfigurationInner.java new file mode 100644 index 000000000000..47125aafdcd4 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/BatchConfigurationInner.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.BatchConfigurationProperties; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The batch configuration resource definition. + */ +@SkipParentValidation +public class BatchConfigurationInner extends Resource { + /** + * The batch configuration properties. + */ + @JsonProperty(value = "properties", required = true) + private BatchConfigurationProperties properties; + + /** + * Get the batch configuration properties. + * + * @return the properties value + */ + public BatchConfigurationProperties properties() { + return this.properties; + } + + /** + * Set the batch configuration properties. + * + * @param properties the properties value to set + * @return the BatchConfigurationInner object itself. + */ + public BatchConfigurationInner withProperties(BatchConfigurationProperties properties) { + this.properties = properties; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/CallbackUrlImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/CallbackUrlImpl.java new file mode 100644 index 000000000000..f48812e12fb5 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/CallbackUrlImpl.java @@ -0,0 +1,31 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.CallbackUrl; +import com.microsoft.azure.arm.model.implementation.WrapperImpl; + +class CallbackUrlImpl extends WrapperImpl implements CallbackUrl { + private final LogicManager manager; + CallbackUrlImpl(CallbackUrlInner inner, LogicManager manager) { + super(inner); + this.manager = manager; + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public String value() { + return this.inner().value(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/CallbackUrlInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/CallbackUrlInner.java new file mode 100644 index 000000000000..193a86ec7c2e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/CallbackUrlInner.java @@ -0,0 +1,43 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The callback url. + */ +public class CallbackUrlInner { + /** + * The URL value. + */ + @JsonProperty(value = "value") + private String value; + + /** + * Get the URL value. + * + * @return the value value + */ + public String value() { + return this.value; + } + + /** + * Set the URL value. + * + * @param value the value value to set + * @return the CallbackUrlInner object itself. + */ + public CallbackUrlInner withValue(String value) { + this.value = value; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ExpressionRootImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ExpressionRootImpl.java new file mode 100644 index 000000000000..1c7ebbcf9dc8 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ExpressionRootImpl.java @@ -0,0 +1,54 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.ExpressionRoot; +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.AzureResourceErrorInfo; +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.Expression; + +class ExpressionRootImpl extends WrapperImpl implements ExpressionRoot { + private final LogicManager manager; + ExpressionRootImpl(ExpressionRootInner inner, LogicManager manager) { + super(inner); + this.manager = manager; + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public AzureResourceErrorInfo error() { + return this.inner().error(); + } + + @Override + public String path() { + return this.inner().path(); + } + + @Override + public List subexpressions() { + return this.inner().subexpressions(); + } + + @Override + public String text() { + return this.inner().text(); + } + + @Override + public Object value() { + return this.inner().value(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ExpressionRootInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ExpressionRootInner.java new file mode 100644 index 000000000000..bf1e6c6ba40c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ExpressionRootInner.java @@ -0,0 +1,44 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.azure.management.logic.v2019_05_01.Expression; + +/** + * The expression root. + */ +public class ExpressionRootInner extends Expression { + /** + * The path. + */ + @JsonProperty(value = "path") + private String path; + + /** + * Get the path. + * + * @return the path value + */ + public String path() { + return this.path; + } + + /** + * Set the path. + * + * @param path the path value to set + * @return the ExpressionRootInner object itself. + */ + public ExpressionRootInner withPath(String path) { + this.path = path; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IdParsingUtils.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IdParsingUtils.java new file mode 100644 index 000000000000..c3bde5525527 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IdParsingUtils.java @@ -0,0 +1,57 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; +import java.util.Arrays; +import java.util.Iterator; + +class IdParsingUtils { + public static String getValueFromIdByName(String id, String name) { + if (id == null) { + return null; + } + Iterable iterable = Arrays.asList(id.split("/")); + Iterator itr = iterable.iterator(); + while (itr.hasNext()) { + String part = itr.next(); + if (part != null && part.trim() != "") { + if (part.equalsIgnoreCase(name)) { + if (itr.hasNext()) { + return itr.next(); + } else { + return null; + } + } + } + } + return null; + } + + public static String getValueFromIdByPosition(String id, int pos) { + if (id == null) { + return null; + } + Iterable iterable = Arrays.asList(id.split("/")); + Iterator itr = iterable.iterator(); + int index = 0; + while (itr.hasNext()) { + String part = itr.next(); + if (part != null && part.trim() != "") { + if (index == pos) { + if (itr.hasNext()) { + return itr.next(); + } else { + return null; + } + } + } + index++; + } + return null; + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAgreementImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAgreementImpl.java new file mode 100644 index 000000000000..1bcd663f1fcf --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAgreementImpl.java @@ -0,0 +1,208 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAgreement; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import java.util.Map; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.AgreementType; +import com.microsoft.azure.management.logic.v2019_05_01.BusinessIdentity; +import com.microsoft.azure.management.logic.v2019_05_01.AgreementContent; + +class IntegrationAccountAgreementImpl extends CreatableUpdatableImpl implements IntegrationAccountAgreement, IntegrationAccountAgreement.Definition, IntegrationAccountAgreement.Update { + private final LogicManager manager; + private String resourceGroupName; + private String integrationAccountName; + private String agreementName; + + IntegrationAccountAgreementImpl(String name, LogicManager manager) { + super(name, new IntegrationAccountAgreementInner()); + this.manager = manager; + // Set resource name + this.agreementName = name; + // + } + + IntegrationAccountAgreementImpl(IntegrationAccountAgreementInner inner, LogicManager manager) { + super(inner.name(), inner); + this.manager = manager; + // Set resource name + this.agreementName = inner.name(); + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.integrationAccountName = IdParsingUtils.getValueFromIdByName(inner.id(), "integrationAccounts"); + this.agreementName = IdParsingUtils.getValueFromIdByName(inner.id(), "agreements"); + // + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public Observable createResourceAsync() { + IntegrationAccountAgreementsInner client = this.manager().inner().integrationAccountAgreements(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.agreementName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + public Observable updateResourceAsync() { + IntegrationAccountAgreementsInner client = this.manager().inner().integrationAccountAgreements(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.agreementName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + protected Observable getInnerAsync() { + IntegrationAccountAgreementsInner client = this.manager().inner().integrationAccountAgreements(); + return client.getAsync(this.resourceGroupName, this.integrationAccountName, this.agreementName); + } + + @Override + public boolean isInCreateMode() { + return this.inner().id() == null; + } + + + @Override + public AgreementType agreementType() { + return this.inner().agreementType(); + } + + @Override + public DateTime changedTime() { + return this.inner().changedTime(); + } + + @Override + public AgreementContent content() { + return this.inner().content(); + } + + @Override + public DateTime createdTime() { + return this.inner().createdTime(); + } + + @Override + public BusinessIdentity guestIdentity() { + return this.inner().guestIdentity(); + } + + @Override + public String guestPartner() { + return this.inner().guestPartner(); + } + + @Override + public BusinessIdentity hostIdentity() { + return this.inner().hostIdentity(); + } + + @Override + public String hostPartner() { + return this.inner().hostPartner(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public Object metadata() { + return this.inner().metadata(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public String type() { + return this.inner().type(); + } + + @Override + public IntegrationAccountAgreementImpl withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName) { + this.resourceGroupName = resourceGroupName; + this.integrationAccountName = integrationAccountName; + return this; + } + + @Override + public IntegrationAccountAgreementImpl withAgreementType(AgreementType agreementType) { + this.inner().withAgreementType(agreementType); + return this; + } + + @Override + public IntegrationAccountAgreementImpl withContent(AgreementContent content) { + this.inner().withContent(content); + return this; + } + + @Override + public IntegrationAccountAgreementImpl withGuestIdentity(BusinessIdentity guestIdentity) { + this.inner().withGuestIdentity(guestIdentity); + return this; + } + + @Override + public IntegrationAccountAgreementImpl withGuestPartner(String guestPartner) { + this.inner().withGuestPartner(guestPartner); + return this; + } + + @Override + public IntegrationAccountAgreementImpl withHostIdentity(BusinessIdentity hostIdentity) { + this.inner().withHostIdentity(hostIdentity); + return this; + } + + @Override + public IntegrationAccountAgreementImpl withHostPartner(String hostPartner) { + this.inner().withHostPartner(hostPartner); + return this; + } + + @Override + public IntegrationAccountAgreementImpl withLocation(String location) { + this.inner().withLocation(location); + return this; + } + + @Override + public IntegrationAccountAgreementImpl withMetadata(Object metadata) { + this.inner().withMetadata(metadata); + return this; + } + + @Override + public IntegrationAccountAgreementImpl withTags(Map tags) { + this.inner().withTags(tags); + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAgreementInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAgreementInner.java new file mode 100644 index 000000000000..5dd42cfa75d4 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAgreementInner.java @@ -0,0 +1,241 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.AgreementType; +import com.microsoft.azure.management.logic.v2019_05_01.BusinessIdentity; +import com.microsoft.azure.management.logic.v2019_05_01.AgreementContent; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The integration account agreement. + */ +@JsonFlatten +@SkipParentValidation +public class IntegrationAccountAgreementInner extends Resource { + /** + * The created time. + */ + @JsonProperty(value = "properties.createdTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime createdTime; + + /** + * The changed time. + */ + @JsonProperty(value = "properties.changedTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime changedTime; + + /** + * The metadata. + */ + @JsonProperty(value = "properties.metadata") + private Object metadata; + + /** + * The agreement type. Possible values include: 'NotSpecified', 'AS2', + * 'X12', 'Edifact'. + */ + @JsonProperty(value = "properties.agreementType", required = true) + private AgreementType agreementType; + + /** + * The integration account partner that is set as host partner for this + * agreement. + */ + @JsonProperty(value = "properties.hostPartner", required = true) + private String hostPartner; + + /** + * The integration account partner that is set as guest partner for this + * agreement. + */ + @JsonProperty(value = "properties.guestPartner", required = true) + private String guestPartner; + + /** + * The business identity of the host partner. + */ + @JsonProperty(value = "properties.hostIdentity", required = true) + private BusinessIdentity hostIdentity; + + /** + * The business identity of the guest partner. + */ + @JsonProperty(value = "properties.guestIdentity", required = true) + private BusinessIdentity guestIdentity; + + /** + * The agreement content. + */ + @JsonProperty(value = "properties.content", required = true) + private AgreementContent content; + + /** + * Get the created time. + * + * @return the createdTime value + */ + public DateTime createdTime() { + return this.createdTime; + } + + /** + * Get the changed time. + * + * @return the changedTime value + */ + public DateTime changedTime() { + return this.changedTime; + } + + /** + * Get the metadata. + * + * @return the metadata value + */ + public Object metadata() { + return this.metadata; + } + + /** + * Set the metadata. + * + * @param metadata the metadata value to set + * @return the IntegrationAccountAgreementInner object itself. + */ + public IntegrationAccountAgreementInner withMetadata(Object metadata) { + this.metadata = metadata; + return this; + } + + /** + * Get the agreement type. Possible values include: 'NotSpecified', 'AS2', 'X12', 'Edifact'. + * + * @return the agreementType value + */ + public AgreementType agreementType() { + return this.agreementType; + } + + /** + * Set the agreement type. Possible values include: 'NotSpecified', 'AS2', 'X12', 'Edifact'. + * + * @param agreementType the agreementType value to set + * @return the IntegrationAccountAgreementInner object itself. + */ + public IntegrationAccountAgreementInner withAgreementType(AgreementType agreementType) { + this.agreementType = agreementType; + return this; + } + + /** + * Get the integration account partner that is set as host partner for this agreement. + * + * @return the hostPartner value + */ + public String hostPartner() { + return this.hostPartner; + } + + /** + * Set the integration account partner that is set as host partner for this agreement. + * + * @param hostPartner the hostPartner value to set + * @return the IntegrationAccountAgreementInner object itself. + */ + public IntegrationAccountAgreementInner withHostPartner(String hostPartner) { + this.hostPartner = hostPartner; + return this; + } + + /** + * Get the integration account partner that is set as guest partner for this agreement. + * + * @return the guestPartner value + */ + public String guestPartner() { + return this.guestPartner; + } + + /** + * Set the integration account partner that is set as guest partner for this agreement. + * + * @param guestPartner the guestPartner value to set + * @return the IntegrationAccountAgreementInner object itself. + */ + public IntegrationAccountAgreementInner withGuestPartner(String guestPartner) { + this.guestPartner = guestPartner; + return this; + } + + /** + * Get the business identity of the host partner. + * + * @return the hostIdentity value + */ + public BusinessIdentity hostIdentity() { + return this.hostIdentity; + } + + /** + * Set the business identity of the host partner. + * + * @param hostIdentity the hostIdentity value to set + * @return the IntegrationAccountAgreementInner object itself. + */ + public IntegrationAccountAgreementInner withHostIdentity(BusinessIdentity hostIdentity) { + this.hostIdentity = hostIdentity; + return this; + } + + /** + * Get the business identity of the guest partner. + * + * @return the guestIdentity value + */ + public BusinessIdentity guestIdentity() { + return this.guestIdentity; + } + + /** + * Set the business identity of the guest partner. + * + * @param guestIdentity the guestIdentity value to set + * @return the IntegrationAccountAgreementInner object itself. + */ + public IntegrationAccountAgreementInner withGuestIdentity(BusinessIdentity guestIdentity) { + this.guestIdentity = guestIdentity; + return this; + } + + /** + * Get the agreement content. + * + * @return the content value + */ + public AgreementContent content() { + return this.content; + } + + /** + * Set the agreement content. + * + * @param content the content value to set + * @return the IntegrationAccountAgreementInner object itself. + */ + public IntegrationAccountAgreementInner withContent(AgreementContent content) { + this.content = content; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAgreementsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAgreementsImpl.java new file mode 100644 index 000000000000..e96bba955ab0 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAgreementsImpl.java @@ -0,0 +1,99 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAgreements; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2019_05_01.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAgreement; + +class IntegrationAccountAgreementsImpl extends WrapperImpl implements IntegrationAccountAgreements { + private final LogicManager manager; + + IntegrationAccountAgreementsImpl(LogicManager manager) { + super(manager.inner().integrationAccountAgreements()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + @Override + public IntegrationAccountAgreementImpl define(String name) { + return wrapModel(name); + } + + private IntegrationAccountAgreementImpl wrapModel(IntegrationAccountAgreementInner inner) { + return new IntegrationAccountAgreementImpl(inner, manager()); + } + + private IntegrationAccountAgreementImpl wrapModel(String name) { + return new IntegrationAccountAgreementImpl(name, this.manager()); + } + + @Override + public Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String agreementName, GetCallbackUrlParameters listContentCallbackUrl) { + IntegrationAccountAgreementsInner client = this.inner(); + return client.listContentCallbackUrlAsync(resourceGroupName, integrationAccountName, agreementName, listContentCallbackUrl) + .map(new Func1() { + @Override + public WorkflowTriggerCallbackUrl call(WorkflowTriggerCallbackUrlInner inner) { + return new WorkflowTriggerCallbackUrlImpl(inner, manager()); + } + }); + } + + @Override + public Observable listAsync(final String resourceGroupName, final String integrationAccountName) { + IntegrationAccountAgreementsInner client = this.inner(); + return client.listAsync(resourceGroupName, integrationAccountName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public IntegrationAccountAgreement call(IntegrationAccountAgreementInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String integrationAccountName, String agreementName) { + IntegrationAccountAgreementsInner client = this.inner(); + return client.getAsync(resourceGroupName, integrationAccountName, agreementName) + .flatMap(new Func1>() { + @Override + public Observable call(IntegrationAccountAgreementInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((IntegrationAccountAgreement)wrapModel(inner)); + } + } + }); + } + + @Override + public Completable deleteAsync(String resourceGroupName, String integrationAccountName, String agreementName) { + IntegrationAccountAgreementsInner client = this.inner(); + return client.deleteAsync(resourceGroupName, integrationAccountName, agreementName).toCompletable(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAgreementsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAgreementsInner.java new file mode 100644 index 000000000000..ffc5f37c51fb --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAgreementsInner.java @@ -0,0 +1,843 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.management.logic.v2019_05_01.GetCallbackUrlParameters; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import com.microsoft.rest.Validator; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.Body; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.HTTP; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.PUT; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationAccountAgreements. + */ +public class IntegrationAccountAgreementsInner { + /** The Retrofit service to perform REST calls. */ + private IntegrationAccountAgreementsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationAccountAgreementsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationAccountAgreementsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationAccountAgreementsService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationAccountAgreements to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationAccountAgreementsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAgreements list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/agreements") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Query("$filter") String filter, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAgreements get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/agreements/{agreementName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("agreementName") String agreementName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAgreements createOrUpdate" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/agreements/{agreementName}") + Observable> createOrUpdate(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("agreementName") String agreementName, @Query("api-version") String apiVersion, @Body IntegrationAccountAgreementInner agreement, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAgreements delete" }) + @HTTP(path = "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/agreements/{agreementName}", method = "DELETE", hasBody = true) + Observable> delete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("agreementName") String agreementName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAgreements listContentCallbackUrl" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/agreements/{agreementName}/listContentCallbackUrl") + Observable> listContentCallbackUrl(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("agreementName") String agreementName, @Query("api-version") String apiVersion, @Body GetCallbackUrlParameters listContentCallbackUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAgreements listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of integration account agreements. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountAgreementInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String integrationAccountName) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, integrationAccountName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account agreements. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String integrationAccountName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, integrationAccountName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account agreements. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountAgreementInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String integrationAccountName) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account agreements. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountAgreementInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String integrationAccountName) { + return listSinglePageAsync(resourceGroupName, integrationAccountName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account agreements. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountAgreementInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String integrationAccountName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + final String filter = null; + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of integration account agreements. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: AgreementType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountAgreementInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account agreements. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: AgreementType. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account agreements. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: AgreementType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountAgreementInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName, top, filter) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account agreements. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: AgreementType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountAgreementInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + return listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account agreements. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param integrationAccountName The integration account name. + ServiceResponse> * @param top The number of items to be included in the result. + ServiceResponse> * @param filter The filter to apply on the operation. Options for filters include: AgreementType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountAgreementInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountAgreementInner object if successful. + */ + public IntegrationAccountAgreementInner get(String resourceGroupName, String integrationAccountName, String agreementName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, agreementName).toBlocking().single().body(); + } + + /** + * Gets an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String integrationAccountName, String agreementName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, integrationAccountName, agreementName), serviceCallback); + } + + /** + * Gets an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountAgreementInner object + */ + public Observable getAsync(String resourceGroupName, String integrationAccountName, String agreementName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, agreementName).map(new Func1, IntegrationAccountAgreementInner>() { + @Override + public IntegrationAccountAgreementInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountAgreementInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String agreementName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (agreementName == null) { + throw new IllegalArgumentException("Parameter agreementName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, integrationAccountName, agreementName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Creates or updates an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @param agreement The integration account agreement. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountAgreementInner object if successful. + */ + public IntegrationAccountAgreementInner createOrUpdate(String resourceGroupName, String integrationAccountName, String agreementName, IntegrationAccountAgreementInner agreement) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, agreementName, agreement).toBlocking().single().body(); + } + + /** + * Creates or updates an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @param agreement The integration account agreement. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String agreementName, IntegrationAccountAgreementInner agreement, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, agreementName, agreement), serviceCallback); + } + + /** + * Creates or updates an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @param agreement The integration account agreement. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountAgreementInner object + */ + public Observable createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String agreementName, IntegrationAccountAgreementInner agreement) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, agreementName, agreement).map(new Func1, IntegrationAccountAgreementInner>() { + @Override + public IntegrationAccountAgreementInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Creates or updates an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @param agreement The integration account agreement. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountAgreementInner object + */ + public Observable> createOrUpdateWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String agreementName, IntegrationAccountAgreementInner agreement) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (agreementName == null) { + throw new IllegalArgumentException("Parameter agreementName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (agreement == null) { + throw new IllegalArgumentException("Parameter agreement is required and cannot be null."); + } + Validator.validate(agreement); + return service.createOrUpdate(this.client.subscriptionId(), resourceGroupName, integrationAccountName, agreementName, this.client.apiVersion(), agreement, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = createOrUpdateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse createOrUpdateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Deletes an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void delete(String resourceGroupName, String integrationAccountName, String agreementName) { + deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, agreementName).toBlocking().single().body(); + } + + /** + * Deletes an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture deleteAsync(String resourceGroupName, String integrationAccountName, String agreementName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, agreementName), serviceCallback); + } + + /** + * Deletes an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable deleteAsync(String resourceGroupName, String integrationAccountName, String agreementName) { + return deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, agreementName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Deletes an integration account agreement. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> deleteWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String agreementName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (agreementName == null) { + throw new IllegalArgumentException("Parameter agreementName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.delete(this.client.subscriptionId(), resourceGroupName, integrationAccountName, agreementName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = deleteDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse deleteDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowTriggerCallbackUrlInner object if successful. + */ + public WorkflowTriggerCallbackUrlInner listContentCallbackUrl(String resourceGroupName, String integrationAccountName, String agreementName, GetCallbackUrlParameters listContentCallbackUrl) { + return listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, agreementName, listContentCallbackUrl).toBlocking().single().body(); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String agreementName, GetCallbackUrlParameters listContentCallbackUrl, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, agreementName, listContentCallbackUrl), serviceCallback); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String agreementName, GetCallbackUrlParameters listContentCallbackUrl) { + return listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, agreementName, listContentCallbackUrl).map(new Func1, WorkflowTriggerCallbackUrlInner>() { + @Override + public WorkflowTriggerCallbackUrlInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param agreementName The integration account agreement name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable> listContentCallbackUrlWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String agreementName, GetCallbackUrlParameters listContentCallbackUrl) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (agreementName == null) { + throw new IllegalArgumentException("Parameter agreementName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (listContentCallbackUrl == null) { + throw new IllegalArgumentException("Parameter listContentCallbackUrl is required and cannot be null."); + } + Validator.validate(listContentCallbackUrl); + return service.listContentCallbackUrl(this.client.subscriptionId(), resourceGroupName, integrationAccountName, agreementName, this.client.apiVersion(), listContentCallbackUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = listContentCallbackUrlDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse listContentCallbackUrlDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of integration account agreements. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountAgreementInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account agreements. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account agreements. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountAgreementInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account agreements. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountAgreementInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account agreements. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountAgreementInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAssembliesImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAssembliesImpl.java new file mode 100644 index 000000000000..c4a38f8fd50f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAssembliesImpl.java @@ -0,0 +1,98 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAssemblies; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2019_05_01.AssemblyDefinition; + +class IntegrationAccountAssembliesImpl extends WrapperImpl implements IntegrationAccountAssemblies { + private final LogicManager manager; + + IntegrationAccountAssembliesImpl(LogicManager manager) { + super(manager.inner().integrationAccountAssemblies()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + @Override + public AssemblyDefinitionImpl define(String name) { + return wrapModel(name); + } + + private AssemblyDefinitionImpl wrapModel(AssemblyDefinitionInner inner) { + return new AssemblyDefinitionImpl(inner, manager()); + } + + private AssemblyDefinitionImpl wrapModel(String name) { + return new AssemblyDefinitionImpl(name, this.manager()); + } + + @Override + public Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName) { + IntegrationAccountAssembliesInner client = this.inner(); + return client.listContentCallbackUrlAsync(resourceGroupName, integrationAccountName, assemblyArtifactName) + .map(new Func1() { + @Override + public WorkflowTriggerCallbackUrl call(WorkflowTriggerCallbackUrlInner inner) { + return new WorkflowTriggerCallbackUrlImpl(inner, manager()); + } + }); + } + + @Override + public Observable listAsync(String resourceGroupName, String integrationAccountName) { + IntegrationAccountAssembliesInner client = this.inner(); + return client.listAsync(resourceGroupName, integrationAccountName) + .flatMap(new Func1, Observable>() { + @Override + public Observable call(List innerList) { + return Observable.from(innerList); + } + }) + .map(new Func1() { + @Override + public AssemblyDefinition call(AssemblyDefinitionInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName) { + IntegrationAccountAssembliesInner client = this.inner(); + return client.getAsync(resourceGroupName, integrationAccountName, assemblyArtifactName) + .flatMap(new Func1>() { + @Override + public Observable call(AssemblyDefinitionInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((AssemblyDefinition)wrapModel(inner)); + } + } + }); + } + + @Override + public Completable deleteAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName) { + IntegrationAccountAssembliesInner client = this.inner(); + return client.deleteAsync(resourceGroupName, integrationAccountName, assemblyArtifactName).toCompletable(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAssembliesInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAssembliesInner.java new file mode 100644 index 000000000000..7b52dd6a0d89 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountAssembliesInner.java @@ -0,0 +1,554 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import com.microsoft.rest.Validator; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.Body; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.HTTP; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.PUT; +import retrofit2.http.Query; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationAccountAssemblies. + */ +public class IntegrationAccountAssembliesInner { + /** The Retrofit service to perform REST calls. */ + private IntegrationAccountAssembliesService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationAccountAssembliesInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationAccountAssembliesInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationAccountAssembliesService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationAccountAssemblies to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationAccountAssembliesService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAssemblies list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/assemblies") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAssemblies get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/assemblies/{assemblyArtifactName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("assemblyArtifactName") String assemblyArtifactName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAssemblies createOrUpdate" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/assemblies/{assemblyArtifactName}") + Observable> createOrUpdate(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("assemblyArtifactName") String assemblyArtifactName, @Body AssemblyDefinitionInner assemblyArtifact, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAssemblies delete" }) + @HTTP(path = "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/assemblies/{assemblyArtifactName}", method = "DELETE", hasBody = true) + Observable> delete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("assemblyArtifactName") String assemblyArtifactName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAssemblies listContentCallbackUrl" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/assemblies/{assemblyArtifactName}/listContentCallbackUrl") + Observable> listContentCallbackUrl(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("assemblyArtifactName") String assemblyArtifactName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * List the assemblies for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the List<AssemblyDefinitionInner> object if successful. + */ + public List list(String resourceGroupName, String integrationAccountName) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName).toBlocking().single().body(); + } + + /** + * List the assemblies for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(String resourceGroupName, String integrationAccountName, final ServiceCallback> serviceCallback) { + return ServiceFuture.fromResponse(listWithServiceResponseAsync(resourceGroupName, integrationAccountName), serviceCallback); + } + + /** + * List the assemblies for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<AssemblyDefinitionInner> object + */ + public Observable> listAsync(String resourceGroupName, String integrationAccountName) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName).map(new Func1>, List>() { + @Override + public List call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * List the assemblies for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<AssemblyDefinitionInner> object + */ + public Observable>> listWithServiceResponseAsync(String resourceGroupName, String integrationAccountName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + List items = null; + if (result.body() != null) { + items = result.body().items(); + } + ServiceResponse> clientResponse = new ServiceResponse>(items, result.response()); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Get an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the AssemblyDefinitionInner object if successful. + */ + public AssemblyDefinitionInner get(String resourceGroupName, String integrationAccountName, String assemblyArtifactName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, assemblyArtifactName).toBlocking().single().body(); + } + + /** + * Get an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, integrationAccountName, assemblyArtifactName), serviceCallback); + } + + /** + * Get an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the AssemblyDefinitionInner object + */ + public Observable getAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, assemblyArtifactName).map(new Func1, AssemblyDefinitionInner>() { + @Override + public AssemblyDefinitionInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the AssemblyDefinitionInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (assemblyArtifactName == null) { + throw new IllegalArgumentException("Parameter assemblyArtifactName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, integrationAccountName, assemblyArtifactName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Create or update an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @param assemblyArtifact The assembly artifact. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the AssemblyDefinitionInner object if successful. + */ + public AssemblyDefinitionInner createOrUpdate(String resourceGroupName, String integrationAccountName, String assemblyArtifactName, AssemblyDefinitionInner assemblyArtifact) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, assemblyArtifactName, assemblyArtifact).toBlocking().single().body(); + } + + /** + * Create or update an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @param assemblyArtifact The assembly artifact. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName, AssemblyDefinitionInner assemblyArtifact, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, assemblyArtifactName, assemblyArtifact), serviceCallback); + } + + /** + * Create or update an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @param assemblyArtifact The assembly artifact. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the AssemblyDefinitionInner object + */ + public Observable createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName, AssemblyDefinitionInner assemblyArtifact) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, assemblyArtifactName, assemblyArtifact).map(new Func1, AssemblyDefinitionInner>() { + @Override + public AssemblyDefinitionInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Create or update an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @param assemblyArtifact The assembly artifact. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the AssemblyDefinitionInner object + */ + public Observable> createOrUpdateWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName, AssemblyDefinitionInner assemblyArtifact) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (assemblyArtifactName == null) { + throw new IllegalArgumentException("Parameter assemblyArtifactName is required and cannot be null."); + } + if (assemblyArtifact == null) { + throw new IllegalArgumentException("Parameter assemblyArtifact is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + Validator.validate(assemblyArtifact); + return service.createOrUpdate(this.client.subscriptionId(), resourceGroupName, integrationAccountName, assemblyArtifactName, assemblyArtifact, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = createOrUpdateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse createOrUpdateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Delete an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void delete(String resourceGroupName, String integrationAccountName, String assemblyArtifactName) { + deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, assemblyArtifactName).toBlocking().single().body(); + } + + /** + * Delete an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture deleteAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, assemblyArtifactName), serviceCallback); + } + + /** + * Delete an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable deleteAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName) { + return deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, assemblyArtifactName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Delete an assembly for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> deleteWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (assemblyArtifactName == null) { + throw new IllegalArgumentException("Parameter assemblyArtifactName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.delete(this.client.subscriptionId(), resourceGroupName, integrationAccountName, assemblyArtifactName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = deleteDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse deleteDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Get the content callback url for an integration account assembly. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowTriggerCallbackUrlInner object if successful. + */ + public WorkflowTriggerCallbackUrlInner listContentCallbackUrl(String resourceGroupName, String integrationAccountName, String assemblyArtifactName) { + return listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, assemblyArtifactName).toBlocking().single().body(); + } + + /** + * Get the content callback url for an integration account assembly. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, assemblyArtifactName), serviceCallback); + } + + /** + * Get the content callback url for an integration account assembly. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName) { + return listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, assemblyArtifactName).map(new Func1, WorkflowTriggerCallbackUrlInner>() { + @Override + public WorkflowTriggerCallbackUrlInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get the content callback url for an integration account assembly. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param assemblyArtifactName The assembly artifact name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable> listContentCallbackUrlWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String assemblyArtifactName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (assemblyArtifactName == null) { + throw new IllegalArgumentException("Parameter assemblyArtifactName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.listContentCallbackUrl(this.client.subscriptionId(), resourceGroupName, integrationAccountName, assemblyArtifactName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = listContentCallbackUrlDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse listContentCallbackUrlDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountBatchConfigurationsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountBatchConfigurationsImpl.java new file mode 100644 index 000000000000..e2fd45e7bcde --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountBatchConfigurationsImpl.java @@ -0,0 +1,85 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountBatchConfigurations; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.BatchConfiguration; + +class IntegrationAccountBatchConfigurationsImpl extends WrapperImpl implements IntegrationAccountBatchConfigurations { + private final LogicManager manager; + + IntegrationAccountBatchConfigurationsImpl(LogicManager manager) { + super(manager.inner().integrationAccountBatchConfigurations()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + @Override + public BatchConfigurationImpl define(String name) { + return wrapModel(name); + } + + private BatchConfigurationImpl wrapModel(BatchConfigurationInner inner) { + return new BatchConfigurationImpl(inner, manager()); + } + + private BatchConfigurationImpl wrapModel(String name) { + return new BatchConfigurationImpl(name, this.manager()); + } + + @Override + public Observable listAsync(String resourceGroupName, String integrationAccountName) { + IntegrationAccountBatchConfigurationsInner client = this.inner(); + return client.listAsync(resourceGroupName, integrationAccountName) + .flatMap(new Func1, Observable>() { + @Override + public Observable call(List innerList) { + return Observable.from(innerList); + } + }) + .map(new Func1() { + @Override + public BatchConfiguration call(BatchConfigurationInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String integrationAccountName, String batchConfigurationName) { + IntegrationAccountBatchConfigurationsInner client = this.inner(); + return client.getAsync(resourceGroupName, integrationAccountName, batchConfigurationName) + .flatMap(new Func1>() { + @Override + public Observable call(BatchConfigurationInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((BatchConfiguration)wrapModel(inner)); + } + } + }); + } + + @Override + public Completable deleteAsync(String resourceGroupName, String integrationAccountName, String batchConfigurationName) { + IntegrationAccountBatchConfigurationsInner client = this.inner(); + return client.deleteAsync(resourceGroupName, integrationAccountName, batchConfigurationName).toCompletable(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountBatchConfigurationsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountBatchConfigurationsInner.java new file mode 100644 index 000000000000..4d37c3f3a63a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountBatchConfigurationsInner.java @@ -0,0 +1,456 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import com.microsoft.rest.Validator; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.Body; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.HTTP; +import retrofit2.http.Path; +import retrofit2.http.PUT; +import retrofit2.http.Query; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationAccountBatchConfigurations. + */ +public class IntegrationAccountBatchConfigurationsInner { + /** The Retrofit service to perform REST calls. */ + private IntegrationAccountBatchConfigurationsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationAccountBatchConfigurationsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationAccountBatchConfigurationsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationAccountBatchConfigurationsService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationAccountBatchConfigurations to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationAccountBatchConfigurationsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountBatchConfigurations list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/batchConfigurations") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountBatchConfigurations get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/batchConfigurations/{batchConfigurationName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("batchConfigurationName") String batchConfigurationName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountBatchConfigurations createOrUpdate" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/batchConfigurations/{batchConfigurationName}") + Observable> createOrUpdate(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("batchConfigurationName") String batchConfigurationName, @Body BatchConfigurationInner batchConfiguration, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountBatchConfigurations delete" }) + @HTTP(path = "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/batchConfigurations/{batchConfigurationName}", method = "DELETE", hasBody = true) + Observable> delete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("batchConfigurationName") String batchConfigurationName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * List the batch configurations for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the List<BatchConfigurationInner> object if successful. + */ + public List list(String resourceGroupName, String integrationAccountName) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName).toBlocking().single().body(); + } + + /** + * List the batch configurations for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(String resourceGroupName, String integrationAccountName, final ServiceCallback> serviceCallback) { + return ServiceFuture.fromResponse(listWithServiceResponseAsync(resourceGroupName, integrationAccountName), serviceCallback); + } + + /** + * List the batch configurations for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<BatchConfigurationInner> object + */ + public Observable> listAsync(String resourceGroupName, String integrationAccountName) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName).map(new Func1>, List>() { + @Override + public List call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * List the batch configurations for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<BatchConfigurationInner> object + */ + public Observable>> listWithServiceResponseAsync(String resourceGroupName, String integrationAccountName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + List items = null; + if (result.body() != null) { + items = result.body().items(); + } + ServiceResponse> clientResponse = new ServiceResponse>(items, result.response()); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Get a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the BatchConfigurationInner object if successful. + */ + public BatchConfigurationInner get(String resourceGroupName, String integrationAccountName, String batchConfigurationName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, batchConfigurationName).toBlocking().single().body(); + } + + /** + * Get a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String integrationAccountName, String batchConfigurationName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, integrationAccountName, batchConfigurationName), serviceCallback); + } + + /** + * Get a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the BatchConfigurationInner object + */ + public Observable getAsync(String resourceGroupName, String integrationAccountName, String batchConfigurationName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, batchConfigurationName).map(new Func1, BatchConfigurationInner>() { + @Override + public BatchConfigurationInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the BatchConfigurationInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String batchConfigurationName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (batchConfigurationName == null) { + throw new IllegalArgumentException("Parameter batchConfigurationName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, integrationAccountName, batchConfigurationName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Create or update a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @param batchConfiguration The batch configuration. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the BatchConfigurationInner object if successful. + */ + public BatchConfigurationInner createOrUpdate(String resourceGroupName, String integrationAccountName, String batchConfigurationName, BatchConfigurationInner batchConfiguration) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, batchConfigurationName, batchConfiguration).toBlocking().single().body(); + } + + /** + * Create or update a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @param batchConfiguration The batch configuration. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String batchConfigurationName, BatchConfigurationInner batchConfiguration, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, batchConfigurationName, batchConfiguration), serviceCallback); + } + + /** + * Create or update a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @param batchConfiguration The batch configuration. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the BatchConfigurationInner object + */ + public Observable createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String batchConfigurationName, BatchConfigurationInner batchConfiguration) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, batchConfigurationName, batchConfiguration).map(new Func1, BatchConfigurationInner>() { + @Override + public BatchConfigurationInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Create or update a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @param batchConfiguration The batch configuration. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the BatchConfigurationInner object + */ + public Observable> createOrUpdateWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String batchConfigurationName, BatchConfigurationInner batchConfiguration) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (batchConfigurationName == null) { + throw new IllegalArgumentException("Parameter batchConfigurationName is required and cannot be null."); + } + if (batchConfiguration == null) { + throw new IllegalArgumentException("Parameter batchConfiguration is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + Validator.validate(batchConfiguration); + return service.createOrUpdate(this.client.subscriptionId(), resourceGroupName, integrationAccountName, batchConfigurationName, batchConfiguration, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = createOrUpdateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse createOrUpdateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Delete a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void delete(String resourceGroupName, String integrationAccountName, String batchConfigurationName) { + deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, batchConfigurationName).toBlocking().single().body(); + } + + /** + * Delete a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture deleteAsync(String resourceGroupName, String integrationAccountName, String batchConfigurationName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, batchConfigurationName), serviceCallback); + } + + /** + * Delete a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable deleteAsync(String resourceGroupName, String integrationAccountName, String batchConfigurationName) { + return deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, batchConfigurationName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Delete a batch configuration for an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param batchConfigurationName The batch configuration name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> deleteWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String batchConfigurationName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (batchConfigurationName == null) { + throw new IllegalArgumentException("Parameter batchConfigurationName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.delete(this.client.subscriptionId(), resourceGroupName, integrationAccountName, batchConfigurationName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = deleteDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse deleteDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountCertificateImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountCertificateImpl.java new file mode 100644 index 000000000000..8575115b8b94 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountCertificateImpl.java @@ -0,0 +1,162 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountCertificate; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import java.util.Map; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.KeyVaultKeyReference; + +class IntegrationAccountCertificateImpl extends CreatableUpdatableImpl implements IntegrationAccountCertificate, IntegrationAccountCertificate.Definition, IntegrationAccountCertificate.Update { + private final LogicManager manager; + private String resourceGroupName; + private String integrationAccountName; + private String certificateName; + + IntegrationAccountCertificateImpl(String name, LogicManager manager) { + super(name, new IntegrationAccountCertificateInner()); + this.manager = manager; + // Set resource name + this.certificateName = name; + // + } + + IntegrationAccountCertificateImpl(IntegrationAccountCertificateInner inner, LogicManager manager) { + super(inner.name(), inner); + this.manager = manager; + // Set resource name + this.certificateName = inner.name(); + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.integrationAccountName = IdParsingUtils.getValueFromIdByName(inner.id(), "integrationAccounts"); + this.certificateName = IdParsingUtils.getValueFromIdByName(inner.id(), "certificates"); + // + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public Observable createResourceAsync() { + IntegrationAccountCertificatesInner client = this.manager().inner().integrationAccountCertificates(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.certificateName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + public Observable updateResourceAsync() { + IntegrationAccountCertificatesInner client = this.manager().inner().integrationAccountCertificates(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.certificateName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + protected Observable getInnerAsync() { + IntegrationAccountCertificatesInner client = this.manager().inner().integrationAccountCertificates(); + return client.getAsync(this.resourceGroupName, this.integrationAccountName, this.certificateName); + } + + @Override + public boolean isInCreateMode() { + return this.inner().id() == null; + } + + + @Override + public DateTime changedTime() { + return this.inner().changedTime(); + } + + @Override + public DateTime createdTime() { + return this.inner().createdTime(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public KeyVaultKeyReference keyVal() { + return this.inner().key(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public Object metadata() { + return this.inner().metadata(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public String publicCertificate() { + return this.inner().publicCertificate(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public String type() { + return this.inner().type(); + } + + @Override + public IntegrationAccountCertificateImpl withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName) { + this.resourceGroupName = resourceGroupName; + this.integrationAccountName = integrationAccountName; + return this; + } + + @Override + public IntegrationAccountCertificateImpl withKey(KeyVaultKeyReference key) { + this.inner().withKey(key); + return this; + } + + @Override + public IntegrationAccountCertificateImpl withLocation(String location) { + this.inner().withLocation(location); + return this; + } + + @Override + public IntegrationAccountCertificateImpl withMetadata(Object metadata) { + this.inner().withMetadata(metadata); + return this; + } + + @Override + public IntegrationAccountCertificateImpl withPublicCertificate(String publicCertificate) { + this.inner().withPublicCertificate(publicCertificate); + return this; + } + + @Override + public IntegrationAccountCertificateImpl withTags(Map tags) { + this.inner().withTags(tags); + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountCertificateInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountCertificateInner.java new file mode 100644 index 000000000000..9c30c499a381 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountCertificateInner.java @@ -0,0 +1,132 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.KeyVaultKeyReference; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The integration account certificate. + */ +@JsonFlatten +@SkipParentValidation +public class IntegrationAccountCertificateInner extends Resource { + /** + * The created time. + */ + @JsonProperty(value = "properties.createdTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime createdTime; + + /** + * The changed time. + */ + @JsonProperty(value = "properties.changedTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime changedTime; + + /** + * The metadata. + */ + @JsonProperty(value = "properties.metadata") + private Object metadata; + + /** + * The key details in the key vault. + */ + @JsonProperty(value = "properties.key") + private KeyVaultKeyReference key; + + /** + * The public certificate. + */ + @JsonProperty(value = "properties.publicCertificate") + private String publicCertificate; + + /** + * Get the created time. + * + * @return the createdTime value + */ + public DateTime createdTime() { + return this.createdTime; + } + + /** + * Get the changed time. + * + * @return the changedTime value + */ + public DateTime changedTime() { + return this.changedTime; + } + + /** + * Get the metadata. + * + * @return the metadata value + */ + public Object metadata() { + return this.metadata; + } + + /** + * Set the metadata. + * + * @param metadata the metadata value to set + * @return the IntegrationAccountCertificateInner object itself. + */ + public IntegrationAccountCertificateInner withMetadata(Object metadata) { + this.metadata = metadata; + return this; + } + + /** + * Get the key details in the key vault. + * + * @return the key value + */ + public KeyVaultKeyReference key() { + return this.key; + } + + /** + * Set the key details in the key vault. + * + * @param key the key value to set + * @return the IntegrationAccountCertificateInner object itself. + */ + public IntegrationAccountCertificateInner withKey(KeyVaultKeyReference key) { + this.key = key; + return this; + } + + /** + * Get the public certificate. + * + * @return the publicCertificate value + */ + public String publicCertificate() { + return this.publicCertificate; + } + + /** + * Set the public certificate. + * + * @param publicCertificate the publicCertificate value to set + * @return the IntegrationAccountCertificateInner object itself. + */ + public IntegrationAccountCertificateInner withPublicCertificate(String publicCertificate) { + this.publicCertificate = publicCertificate; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountCertificatesImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountCertificatesImpl.java new file mode 100644 index 000000000000..ab1679869a81 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountCertificatesImpl.java @@ -0,0 +1,85 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountCertificates; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountCertificate; + +class IntegrationAccountCertificatesImpl extends WrapperImpl implements IntegrationAccountCertificates { + private final LogicManager manager; + + IntegrationAccountCertificatesImpl(LogicManager manager) { + super(manager.inner().integrationAccountCertificates()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + @Override + public IntegrationAccountCertificateImpl define(String name) { + return wrapModel(name); + } + + private IntegrationAccountCertificateImpl wrapModel(IntegrationAccountCertificateInner inner) { + return new IntegrationAccountCertificateImpl(inner, manager()); + } + + private IntegrationAccountCertificateImpl wrapModel(String name) { + return new IntegrationAccountCertificateImpl(name, this.manager()); + } + + @Override + public Observable listAsync(final String resourceGroupName, final String integrationAccountName) { + IntegrationAccountCertificatesInner client = this.inner(); + return client.listAsync(resourceGroupName, integrationAccountName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public IntegrationAccountCertificate call(IntegrationAccountCertificateInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String integrationAccountName, String certificateName) { + IntegrationAccountCertificatesInner client = this.inner(); + return client.getAsync(resourceGroupName, integrationAccountName, certificateName) + .flatMap(new Func1>() { + @Override + public Observable call(IntegrationAccountCertificateInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((IntegrationAccountCertificate)wrapModel(inner)); + } + } + }); + } + + @Override + public Completable deleteAsync(String resourceGroupName, String integrationAccountName, String certificateName) { + IntegrationAccountCertificatesInner client = this.inner(); + return client.deleteAsync(resourceGroupName, integrationAccountName, certificateName).toCompletable(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountCertificatesInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountCertificatesInner.java new file mode 100644 index 000000000000..8b7ed2e4618b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountCertificatesInner.java @@ -0,0 +1,730 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import com.microsoft.rest.Validator; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.Body; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.HTTP; +import retrofit2.http.Path; +import retrofit2.http.PUT; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationAccountCertificates. + */ +public class IntegrationAccountCertificatesInner { + /** The Retrofit service to perform REST calls. */ + private IntegrationAccountCertificatesService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationAccountCertificatesInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationAccountCertificatesInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationAccountCertificatesService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationAccountCertificates to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationAccountCertificatesService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountCertificates list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/certificates") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountCertificates get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/certificates/{certificateName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("certificateName") String certificateName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountCertificates createOrUpdate" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/certificates/{certificateName}") + Observable> createOrUpdate(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("certificateName") String certificateName, @Query("api-version") String apiVersion, @Body IntegrationAccountCertificateInner certificate, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountCertificates delete" }) + @HTTP(path = "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/certificates/{certificateName}", method = "DELETE", hasBody = true) + Observable> delete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("certificateName") String certificateName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountCertificates listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of integration account certificates. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountCertificateInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String integrationAccountName) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, integrationAccountName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account certificates. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String integrationAccountName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, integrationAccountName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account certificates. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountCertificateInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String integrationAccountName) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account certificates. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountCertificateInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String integrationAccountName) { + return listSinglePageAsync(resourceGroupName, integrationAccountName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account certificates. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountCertificateInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String integrationAccountName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), top, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of integration account certificates. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountCertificateInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String integrationAccountName, final Integer top) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, integrationAccountName, top).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account certificates. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, integrationAccountName, top), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account certificates. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountCertificateInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String integrationAccountName, final Integer top) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName, top) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account certificates. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountCertificateInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String integrationAccountName, final Integer top) { + return listSinglePageAsync(resourceGroupName, integrationAccountName, top) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account certificates. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param integrationAccountName The integration account name. + ServiceResponse> * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountCertificateInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String integrationAccountName, final Integer top) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), top, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountCertificateInner object if successful. + */ + public IntegrationAccountCertificateInner get(String resourceGroupName, String integrationAccountName, String certificateName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, certificateName).toBlocking().single().body(); + } + + /** + * Gets an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String integrationAccountName, String certificateName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, integrationAccountName, certificateName), serviceCallback); + } + + /** + * Gets an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountCertificateInner object + */ + public Observable getAsync(String resourceGroupName, String integrationAccountName, String certificateName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, certificateName).map(new Func1, IntegrationAccountCertificateInner>() { + @Override + public IntegrationAccountCertificateInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountCertificateInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String certificateName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (certificateName == null) { + throw new IllegalArgumentException("Parameter certificateName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, integrationAccountName, certificateName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Creates or updates an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @param certificate The integration account certificate. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountCertificateInner object if successful. + */ + public IntegrationAccountCertificateInner createOrUpdate(String resourceGroupName, String integrationAccountName, String certificateName, IntegrationAccountCertificateInner certificate) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, certificateName, certificate).toBlocking().single().body(); + } + + /** + * Creates or updates an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @param certificate The integration account certificate. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String certificateName, IntegrationAccountCertificateInner certificate, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, certificateName, certificate), serviceCallback); + } + + /** + * Creates or updates an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @param certificate The integration account certificate. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountCertificateInner object + */ + public Observable createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String certificateName, IntegrationAccountCertificateInner certificate) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, certificateName, certificate).map(new Func1, IntegrationAccountCertificateInner>() { + @Override + public IntegrationAccountCertificateInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Creates or updates an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @param certificate The integration account certificate. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountCertificateInner object + */ + public Observable> createOrUpdateWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String certificateName, IntegrationAccountCertificateInner certificate) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (certificateName == null) { + throw new IllegalArgumentException("Parameter certificateName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (certificate == null) { + throw new IllegalArgumentException("Parameter certificate is required and cannot be null."); + } + Validator.validate(certificate); + return service.createOrUpdate(this.client.subscriptionId(), resourceGroupName, integrationAccountName, certificateName, this.client.apiVersion(), certificate, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = createOrUpdateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse createOrUpdateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Deletes an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void delete(String resourceGroupName, String integrationAccountName, String certificateName) { + deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, certificateName).toBlocking().single().body(); + } + + /** + * Deletes an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture deleteAsync(String resourceGroupName, String integrationAccountName, String certificateName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, certificateName), serviceCallback); + } + + /** + * Deletes an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable deleteAsync(String resourceGroupName, String integrationAccountName, String certificateName) { + return deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, certificateName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Deletes an integration account certificate. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param certificateName The integration account certificate name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> deleteWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String certificateName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (certificateName == null) { + throw new IllegalArgumentException("Parameter certificateName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.delete(this.client.subscriptionId(), resourceGroupName, integrationAccountName, certificateName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = deleteDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse deleteDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of integration account certificates. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountCertificateInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account certificates. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account certificates. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountCertificateInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account certificates. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountCertificateInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account certificates. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountCertificateInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountImpl.java new file mode 100644 index 000000000000..fd180767b805 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountImpl.java @@ -0,0 +1,87 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.resources.models.implementation.GroupableResourceCoreImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccount; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowState; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSku; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironment; + +class IntegrationAccountImpl extends GroupableResourceCoreImpl implements IntegrationAccount, IntegrationAccount.Definition, IntegrationAccount.Update { + IntegrationAccountImpl(String name, IntegrationAccountInner inner, LogicManager manager) { + super(name, inner, manager); + } + + @Override + public Observable createResourceAsync() { + IntegrationAccountsInner client = this.manager().inner().integrationAccounts(); + return client.createOrUpdateAsync(this.resourceGroupName(), this.name(), this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + public Observable updateResourceAsync() { + IntegrationAccountsInner client = this.manager().inner().integrationAccounts(); + return client.updateAsync(this.resourceGroupName(), this.name(), this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + protected Observable getInnerAsync() { + IntegrationAccountsInner client = this.manager().inner().integrationAccounts(); + return client.getByResourceGroupAsync(this.resourceGroupName(), this.name()); + } + + @Override + public boolean isInCreateMode() { + return this.inner().id() == null; + } + + + @Override + public IntegrationServiceEnvironment integrationServiceEnvironment() { + IntegrationServiceEnvironmentInner inner = this.inner().integrationServiceEnvironment(); + if (inner != null) { + return new IntegrationServiceEnvironmentImpl(inner.name(), inner, manager()); + } else { + return null; + } + } + + @Override + public IntegrationAccountSku sku() { + return this.inner().sku(); + } + + @Override + public WorkflowState state() { + return this.inner().state(); + } + + @Override + public IntegrationAccountImpl withIntegrationServiceEnvironment(IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + this.inner().withIntegrationServiceEnvironment(integrationServiceEnvironment); + return this; + } + + @Override + public IntegrationAccountImpl withSku(IntegrationAccountSku sku) { + this.inner().withSku(sku); + return this; + } + + @Override + public IntegrationAccountImpl withState(WorkflowState state) { + this.inner().withState(state); + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountInner.java new file mode 100644 index 000000000000..6a58d940c5be --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountInner.java @@ -0,0 +1,103 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowState; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSku; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The integration account. + */ +@JsonFlatten +@SkipParentValidation +public class IntegrationAccountInner extends Resource { + /** + * The integration service environment. + */ + @JsonProperty(value = "properties.integrationServiceEnvironment") + private IntegrationServiceEnvironmentInner integrationServiceEnvironment; + + /** + * The workflow state. Possible values include: 'NotSpecified', + * 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + */ + @JsonProperty(value = "properties.state") + private WorkflowState state; + + /** + * The sku. + */ + @JsonProperty(value = "sku") + private IntegrationAccountSku sku; + + /** + * Get the integration service environment. + * + * @return the integrationServiceEnvironment value + */ + public IntegrationServiceEnvironmentInner integrationServiceEnvironment() { + return this.integrationServiceEnvironment; + } + + /** + * Set the integration service environment. + * + * @param integrationServiceEnvironment the integrationServiceEnvironment value to set + * @return the IntegrationAccountInner object itself. + */ + public IntegrationAccountInner withIntegrationServiceEnvironment(IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + this.integrationServiceEnvironment = integrationServiceEnvironment; + return this; + } + + /** + * Get the workflow state. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + * + * @return the state value + */ + public WorkflowState state() { + return this.state; + } + + /** + * Set the workflow state. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + * + * @param state the state value to set + * @return the IntegrationAccountInner object itself. + */ + public IntegrationAccountInner withState(WorkflowState state) { + this.state = state; + return this; + } + + /** + * Get the sku. + * + * @return the sku value + */ + public IntegrationAccountSku sku() { + return this.sku; + } + + /** + * Set the sku. + * + * @param sku the sku value to set + * @return the IntegrationAccountInner object itself. + */ + public IntegrationAccountInner withSku(IntegrationAccountSku sku) { + this.sku = sku; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountMapImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountMapImpl.java new file mode 100644 index 000000000000..fa184b323fdf --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountMapImpl.java @@ -0,0 +1,191 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountMap; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import java.util.Map; +import com.microsoft.azure.management.logic.v2019_05_01.MapType; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountMapPropertiesParametersSchema; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.ContentLink; + +class IntegrationAccountMapImpl extends CreatableUpdatableImpl implements IntegrationAccountMap, IntegrationAccountMap.Definition, IntegrationAccountMap.Update { + private final LogicManager manager; + private String resourceGroupName; + private String integrationAccountName; + private String mapName; + + IntegrationAccountMapImpl(String name, LogicManager manager) { + super(name, new IntegrationAccountMapInner()); + this.manager = manager; + // Set resource name + this.mapName = name; + // + } + + IntegrationAccountMapImpl(IntegrationAccountMapInner inner, LogicManager manager) { + super(inner.name(), inner); + this.manager = manager; + // Set resource name + this.mapName = inner.name(); + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.integrationAccountName = IdParsingUtils.getValueFromIdByName(inner.id(), "integrationAccounts"); + this.mapName = IdParsingUtils.getValueFromIdByName(inner.id(), "maps"); + // + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public Observable createResourceAsync() { + IntegrationAccountMapsInner client = this.manager().inner().integrationAccountMaps(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.mapName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + public Observable updateResourceAsync() { + IntegrationAccountMapsInner client = this.manager().inner().integrationAccountMaps(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.mapName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + protected Observable getInnerAsync() { + IntegrationAccountMapsInner client = this.manager().inner().integrationAccountMaps(); + return client.getAsync(this.resourceGroupName, this.integrationAccountName, this.mapName); + } + + @Override + public boolean isInCreateMode() { + return this.inner().id() == null; + } + + + @Override + public DateTime changedTime() { + return this.inner().changedTime(); + } + + @Override + public String content() { + return this.inner().content(); + } + + @Override + public ContentLink contentLink() { + return this.inner().contentLink(); + } + + @Override + public String contentType() { + return this.inner().contentType(); + } + + @Override + public DateTime createdTime() { + return this.inner().createdTime(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public MapType mapType() { + return this.inner().mapType(); + } + + @Override + public Object metadata() { + return this.inner().metadata(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public IntegrationAccountMapPropertiesParametersSchema parametersSchema() { + return this.inner().parametersSchema(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public String type() { + return this.inner().type(); + } + + @Override + public IntegrationAccountMapImpl withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName) { + this.resourceGroupName = resourceGroupName; + this.integrationAccountName = integrationAccountName; + return this; + } + + @Override + public IntegrationAccountMapImpl withMapType(MapType mapType) { + this.inner().withMapType(mapType); + return this; + } + + @Override + public IntegrationAccountMapImpl withContent(String content) { + this.inner().withContent(content); + return this; + } + + @Override + public IntegrationAccountMapImpl withContentType(String contentType) { + this.inner().withContentType(contentType); + return this; + } + + @Override + public IntegrationAccountMapImpl withLocation(String location) { + this.inner().withLocation(location); + return this; + } + + @Override + public IntegrationAccountMapImpl withMetadata(Object metadata) { + this.inner().withMetadata(metadata); + return this; + } + + @Override + public IntegrationAccountMapImpl withParametersSchema(IntegrationAccountMapPropertiesParametersSchema parametersSchema) { + this.inner().withParametersSchema(parametersSchema); + return this; + } + + @Override + public IntegrationAccountMapImpl withTags(Map tags) { + this.inner().withTags(tags); + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountMapInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountMapInner.java new file mode 100644 index 000000000000..36b2d96f9059 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountMapInner.java @@ -0,0 +1,202 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.MapType; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountMapPropertiesParametersSchema; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.ContentLink; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The integration account map. + */ +@JsonFlatten +@SkipParentValidation +public class IntegrationAccountMapInner extends Resource { + /** + * The map type. Possible values include: 'NotSpecified', 'Xslt', 'Xslt20', + * 'Xslt30', 'Liquid'. + */ + @JsonProperty(value = "properties.mapType", required = true) + private MapType mapType; + + /** + * The parameters schema of integration account map. + */ + @JsonProperty(value = "properties.parametersSchema") + private IntegrationAccountMapPropertiesParametersSchema parametersSchema; + + /** + * The created time. + */ + @JsonProperty(value = "properties.createdTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime createdTime; + + /** + * The changed time. + */ + @JsonProperty(value = "properties.changedTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime changedTime; + + /** + * The content. + */ + @JsonProperty(value = "properties.content") + private String content; + + /** + * The content type. + */ + @JsonProperty(value = "properties.contentType") + private String contentType; + + /** + * The content link. + */ + @JsonProperty(value = "properties.contentLink", access = JsonProperty.Access.WRITE_ONLY) + private ContentLink contentLink; + + /** + * The metadata. + */ + @JsonProperty(value = "properties.metadata") + private Object metadata; + + /** + * Get the map type. Possible values include: 'NotSpecified', 'Xslt', 'Xslt20', 'Xslt30', 'Liquid'. + * + * @return the mapType value + */ + public MapType mapType() { + return this.mapType; + } + + /** + * Set the map type. Possible values include: 'NotSpecified', 'Xslt', 'Xslt20', 'Xslt30', 'Liquid'. + * + * @param mapType the mapType value to set + * @return the IntegrationAccountMapInner object itself. + */ + public IntegrationAccountMapInner withMapType(MapType mapType) { + this.mapType = mapType; + return this; + } + + /** + * Get the parameters schema of integration account map. + * + * @return the parametersSchema value + */ + public IntegrationAccountMapPropertiesParametersSchema parametersSchema() { + return this.parametersSchema; + } + + /** + * Set the parameters schema of integration account map. + * + * @param parametersSchema the parametersSchema value to set + * @return the IntegrationAccountMapInner object itself. + */ + public IntegrationAccountMapInner withParametersSchema(IntegrationAccountMapPropertiesParametersSchema parametersSchema) { + this.parametersSchema = parametersSchema; + return this; + } + + /** + * Get the created time. + * + * @return the createdTime value + */ + public DateTime createdTime() { + return this.createdTime; + } + + /** + * Get the changed time. + * + * @return the changedTime value + */ + public DateTime changedTime() { + return this.changedTime; + } + + /** + * Get the content. + * + * @return the content value + */ + public String content() { + return this.content; + } + + /** + * Set the content. + * + * @param content the content value to set + * @return the IntegrationAccountMapInner object itself. + */ + public IntegrationAccountMapInner withContent(String content) { + this.content = content; + return this; + } + + /** + * Get the content type. + * + * @return the contentType value + */ + public String contentType() { + return this.contentType; + } + + /** + * Set the content type. + * + * @param contentType the contentType value to set + * @return the IntegrationAccountMapInner object itself. + */ + public IntegrationAccountMapInner withContentType(String contentType) { + this.contentType = contentType; + return this; + } + + /** + * Get the content link. + * + * @return the contentLink value + */ + public ContentLink contentLink() { + return this.contentLink; + } + + /** + * Get the metadata. + * + * @return the metadata value + */ + public Object metadata() { + return this.metadata; + } + + /** + * Set the metadata. + * + * @param metadata the metadata value to set + * @return the IntegrationAccountMapInner object itself. + */ + public IntegrationAccountMapInner withMetadata(Object metadata) { + this.metadata = metadata; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountMapsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountMapsImpl.java new file mode 100644 index 000000000000..60795bb0a59e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountMapsImpl.java @@ -0,0 +1,99 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountMaps; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2019_05_01.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountMap; + +class IntegrationAccountMapsImpl extends WrapperImpl implements IntegrationAccountMaps { + private final LogicManager manager; + + IntegrationAccountMapsImpl(LogicManager manager) { + super(manager.inner().integrationAccountMaps()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + @Override + public IntegrationAccountMapImpl define(String name) { + return wrapModel(name); + } + + private IntegrationAccountMapImpl wrapModel(IntegrationAccountMapInner inner) { + return new IntegrationAccountMapImpl(inner, manager()); + } + + private IntegrationAccountMapImpl wrapModel(String name) { + return new IntegrationAccountMapImpl(name, this.manager()); + } + + @Override + public Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String mapName, GetCallbackUrlParameters listContentCallbackUrl) { + IntegrationAccountMapsInner client = this.inner(); + return client.listContentCallbackUrlAsync(resourceGroupName, integrationAccountName, mapName, listContentCallbackUrl) + .map(new Func1() { + @Override + public WorkflowTriggerCallbackUrl call(WorkflowTriggerCallbackUrlInner inner) { + return new WorkflowTriggerCallbackUrlImpl(inner, manager()); + } + }); + } + + @Override + public Observable listAsync(final String resourceGroupName, final String integrationAccountName) { + IntegrationAccountMapsInner client = this.inner(); + return client.listAsync(resourceGroupName, integrationAccountName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public IntegrationAccountMap call(IntegrationAccountMapInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String integrationAccountName, String mapName) { + IntegrationAccountMapsInner client = this.inner(); + return client.getAsync(resourceGroupName, integrationAccountName, mapName) + .flatMap(new Func1>() { + @Override + public Observable call(IntegrationAccountMapInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((IntegrationAccountMap)wrapModel(inner)); + } + } + }); + } + + @Override + public Completable deleteAsync(String resourceGroupName, String integrationAccountName, String mapName) { + IntegrationAccountMapsInner client = this.inner(); + return client.deleteAsync(resourceGroupName, integrationAccountName, mapName).toCompletable(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountMapsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountMapsInner.java new file mode 100644 index 000000000000..d9aa93429173 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountMapsInner.java @@ -0,0 +1,843 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.management.logic.v2019_05_01.GetCallbackUrlParameters; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import com.microsoft.rest.Validator; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.Body; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.HTTP; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.PUT; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationAccountMaps. + */ +public class IntegrationAccountMapsInner { + /** The Retrofit service to perform REST calls. */ + private IntegrationAccountMapsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationAccountMapsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationAccountMapsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationAccountMapsService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationAccountMaps to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationAccountMapsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountMaps list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/maps") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Query("$filter") String filter, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountMaps get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/maps/{mapName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("mapName") String mapName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountMaps createOrUpdate" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/maps/{mapName}") + Observable> createOrUpdate(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("mapName") String mapName, @Query("api-version") String apiVersion, @Body IntegrationAccountMapInner map, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountMaps delete" }) + @HTTP(path = "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/maps/{mapName}", method = "DELETE", hasBody = true) + Observable> delete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("mapName") String mapName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountMaps listContentCallbackUrl" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/maps/{mapName}/listContentCallbackUrl") + Observable> listContentCallbackUrl(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("mapName") String mapName, @Query("api-version") String apiVersion, @Body GetCallbackUrlParameters listContentCallbackUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountMaps listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of integration account maps. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountMapInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String integrationAccountName) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, integrationAccountName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account maps. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String integrationAccountName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, integrationAccountName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account maps. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountMapInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String integrationAccountName) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account maps. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountMapInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String integrationAccountName) { + return listSinglePageAsync(resourceGroupName, integrationAccountName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account maps. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountMapInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String integrationAccountName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + final String filter = null; + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of integration account maps. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: MapType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountMapInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account maps. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: MapType. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account maps. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: MapType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountMapInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName, top, filter) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account maps. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: MapType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountMapInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + return listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account maps. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param integrationAccountName The integration account name. + ServiceResponse> * @param top The number of items to be included in the result. + ServiceResponse> * @param filter The filter to apply on the operation. Options for filters include: MapType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountMapInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountMapInner object if successful. + */ + public IntegrationAccountMapInner get(String resourceGroupName, String integrationAccountName, String mapName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, mapName).toBlocking().single().body(); + } + + /** + * Gets an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String integrationAccountName, String mapName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, integrationAccountName, mapName), serviceCallback); + } + + /** + * Gets an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountMapInner object + */ + public Observable getAsync(String resourceGroupName, String integrationAccountName, String mapName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, mapName).map(new Func1, IntegrationAccountMapInner>() { + @Override + public IntegrationAccountMapInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountMapInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String mapName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (mapName == null) { + throw new IllegalArgumentException("Parameter mapName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, integrationAccountName, mapName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Creates or updates an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @param map The integration account map. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountMapInner object if successful. + */ + public IntegrationAccountMapInner createOrUpdate(String resourceGroupName, String integrationAccountName, String mapName, IntegrationAccountMapInner map) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, mapName, map).toBlocking().single().body(); + } + + /** + * Creates or updates an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @param map The integration account map. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String mapName, IntegrationAccountMapInner map, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, mapName, map), serviceCallback); + } + + /** + * Creates or updates an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @param map The integration account map. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountMapInner object + */ + public Observable createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String mapName, IntegrationAccountMapInner map) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, mapName, map).map(new Func1, IntegrationAccountMapInner>() { + @Override + public IntegrationAccountMapInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Creates or updates an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @param map The integration account map. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountMapInner object + */ + public Observable> createOrUpdateWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String mapName, IntegrationAccountMapInner map) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (mapName == null) { + throw new IllegalArgumentException("Parameter mapName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (map == null) { + throw new IllegalArgumentException("Parameter map is required and cannot be null."); + } + Validator.validate(map); + return service.createOrUpdate(this.client.subscriptionId(), resourceGroupName, integrationAccountName, mapName, this.client.apiVersion(), map, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = createOrUpdateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse createOrUpdateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Deletes an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void delete(String resourceGroupName, String integrationAccountName, String mapName) { + deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, mapName).toBlocking().single().body(); + } + + /** + * Deletes an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture deleteAsync(String resourceGroupName, String integrationAccountName, String mapName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, mapName), serviceCallback); + } + + /** + * Deletes an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable deleteAsync(String resourceGroupName, String integrationAccountName, String mapName) { + return deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, mapName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Deletes an integration account map. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> deleteWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String mapName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (mapName == null) { + throw new IllegalArgumentException("Parameter mapName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.delete(this.client.subscriptionId(), resourceGroupName, integrationAccountName, mapName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = deleteDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse deleteDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowTriggerCallbackUrlInner object if successful. + */ + public WorkflowTriggerCallbackUrlInner listContentCallbackUrl(String resourceGroupName, String integrationAccountName, String mapName, GetCallbackUrlParameters listContentCallbackUrl) { + return listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, mapName, listContentCallbackUrl).toBlocking().single().body(); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String mapName, GetCallbackUrlParameters listContentCallbackUrl, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, mapName, listContentCallbackUrl), serviceCallback); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String mapName, GetCallbackUrlParameters listContentCallbackUrl) { + return listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, mapName, listContentCallbackUrl).map(new Func1, WorkflowTriggerCallbackUrlInner>() { + @Override + public WorkflowTriggerCallbackUrlInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param mapName The integration account map name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable> listContentCallbackUrlWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String mapName, GetCallbackUrlParameters listContentCallbackUrl) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (mapName == null) { + throw new IllegalArgumentException("Parameter mapName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (listContentCallbackUrl == null) { + throw new IllegalArgumentException("Parameter listContentCallbackUrl is required and cannot be null."); + } + Validator.validate(listContentCallbackUrl); + return service.listContentCallbackUrl(this.client.subscriptionId(), resourceGroupName, integrationAccountName, mapName, this.client.apiVersion(), listContentCallbackUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = listContentCallbackUrlDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse listContentCallbackUrlDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of integration account maps. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountMapInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account maps. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account maps. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountMapInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account maps. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountMapInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account maps. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountMapInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountPartnerImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountPartnerImpl.java new file mode 100644 index 000000000000..81765d63cfa8 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountPartnerImpl.java @@ -0,0 +1,163 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountPartner; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import java.util.Map; +import com.microsoft.azure.management.logic.v2019_05_01.PartnerType; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.PartnerContent; + +class IntegrationAccountPartnerImpl extends CreatableUpdatableImpl implements IntegrationAccountPartner, IntegrationAccountPartner.Definition, IntegrationAccountPartner.Update { + private final LogicManager manager; + private String resourceGroupName; + private String integrationAccountName; + private String partnerName; + + IntegrationAccountPartnerImpl(String name, LogicManager manager) { + super(name, new IntegrationAccountPartnerInner()); + this.manager = manager; + // Set resource name + this.partnerName = name; + // + } + + IntegrationAccountPartnerImpl(IntegrationAccountPartnerInner inner, LogicManager manager) { + super(inner.name(), inner); + this.manager = manager; + // Set resource name + this.partnerName = inner.name(); + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.integrationAccountName = IdParsingUtils.getValueFromIdByName(inner.id(), "integrationAccounts"); + this.partnerName = IdParsingUtils.getValueFromIdByName(inner.id(), "partners"); + // + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public Observable createResourceAsync() { + IntegrationAccountPartnersInner client = this.manager().inner().integrationAccountPartners(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.partnerName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + public Observable updateResourceAsync() { + IntegrationAccountPartnersInner client = this.manager().inner().integrationAccountPartners(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.partnerName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + protected Observable getInnerAsync() { + IntegrationAccountPartnersInner client = this.manager().inner().integrationAccountPartners(); + return client.getAsync(this.resourceGroupName, this.integrationAccountName, this.partnerName); + } + + @Override + public boolean isInCreateMode() { + return this.inner().id() == null; + } + + + @Override + public DateTime changedTime() { + return this.inner().changedTime(); + } + + @Override + public PartnerContent content() { + return this.inner().content(); + } + + @Override + public DateTime createdTime() { + return this.inner().createdTime(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public Object metadata() { + return this.inner().metadata(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public PartnerType partnerType() { + return this.inner().partnerType(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public String type() { + return this.inner().type(); + } + + @Override + public IntegrationAccountPartnerImpl withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName) { + this.resourceGroupName = resourceGroupName; + this.integrationAccountName = integrationAccountName; + return this; + } + + @Override + public IntegrationAccountPartnerImpl withContent(PartnerContent content) { + this.inner().withContent(content); + return this; + } + + @Override + public IntegrationAccountPartnerImpl withPartnerType(PartnerType partnerType) { + this.inner().withPartnerType(partnerType); + return this; + } + + @Override + public IntegrationAccountPartnerImpl withLocation(String location) { + this.inner().withLocation(location); + return this; + } + + @Override + public IntegrationAccountPartnerImpl withMetadata(Object metadata) { + this.inner().withMetadata(metadata); + return this; + } + + @Override + public IntegrationAccountPartnerImpl withTags(Map tags) { + this.inner().withTags(tags); + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountPartnerInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountPartnerInner.java new file mode 100644 index 000000000000..879978abd2bc --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountPartnerInner.java @@ -0,0 +1,133 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.PartnerType; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.PartnerContent; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The integration account partner. + */ +@JsonFlatten +@SkipParentValidation +public class IntegrationAccountPartnerInner extends Resource { + /** + * The partner type. Possible values include: 'NotSpecified', 'B2B'. + */ + @JsonProperty(value = "properties.partnerType", required = true) + private PartnerType partnerType; + + /** + * The created time. + */ + @JsonProperty(value = "properties.createdTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime createdTime; + + /** + * The changed time. + */ + @JsonProperty(value = "properties.changedTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime changedTime; + + /** + * The metadata. + */ + @JsonProperty(value = "properties.metadata") + private Object metadata; + + /** + * The partner content. + */ + @JsonProperty(value = "properties.content", required = true) + private PartnerContent content; + + /** + * Get the partner type. Possible values include: 'NotSpecified', 'B2B'. + * + * @return the partnerType value + */ + public PartnerType partnerType() { + return this.partnerType; + } + + /** + * Set the partner type. Possible values include: 'NotSpecified', 'B2B'. + * + * @param partnerType the partnerType value to set + * @return the IntegrationAccountPartnerInner object itself. + */ + public IntegrationAccountPartnerInner withPartnerType(PartnerType partnerType) { + this.partnerType = partnerType; + return this; + } + + /** + * Get the created time. + * + * @return the createdTime value + */ + public DateTime createdTime() { + return this.createdTime; + } + + /** + * Get the changed time. + * + * @return the changedTime value + */ + public DateTime changedTime() { + return this.changedTime; + } + + /** + * Get the metadata. + * + * @return the metadata value + */ + public Object metadata() { + return this.metadata; + } + + /** + * Set the metadata. + * + * @param metadata the metadata value to set + * @return the IntegrationAccountPartnerInner object itself. + */ + public IntegrationAccountPartnerInner withMetadata(Object metadata) { + this.metadata = metadata; + return this; + } + + /** + * Get the partner content. + * + * @return the content value + */ + public PartnerContent content() { + return this.content; + } + + /** + * Set the partner content. + * + * @param content the content value to set + * @return the IntegrationAccountPartnerInner object itself. + */ + public IntegrationAccountPartnerInner withContent(PartnerContent content) { + this.content = content; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountPartnersImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountPartnersImpl.java new file mode 100644 index 000000000000..0015cb9bd6f8 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountPartnersImpl.java @@ -0,0 +1,99 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountPartners; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2019_05_01.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountPartner; + +class IntegrationAccountPartnersImpl extends WrapperImpl implements IntegrationAccountPartners { + private final LogicManager manager; + + IntegrationAccountPartnersImpl(LogicManager manager) { + super(manager.inner().integrationAccountPartners()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + @Override + public IntegrationAccountPartnerImpl define(String name) { + return wrapModel(name); + } + + private IntegrationAccountPartnerImpl wrapModel(IntegrationAccountPartnerInner inner) { + return new IntegrationAccountPartnerImpl(inner, manager()); + } + + private IntegrationAccountPartnerImpl wrapModel(String name) { + return new IntegrationAccountPartnerImpl(name, this.manager()); + } + + @Override + public Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String partnerName, GetCallbackUrlParameters listContentCallbackUrl) { + IntegrationAccountPartnersInner client = this.inner(); + return client.listContentCallbackUrlAsync(resourceGroupName, integrationAccountName, partnerName, listContentCallbackUrl) + .map(new Func1() { + @Override + public WorkflowTriggerCallbackUrl call(WorkflowTriggerCallbackUrlInner inner) { + return new WorkflowTriggerCallbackUrlImpl(inner, manager()); + } + }); + } + + @Override + public Observable listAsync(final String resourceGroupName, final String integrationAccountName) { + IntegrationAccountPartnersInner client = this.inner(); + return client.listAsync(resourceGroupName, integrationAccountName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public IntegrationAccountPartner call(IntegrationAccountPartnerInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String integrationAccountName, String partnerName) { + IntegrationAccountPartnersInner client = this.inner(); + return client.getAsync(resourceGroupName, integrationAccountName, partnerName) + .flatMap(new Func1>() { + @Override + public Observable call(IntegrationAccountPartnerInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((IntegrationAccountPartner)wrapModel(inner)); + } + } + }); + } + + @Override + public Completable deleteAsync(String resourceGroupName, String integrationAccountName, String partnerName) { + IntegrationAccountPartnersInner client = this.inner(); + return client.deleteAsync(resourceGroupName, integrationAccountName, partnerName).toCompletable(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountPartnersInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountPartnersInner.java new file mode 100644 index 000000000000..81699e822dd3 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountPartnersInner.java @@ -0,0 +1,843 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.management.logic.v2019_05_01.GetCallbackUrlParameters; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import com.microsoft.rest.Validator; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.Body; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.HTTP; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.PUT; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationAccountPartners. + */ +public class IntegrationAccountPartnersInner { + /** The Retrofit service to perform REST calls. */ + private IntegrationAccountPartnersService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationAccountPartnersInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationAccountPartnersInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationAccountPartnersService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationAccountPartners to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationAccountPartnersService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountPartners list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/partners") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Query("$filter") String filter, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountPartners get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/partners/{partnerName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("partnerName") String partnerName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountPartners createOrUpdate" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/partners/{partnerName}") + Observable> createOrUpdate(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("partnerName") String partnerName, @Query("api-version") String apiVersion, @Body IntegrationAccountPartnerInner partner, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountPartners delete" }) + @HTTP(path = "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/partners/{partnerName}", method = "DELETE", hasBody = true) + Observable> delete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("partnerName") String partnerName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountPartners listContentCallbackUrl" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/partners/{partnerName}/listContentCallbackUrl") + Observable> listContentCallbackUrl(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("partnerName") String partnerName, @Query("api-version") String apiVersion, @Body GetCallbackUrlParameters listContentCallbackUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountPartners listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of integration account partners. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountPartnerInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String integrationAccountName) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, integrationAccountName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account partners. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String integrationAccountName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, integrationAccountName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account partners. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountPartnerInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String integrationAccountName) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account partners. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountPartnerInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String integrationAccountName) { + return listSinglePageAsync(resourceGroupName, integrationAccountName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account partners. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountPartnerInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String integrationAccountName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + final String filter = null; + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of integration account partners. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: PartnerType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountPartnerInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account partners. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: PartnerType. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account partners. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: PartnerType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountPartnerInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName, top, filter) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account partners. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: PartnerType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountPartnerInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + return listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account partners. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param integrationAccountName The integration account name. + ServiceResponse> * @param top The number of items to be included in the result. + ServiceResponse> * @param filter The filter to apply on the operation. Options for filters include: PartnerType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountPartnerInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountPartnerInner object if successful. + */ + public IntegrationAccountPartnerInner get(String resourceGroupName, String integrationAccountName, String partnerName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, partnerName).toBlocking().single().body(); + } + + /** + * Gets an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String integrationAccountName, String partnerName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, integrationAccountName, partnerName), serviceCallback); + } + + /** + * Gets an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountPartnerInner object + */ + public Observable getAsync(String resourceGroupName, String integrationAccountName, String partnerName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, partnerName).map(new Func1, IntegrationAccountPartnerInner>() { + @Override + public IntegrationAccountPartnerInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountPartnerInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String partnerName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (partnerName == null) { + throw new IllegalArgumentException("Parameter partnerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, integrationAccountName, partnerName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Creates or updates an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @param partner The integration account partner. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountPartnerInner object if successful. + */ + public IntegrationAccountPartnerInner createOrUpdate(String resourceGroupName, String integrationAccountName, String partnerName, IntegrationAccountPartnerInner partner) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, partnerName, partner).toBlocking().single().body(); + } + + /** + * Creates or updates an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @param partner The integration account partner. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String partnerName, IntegrationAccountPartnerInner partner, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, partnerName, partner), serviceCallback); + } + + /** + * Creates or updates an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @param partner The integration account partner. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountPartnerInner object + */ + public Observable createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String partnerName, IntegrationAccountPartnerInner partner) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, partnerName, partner).map(new Func1, IntegrationAccountPartnerInner>() { + @Override + public IntegrationAccountPartnerInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Creates or updates an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @param partner The integration account partner. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountPartnerInner object + */ + public Observable> createOrUpdateWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String partnerName, IntegrationAccountPartnerInner partner) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (partnerName == null) { + throw new IllegalArgumentException("Parameter partnerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (partner == null) { + throw new IllegalArgumentException("Parameter partner is required and cannot be null."); + } + Validator.validate(partner); + return service.createOrUpdate(this.client.subscriptionId(), resourceGroupName, integrationAccountName, partnerName, this.client.apiVersion(), partner, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = createOrUpdateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse createOrUpdateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Deletes an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void delete(String resourceGroupName, String integrationAccountName, String partnerName) { + deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, partnerName).toBlocking().single().body(); + } + + /** + * Deletes an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture deleteAsync(String resourceGroupName, String integrationAccountName, String partnerName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, partnerName), serviceCallback); + } + + /** + * Deletes an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable deleteAsync(String resourceGroupName, String integrationAccountName, String partnerName) { + return deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, partnerName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Deletes an integration account partner. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> deleteWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String partnerName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (partnerName == null) { + throw new IllegalArgumentException("Parameter partnerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.delete(this.client.subscriptionId(), resourceGroupName, integrationAccountName, partnerName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = deleteDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse deleteDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowTriggerCallbackUrlInner object if successful. + */ + public WorkflowTriggerCallbackUrlInner listContentCallbackUrl(String resourceGroupName, String integrationAccountName, String partnerName, GetCallbackUrlParameters listContentCallbackUrl) { + return listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, partnerName, listContentCallbackUrl).toBlocking().single().body(); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String partnerName, GetCallbackUrlParameters listContentCallbackUrl, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, partnerName, listContentCallbackUrl), serviceCallback); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String partnerName, GetCallbackUrlParameters listContentCallbackUrl) { + return listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, partnerName, listContentCallbackUrl).map(new Func1, WorkflowTriggerCallbackUrlInner>() { + @Override + public WorkflowTriggerCallbackUrlInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param partnerName The integration account partner name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable> listContentCallbackUrlWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String partnerName, GetCallbackUrlParameters listContentCallbackUrl) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (partnerName == null) { + throw new IllegalArgumentException("Parameter partnerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (listContentCallbackUrl == null) { + throw new IllegalArgumentException("Parameter listContentCallbackUrl is required and cannot be null."); + } + Validator.validate(listContentCallbackUrl); + return service.listContentCallbackUrl(this.client.subscriptionId(), resourceGroupName, integrationAccountName, partnerName, this.client.apiVersion(), listContentCallbackUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = listContentCallbackUrlDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse listContentCallbackUrlDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of integration account partners. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountPartnerInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account partners. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account partners. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountPartnerInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account partners. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountPartnerInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account partners. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountPartnerInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSchemaImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSchemaImpl.java new file mode 100644 index 000000000000..bb2ceb762af0 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSchemaImpl.java @@ -0,0 +1,212 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSchema; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import java.util.Map; +import com.microsoft.azure.management.logic.v2019_05_01.SchemaType; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.ContentLink; + +class IntegrationAccountSchemaImpl extends CreatableUpdatableImpl implements IntegrationAccountSchema, IntegrationAccountSchema.Definition, IntegrationAccountSchema.Update { + private final LogicManager manager; + private String resourceGroupName; + private String integrationAccountName; + private String schemaName; + + IntegrationAccountSchemaImpl(String name, LogicManager manager) { + super(name, new IntegrationAccountSchemaInner()); + this.manager = manager; + // Set resource name + this.schemaName = name; + // + } + + IntegrationAccountSchemaImpl(IntegrationAccountSchemaInner inner, LogicManager manager) { + super(inner.name(), inner); + this.manager = manager; + // Set resource name + this.schemaName = inner.name(); + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.integrationAccountName = IdParsingUtils.getValueFromIdByName(inner.id(), "integrationAccounts"); + this.schemaName = IdParsingUtils.getValueFromIdByName(inner.id(), "schemas"); + // + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public Observable createResourceAsync() { + IntegrationAccountSchemasInner client = this.manager().inner().integrationAccountSchemas(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.schemaName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + public Observable updateResourceAsync() { + IntegrationAccountSchemasInner client = this.manager().inner().integrationAccountSchemas(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.schemaName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + protected Observable getInnerAsync() { + IntegrationAccountSchemasInner client = this.manager().inner().integrationAccountSchemas(); + return client.getAsync(this.resourceGroupName, this.integrationAccountName, this.schemaName); + } + + @Override + public boolean isInCreateMode() { + return this.inner().id() == null; + } + + + @Override + public DateTime changedTime() { + return this.inner().changedTime(); + } + + @Override + public String content() { + return this.inner().content(); + } + + @Override + public ContentLink contentLink() { + return this.inner().contentLink(); + } + + @Override + public String contentType() { + return this.inner().contentType(); + } + + @Override + public DateTime createdTime() { + return this.inner().createdTime(); + } + + @Override + public String documentName() { + return this.inner().documentName(); + } + + @Override + public String fileName() { + return this.inner().fileName(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public Object metadata() { + return this.inner().metadata(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public SchemaType schemaType() { + return this.inner().schemaType(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public String targetNamespace() { + return this.inner().targetNamespace(); + } + + @Override + public String type() { + return this.inner().type(); + } + + @Override + public IntegrationAccountSchemaImpl withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName) { + this.resourceGroupName = resourceGroupName; + this.integrationAccountName = integrationAccountName; + return this; + } + + @Override + public IntegrationAccountSchemaImpl withSchemaType(SchemaType schemaType) { + this.inner().withSchemaType(schemaType); + return this; + } + + @Override + public IntegrationAccountSchemaImpl withContent(String content) { + this.inner().withContent(content); + return this; + } + + @Override + public IntegrationAccountSchemaImpl withContentType(String contentType) { + this.inner().withContentType(contentType); + return this; + } + + @Override + public IntegrationAccountSchemaImpl withDocumentName(String documentName) { + this.inner().withDocumentName(documentName); + return this; + } + + @Override + public IntegrationAccountSchemaImpl withFileName(String fileName) { + this.inner().withFileName(fileName); + return this; + } + + @Override + public IntegrationAccountSchemaImpl withLocation(String location) { + this.inner().withLocation(location); + return this; + } + + @Override + public IntegrationAccountSchemaImpl withMetadata(Object metadata) { + this.inner().withMetadata(metadata); + return this; + } + + @Override + public IntegrationAccountSchemaImpl withTags(Map tags) { + this.inner().withTags(tags); + return this; + } + + @Override + public IntegrationAccountSchemaImpl withTargetNamespace(String targetNamespace) { + this.inner().withTargetNamespace(targetNamespace); + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSchemaInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSchemaInner.java new file mode 100644 index 000000000000..e77fddffc5fb --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSchemaInner.java @@ -0,0 +1,252 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.SchemaType; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.ContentLink; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The integration account schema. + */ +@JsonFlatten +@SkipParentValidation +public class IntegrationAccountSchemaInner extends Resource { + /** + * The schema type. Possible values include: 'NotSpecified', 'Xml'. + */ + @JsonProperty(value = "properties.schemaType", required = true) + private SchemaType schemaType; + + /** + * The target namespace of the schema. + */ + @JsonProperty(value = "properties.targetNamespace") + private String targetNamespace; + + /** + * The document name. + */ + @JsonProperty(value = "properties.documentName") + private String documentName; + + /** + * The file name. + */ + @JsonProperty(value = "properties.fileName") + private String fileName; + + /** + * The created time. + */ + @JsonProperty(value = "properties.createdTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime createdTime; + + /** + * The changed time. + */ + @JsonProperty(value = "properties.changedTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime changedTime; + + /** + * The metadata. + */ + @JsonProperty(value = "properties.metadata") + private Object metadata; + + /** + * The content. + */ + @JsonProperty(value = "properties.content") + private String content; + + /** + * The content type. + */ + @JsonProperty(value = "properties.contentType") + private String contentType; + + /** + * The content link. + */ + @JsonProperty(value = "properties.contentLink", access = JsonProperty.Access.WRITE_ONLY) + private ContentLink contentLink; + + /** + * Get the schema type. Possible values include: 'NotSpecified', 'Xml'. + * + * @return the schemaType value + */ + public SchemaType schemaType() { + return this.schemaType; + } + + /** + * Set the schema type. Possible values include: 'NotSpecified', 'Xml'. + * + * @param schemaType the schemaType value to set + * @return the IntegrationAccountSchemaInner object itself. + */ + public IntegrationAccountSchemaInner withSchemaType(SchemaType schemaType) { + this.schemaType = schemaType; + return this; + } + + /** + * Get the target namespace of the schema. + * + * @return the targetNamespace value + */ + public String targetNamespace() { + return this.targetNamespace; + } + + /** + * Set the target namespace of the schema. + * + * @param targetNamespace the targetNamespace value to set + * @return the IntegrationAccountSchemaInner object itself. + */ + public IntegrationAccountSchemaInner withTargetNamespace(String targetNamespace) { + this.targetNamespace = targetNamespace; + return this; + } + + /** + * Get the document name. + * + * @return the documentName value + */ + public String documentName() { + return this.documentName; + } + + /** + * Set the document name. + * + * @param documentName the documentName value to set + * @return the IntegrationAccountSchemaInner object itself. + */ + public IntegrationAccountSchemaInner withDocumentName(String documentName) { + this.documentName = documentName; + return this; + } + + /** + * Get the file name. + * + * @return the fileName value + */ + public String fileName() { + return this.fileName; + } + + /** + * Set the file name. + * + * @param fileName the fileName value to set + * @return the IntegrationAccountSchemaInner object itself. + */ + public IntegrationAccountSchemaInner withFileName(String fileName) { + this.fileName = fileName; + return this; + } + + /** + * Get the created time. + * + * @return the createdTime value + */ + public DateTime createdTime() { + return this.createdTime; + } + + /** + * Get the changed time. + * + * @return the changedTime value + */ + public DateTime changedTime() { + return this.changedTime; + } + + /** + * Get the metadata. + * + * @return the metadata value + */ + public Object metadata() { + return this.metadata; + } + + /** + * Set the metadata. + * + * @param metadata the metadata value to set + * @return the IntegrationAccountSchemaInner object itself. + */ + public IntegrationAccountSchemaInner withMetadata(Object metadata) { + this.metadata = metadata; + return this; + } + + /** + * Get the content. + * + * @return the content value + */ + public String content() { + return this.content; + } + + /** + * Set the content. + * + * @param content the content value to set + * @return the IntegrationAccountSchemaInner object itself. + */ + public IntegrationAccountSchemaInner withContent(String content) { + this.content = content; + return this; + } + + /** + * Get the content type. + * + * @return the contentType value + */ + public String contentType() { + return this.contentType; + } + + /** + * Set the content type. + * + * @param contentType the contentType value to set + * @return the IntegrationAccountSchemaInner object itself. + */ + public IntegrationAccountSchemaInner withContentType(String contentType) { + this.contentType = contentType; + return this; + } + + /** + * Get the content link. + * + * @return the contentLink value + */ + public ContentLink contentLink() { + return this.contentLink; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSchemasImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSchemasImpl.java new file mode 100644 index 000000000000..5497ccae6f70 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSchemasImpl.java @@ -0,0 +1,99 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSchemas; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2019_05_01.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSchema; + +class IntegrationAccountSchemasImpl extends WrapperImpl implements IntegrationAccountSchemas { + private final LogicManager manager; + + IntegrationAccountSchemasImpl(LogicManager manager) { + super(manager.inner().integrationAccountSchemas()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + @Override + public IntegrationAccountSchemaImpl define(String name) { + return wrapModel(name); + } + + private IntegrationAccountSchemaImpl wrapModel(IntegrationAccountSchemaInner inner) { + return new IntegrationAccountSchemaImpl(inner, manager()); + } + + private IntegrationAccountSchemaImpl wrapModel(String name) { + return new IntegrationAccountSchemaImpl(name, this.manager()); + } + + @Override + public Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String schemaName, GetCallbackUrlParameters listContentCallbackUrl) { + IntegrationAccountSchemasInner client = this.inner(); + return client.listContentCallbackUrlAsync(resourceGroupName, integrationAccountName, schemaName, listContentCallbackUrl) + .map(new Func1() { + @Override + public WorkflowTriggerCallbackUrl call(WorkflowTriggerCallbackUrlInner inner) { + return new WorkflowTriggerCallbackUrlImpl(inner, manager()); + } + }); + } + + @Override + public Observable listAsync(final String resourceGroupName, final String integrationAccountName) { + IntegrationAccountSchemasInner client = this.inner(); + return client.listAsync(resourceGroupName, integrationAccountName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public IntegrationAccountSchema call(IntegrationAccountSchemaInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String integrationAccountName, String schemaName) { + IntegrationAccountSchemasInner client = this.inner(); + return client.getAsync(resourceGroupName, integrationAccountName, schemaName) + .flatMap(new Func1>() { + @Override + public Observable call(IntegrationAccountSchemaInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((IntegrationAccountSchema)wrapModel(inner)); + } + } + }); + } + + @Override + public Completable deleteAsync(String resourceGroupName, String integrationAccountName, String schemaName) { + IntegrationAccountSchemasInner client = this.inner(); + return client.deleteAsync(resourceGroupName, integrationAccountName, schemaName).toCompletable(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSchemasInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSchemasInner.java new file mode 100644 index 000000000000..db7d5dce09b8 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSchemasInner.java @@ -0,0 +1,843 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.management.logic.v2019_05_01.GetCallbackUrlParameters; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import com.microsoft.rest.Validator; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.Body; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.HTTP; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.PUT; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationAccountSchemas. + */ +public class IntegrationAccountSchemasInner { + /** The Retrofit service to perform REST calls. */ + private IntegrationAccountSchemasService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationAccountSchemasInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationAccountSchemasInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationAccountSchemasService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationAccountSchemas to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationAccountSchemasService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSchemas list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/schemas") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Query("$filter") String filter, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSchemas get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/schemas/{schemaName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("schemaName") String schemaName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSchemas createOrUpdate" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/schemas/{schemaName}") + Observable> createOrUpdate(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("schemaName") String schemaName, @Query("api-version") String apiVersion, @Body IntegrationAccountSchemaInner schema, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSchemas delete" }) + @HTTP(path = "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/schemas/{schemaName}", method = "DELETE", hasBody = true) + Observable> delete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("schemaName") String schemaName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSchemas listContentCallbackUrl" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/schemas/{schemaName}/listContentCallbackUrl") + Observable> listContentCallbackUrl(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("schemaName") String schemaName, @Query("api-version") String apiVersion, @Body GetCallbackUrlParameters listContentCallbackUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSchemas listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of integration account schemas. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountSchemaInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String integrationAccountName) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, integrationAccountName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account schemas. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String integrationAccountName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, integrationAccountName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account schemas. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountSchemaInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String integrationAccountName) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account schemas. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountSchemaInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String integrationAccountName) { + return listSinglePageAsync(resourceGroupName, integrationAccountName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account schemas. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountSchemaInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String integrationAccountName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + final String filter = null; + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of integration account schemas. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: SchemaType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountSchemaInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account schemas. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: SchemaType. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account schemas. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: SchemaType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountSchemaInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName, top, filter) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account schemas. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: SchemaType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountSchemaInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + return listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account schemas. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param integrationAccountName The integration account name. + ServiceResponse> * @param top The number of items to be included in the result. + ServiceResponse> * @param filter The filter to apply on the operation. Options for filters include: SchemaType. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountSchemaInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountSchemaInner object if successful. + */ + public IntegrationAccountSchemaInner get(String resourceGroupName, String integrationAccountName, String schemaName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, schemaName).toBlocking().single().body(); + } + + /** + * Gets an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String integrationAccountName, String schemaName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, integrationAccountName, schemaName), serviceCallback); + } + + /** + * Gets an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountSchemaInner object + */ + public Observable getAsync(String resourceGroupName, String integrationAccountName, String schemaName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, schemaName).map(new Func1, IntegrationAccountSchemaInner>() { + @Override + public IntegrationAccountSchemaInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountSchemaInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String schemaName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (schemaName == null) { + throw new IllegalArgumentException("Parameter schemaName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, integrationAccountName, schemaName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Creates or updates an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @param schema The integration account schema. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountSchemaInner object if successful. + */ + public IntegrationAccountSchemaInner createOrUpdate(String resourceGroupName, String integrationAccountName, String schemaName, IntegrationAccountSchemaInner schema) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, schemaName, schema).toBlocking().single().body(); + } + + /** + * Creates or updates an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @param schema The integration account schema. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String schemaName, IntegrationAccountSchemaInner schema, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, schemaName, schema), serviceCallback); + } + + /** + * Creates or updates an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @param schema The integration account schema. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountSchemaInner object + */ + public Observable createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String schemaName, IntegrationAccountSchemaInner schema) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, schemaName, schema).map(new Func1, IntegrationAccountSchemaInner>() { + @Override + public IntegrationAccountSchemaInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Creates or updates an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @param schema The integration account schema. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountSchemaInner object + */ + public Observable> createOrUpdateWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String schemaName, IntegrationAccountSchemaInner schema) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (schemaName == null) { + throw new IllegalArgumentException("Parameter schemaName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (schema == null) { + throw new IllegalArgumentException("Parameter schema is required and cannot be null."); + } + Validator.validate(schema); + return service.createOrUpdate(this.client.subscriptionId(), resourceGroupName, integrationAccountName, schemaName, this.client.apiVersion(), schema, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = createOrUpdateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse createOrUpdateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Deletes an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void delete(String resourceGroupName, String integrationAccountName, String schemaName) { + deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, schemaName).toBlocking().single().body(); + } + + /** + * Deletes an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture deleteAsync(String resourceGroupName, String integrationAccountName, String schemaName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, schemaName), serviceCallback); + } + + /** + * Deletes an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable deleteAsync(String resourceGroupName, String integrationAccountName, String schemaName) { + return deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, schemaName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Deletes an integration account schema. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> deleteWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String schemaName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (schemaName == null) { + throw new IllegalArgumentException("Parameter schemaName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.delete(this.client.subscriptionId(), resourceGroupName, integrationAccountName, schemaName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = deleteDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse deleteDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowTriggerCallbackUrlInner object if successful. + */ + public WorkflowTriggerCallbackUrlInner listContentCallbackUrl(String resourceGroupName, String integrationAccountName, String schemaName, GetCallbackUrlParameters listContentCallbackUrl) { + return listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, schemaName, listContentCallbackUrl).toBlocking().single().body(); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String schemaName, GetCallbackUrlParameters listContentCallbackUrl, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, schemaName, listContentCallbackUrl), serviceCallback); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable listContentCallbackUrlAsync(String resourceGroupName, String integrationAccountName, String schemaName, GetCallbackUrlParameters listContentCallbackUrl) { + return listContentCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, schemaName, listContentCallbackUrl).map(new Func1, WorkflowTriggerCallbackUrlInner>() { + @Override + public WorkflowTriggerCallbackUrlInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get the content callback url. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param schemaName The integration account schema name. + * @param listContentCallbackUrl the GetCallbackUrlParameters value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable> listContentCallbackUrlWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String schemaName, GetCallbackUrlParameters listContentCallbackUrl) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (schemaName == null) { + throw new IllegalArgumentException("Parameter schemaName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (listContentCallbackUrl == null) { + throw new IllegalArgumentException("Parameter listContentCallbackUrl is required and cannot be null."); + } + Validator.validate(listContentCallbackUrl); + return service.listContentCallbackUrl(this.client.subscriptionId(), resourceGroupName, integrationAccountName, schemaName, this.client.apiVersion(), listContentCallbackUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = listContentCallbackUrlDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse listContentCallbackUrlDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of integration account schemas. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountSchemaInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account schemas. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account schemas. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountSchemaInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account schemas. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountSchemaInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account schemas. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountSchemaInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSessionImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSessionImpl.java new file mode 100644 index 000000000000..0737f89e4cd7 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSessionImpl.java @@ -0,0 +1,139 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSession; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import java.util.Map; +import org.joda.time.DateTime; + +class IntegrationAccountSessionImpl extends CreatableUpdatableImpl implements IntegrationAccountSession, IntegrationAccountSession.Definition, IntegrationAccountSession.Update { + private final LogicManager manager; + private String resourceGroupName; + private String integrationAccountName; + private String sessionName; + + IntegrationAccountSessionImpl(String name, LogicManager manager) { + super(name, new IntegrationAccountSessionInner()); + this.manager = manager; + // Set resource name + this.sessionName = name; + // + } + + IntegrationAccountSessionImpl(IntegrationAccountSessionInner inner, LogicManager manager) { + super(inner.name(), inner); + this.manager = manager; + // Set resource name + this.sessionName = inner.name(); + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.integrationAccountName = IdParsingUtils.getValueFromIdByName(inner.id(), "integrationAccounts"); + this.sessionName = IdParsingUtils.getValueFromIdByName(inner.id(), "sessions"); + // + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public Observable createResourceAsync() { + IntegrationAccountSessionsInner client = this.manager().inner().integrationAccountSessions(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.sessionName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + public Observable updateResourceAsync() { + IntegrationAccountSessionsInner client = this.manager().inner().integrationAccountSessions(); + return client.createOrUpdateAsync(this.resourceGroupName, this.integrationAccountName, this.sessionName, this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + protected Observable getInnerAsync() { + IntegrationAccountSessionsInner client = this.manager().inner().integrationAccountSessions(); + return client.getAsync(this.resourceGroupName, this.integrationAccountName, this.sessionName); + } + + @Override + public boolean isInCreateMode() { + return this.inner().id() == null; + } + + + @Override + public DateTime changedTime() { + return this.inner().changedTime(); + } + + @Override + public Object content() { + return this.inner().content(); + } + + @Override + public DateTime createdTime() { + return this.inner().createdTime(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public String type() { + return this.inner().type(); + } + + @Override + public IntegrationAccountSessionImpl withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName) { + this.resourceGroupName = resourceGroupName; + this.integrationAccountName = integrationAccountName; + return this; + } + + @Override + public IntegrationAccountSessionImpl withContent(Object content) { + this.inner().withContent(content); + return this; + } + + @Override + public IntegrationAccountSessionImpl withLocation(String location) { + this.inner().withLocation(location); + return this; + } + + @Override + public IntegrationAccountSessionImpl withTags(Map tags) { + this.inner().withTags(tags); + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSessionInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSessionInner.java new file mode 100644 index 000000000000..a3b3ba443041 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSessionInner.java @@ -0,0 +1,79 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import org.joda.time.DateTime; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The integration account session. + */ +@JsonFlatten +@SkipParentValidation +public class IntegrationAccountSessionInner extends Resource { + /** + * The created time. + */ + @JsonProperty(value = "properties.createdTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime createdTime; + + /** + * The changed time. + */ + @JsonProperty(value = "properties.changedTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime changedTime; + + /** + * The session content. + */ + @JsonProperty(value = "properties.content") + private Object content; + + /** + * Get the created time. + * + * @return the createdTime value + */ + public DateTime createdTime() { + return this.createdTime; + } + + /** + * Get the changed time. + * + * @return the changedTime value + */ + public DateTime changedTime() { + return this.changedTime; + } + + /** + * Get the session content. + * + * @return the content value + */ + public Object content() { + return this.content; + } + + /** + * Set the session content. + * + * @param content the content value to set + * @return the IntegrationAccountSessionInner object itself. + */ + public IntegrationAccountSessionInner withContent(Object content) { + this.content = content; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSessionsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSessionsImpl.java new file mode 100644 index 000000000000..0208773cd6ff --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSessionsImpl.java @@ -0,0 +1,85 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSessions; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSession; + +class IntegrationAccountSessionsImpl extends WrapperImpl implements IntegrationAccountSessions { + private final LogicManager manager; + + IntegrationAccountSessionsImpl(LogicManager manager) { + super(manager.inner().integrationAccountSessions()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + @Override + public IntegrationAccountSessionImpl define(String name) { + return wrapModel(name); + } + + private IntegrationAccountSessionImpl wrapModel(IntegrationAccountSessionInner inner) { + return new IntegrationAccountSessionImpl(inner, manager()); + } + + private IntegrationAccountSessionImpl wrapModel(String name) { + return new IntegrationAccountSessionImpl(name, this.manager()); + } + + @Override + public Observable listAsync(final String resourceGroupName, final String integrationAccountName) { + IntegrationAccountSessionsInner client = this.inner(); + return client.listAsync(resourceGroupName, integrationAccountName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public IntegrationAccountSession call(IntegrationAccountSessionInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String integrationAccountName, String sessionName) { + IntegrationAccountSessionsInner client = this.inner(); + return client.getAsync(resourceGroupName, integrationAccountName, sessionName) + .flatMap(new Func1>() { + @Override + public Observable call(IntegrationAccountSessionInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((IntegrationAccountSession)wrapModel(inner)); + } + } + }); + } + + @Override + public Completable deleteAsync(String resourceGroupName, String integrationAccountName, String sessionName) { + IntegrationAccountSessionsInner client = this.inner(); + return client.deleteAsync(resourceGroupName, integrationAccountName, sessionName).toCompletable(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSessionsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSessionsInner.java new file mode 100644 index 000000000000..39960059ae22 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountSessionsInner.java @@ -0,0 +1,736 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import com.microsoft.rest.Validator; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.Body; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.HTTP; +import retrofit2.http.Path; +import retrofit2.http.PUT; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationAccountSessions. + */ +public class IntegrationAccountSessionsInner { + /** The Retrofit service to perform REST calls. */ + private IntegrationAccountSessionsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationAccountSessionsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationAccountSessionsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationAccountSessionsService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationAccountSessions to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationAccountSessionsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSessions list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/sessions") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Query("$filter") String filter, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSessions get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/sessions/{sessionName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("sessionName") String sessionName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSessions createOrUpdate" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/sessions/{sessionName}") + Observable> createOrUpdate(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("sessionName") String sessionName, @Query("api-version") String apiVersion, @Body IntegrationAccountSessionInner session, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSessions delete" }) + @HTTP(path = "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/sessions/{sessionName}", method = "DELETE", hasBody = true) + Observable> delete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Path("sessionName") String sessionName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSessions listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of integration account sessions. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountSessionInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String integrationAccountName) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, integrationAccountName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account sessions. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String integrationAccountName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, integrationAccountName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account sessions. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountSessionInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String integrationAccountName) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account sessions. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountSessionInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String integrationAccountName) { + return listSinglePageAsync(resourceGroupName, integrationAccountName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account sessions. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountSessionInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String integrationAccountName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + final String filter = null; + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of integration account sessions. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: ChangedTime. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountSessionInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account sessions. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: ChangedTime. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account sessions. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: ChangedTime. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountSessionInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + return listWithServiceResponseAsync(resourceGroupName, integrationAccountName, top, filter) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account sessions. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: ChangedTime. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountSessionInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + return listSinglePageAsync(resourceGroupName, integrationAccountName, top, filter) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account sessions. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param integrationAccountName The integration account name. + ServiceResponse> * @param top The number of items to be included in the result. + ServiceResponse> * @param filter The filter to apply on the operation. Options for filters include: ChangedTime. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountSessionInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String integrationAccountName, final Integer top, final String filter) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountSessionInner object if successful. + */ + public IntegrationAccountSessionInner get(String resourceGroupName, String integrationAccountName, String sessionName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, sessionName).toBlocking().single().body(); + } + + /** + * Gets an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String integrationAccountName, String sessionName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, integrationAccountName, sessionName), serviceCallback); + } + + /** + * Gets an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountSessionInner object + */ + public Observable getAsync(String resourceGroupName, String integrationAccountName, String sessionName) { + return getWithServiceResponseAsync(resourceGroupName, integrationAccountName, sessionName).map(new Func1, IntegrationAccountSessionInner>() { + @Override + public IntegrationAccountSessionInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountSessionInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String sessionName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (sessionName == null) { + throw new IllegalArgumentException("Parameter sessionName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, integrationAccountName, sessionName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Creates or updates an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @param session The integration account session. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountSessionInner object if successful. + */ + public IntegrationAccountSessionInner createOrUpdate(String resourceGroupName, String integrationAccountName, String sessionName, IntegrationAccountSessionInner session) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, sessionName, session).toBlocking().single().body(); + } + + /** + * Creates or updates an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @param session The integration account session. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String sessionName, IntegrationAccountSessionInner session, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, sessionName, session), serviceCallback); + } + + /** + * Creates or updates an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @param session The integration account session. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountSessionInner object + */ + public Observable createOrUpdateAsync(String resourceGroupName, String integrationAccountName, String sessionName, IntegrationAccountSessionInner session) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, sessionName, session).map(new Func1, IntegrationAccountSessionInner>() { + @Override + public IntegrationAccountSessionInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Creates or updates an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @param session The integration account session. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountSessionInner object + */ + public Observable> createOrUpdateWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String sessionName, IntegrationAccountSessionInner session) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (sessionName == null) { + throw new IllegalArgumentException("Parameter sessionName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (session == null) { + throw new IllegalArgumentException("Parameter session is required and cannot be null."); + } + Validator.validate(session); + return service.createOrUpdate(this.client.subscriptionId(), resourceGroupName, integrationAccountName, sessionName, this.client.apiVersion(), session, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = createOrUpdateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse createOrUpdateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Deletes an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void delete(String resourceGroupName, String integrationAccountName, String sessionName) { + deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, sessionName).toBlocking().single().body(); + } + + /** + * Deletes an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture deleteAsync(String resourceGroupName, String integrationAccountName, String sessionName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, sessionName), serviceCallback); + } + + /** + * Deletes an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable deleteAsync(String resourceGroupName, String integrationAccountName, String sessionName) { + return deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName, sessionName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Deletes an integration account session. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param sessionName The integration account session name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> deleteWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, String sessionName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (sessionName == null) { + throw new IllegalArgumentException("Parameter sessionName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.delete(this.client.subscriptionId(), resourceGroupName, integrationAccountName, sessionName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = deleteDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse deleteDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of integration account sessions. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountSessionInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration account sessions. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration account sessions. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountSessionInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration account sessions. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountSessionInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration account sessions. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountSessionInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountsImpl.java new file mode 100644 index 000000000000..f08e8cb73394 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountsImpl.java @@ -0,0 +1,192 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * def + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.resources.collection.implementation.GroupableResourcesCoreImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccount; +import rx.Observable; +import rx.Completable; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; +import com.microsoft.azure.arm.resources.ResourceUtilsCore; +import com.microsoft.azure.arm.utils.RXMapper; +import rx.functions.Func1; +import com.microsoft.azure.PagedList; +import com.microsoft.azure.Page; +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.CallbackUrl; +import com.microsoft.azure.management.logic.v2019_05_01.KeyVaultKey; +import com.microsoft.azure.management.logic.v2019_05_01.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2019_05_01.ListKeyVaultKeysDefinition; +import com.microsoft.azure.management.logic.v2019_05_01.TrackingEventsDefinition; + +class IntegrationAccountsImpl extends GroupableResourcesCoreImpl implements IntegrationAccounts { + protected IntegrationAccountsImpl(LogicManager manager) { + super(manager.inner().integrationAccounts(), manager); + } + + @Override + protected Observable getInnerAsync(String resourceGroupName, String name) { + IntegrationAccountsInner client = this.inner(); + return client.getByResourceGroupAsync(resourceGroupName, name); + } + + @Override + protected Completable deleteInnerAsync(String resourceGroupName, String name) { + IntegrationAccountsInner client = this.inner(); + return client.deleteAsync(resourceGroupName, name).toCompletable(); + } + + @Override + public Observable deleteByIdsAsync(Collection ids) { + if (ids == null || ids.isEmpty()) { + return Observable.empty(); + } + Collection> observables = new ArrayList<>(); + for (String id : ids) { + final String resourceGroupName = ResourceUtilsCore.groupFromResourceId(id); + final String name = ResourceUtilsCore.nameFromResourceId(id); + Observable o = RXMapper.map(this.inner().deleteAsync(resourceGroupName, name), id); + observables.add(o); + } + return Observable.mergeDelayError(observables); + } + + @Override + public Observable deleteByIdsAsync(String...ids) { + return this.deleteByIdsAsync(new ArrayList(Arrays.asList(ids))); + } + + @Override + public void deleteByIds(Collection ids) { + if (ids != null && !ids.isEmpty()) { + this.deleteByIdsAsync(ids).toBlocking().last(); + } + } + + @Override + public void deleteByIds(String...ids) { + this.deleteByIds(new ArrayList(Arrays.asList(ids))); + } + + @Override + public PagedList listByResourceGroup(String resourceGroupName) { + IntegrationAccountsInner client = this.inner(); + return this.wrapList(client.listByResourceGroup(resourceGroupName)); + } + + @Override + public Observable listByResourceGroupAsync(String resourceGroupName) { + IntegrationAccountsInner client = this.inner(); + return client.listByResourceGroupAsync(resourceGroupName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public IntegrationAccount call(IntegrationAccountInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public PagedList list() { + IntegrationAccountsInner client = this.inner(); + return this.wrapList(client.list()); + } + + @Override + public Observable listAsync() { + IntegrationAccountsInner client = this.inner(); + return client.listAsync() + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public IntegrationAccount call(IntegrationAccountInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public IntegrationAccountImpl define(String name) { + return wrapModel(name); + } + + @Override + public Observable listCallbackUrlAsync(String resourceGroupName, String integrationAccountName, GetCallbackUrlParameters parameters) { + IntegrationAccountsInner client = this.inner(); + return client.listCallbackUrlAsync(resourceGroupName, integrationAccountName, parameters) + .map(new Func1() { + @Override + public CallbackUrl call(CallbackUrlInner inner) { + return new CallbackUrlImpl(inner, manager()); + } + }); + } + + @Override + public Observable listKeyVaultKeysAsync(String resourceGroupName, String integrationAccountName, ListKeyVaultKeysDefinition listKeyVaultKeys) { + IntegrationAccountsInner client = this.inner(); + return client.listKeyVaultKeysAsync(resourceGroupName, integrationAccountName, listKeyVaultKeys) + .flatMap(new Func1, Observable>() { + @Override + public Observable call(List innerList) { + return Observable.from(innerList); + } + }) + .map(new Func1() { + @Override + public KeyVaultKey call(KeyVaultKeyInner inner) { + return new KeyVaultKeyImpl(inner, manager()); + } + }); + } + + @Override + public Completable logTrackingEventsAsync(String resourceGroupName, String integrationAccountName, TrackingEventsDefinition logTrackingEvents) { + IntegrationAccountsInner client = this.inner(); + return client.logTrackingEventsAsync(resourceGroupName, integrationAccountName, logTrackingEvents).toCompletable(); + } + + @Override + public Observable regenerateAccessKeyAsync(String resourceGroupName, String integrationAccountName) { + IntegrationAccountsInner client = this.inner(); + return client.regenerateAccessKeyAsync(resourceGroupName, integrationAccountName) + .map(new Func1() { + @Override + public IntegrationAccount call(IntegrationAccountInner inner) { + return new IntegrationAccountImpl(inner.name(), inner, manager()); + } + }); + } + + @Override + protected IntegrationAccountImpl wrapModel(IntegrationAccountInner inner) { + return new IntegrationAccountImpl(inner.name(), inner, manager()); + } + + @Override + protected IntegrationAccountImpl wrapModel(String name) { + return new IntegrationAccountImpl(name, new IntegrationAccountInner(), this.manager()); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountsInner.java new file mode 100644 index 000000000000..11d6e4e3eaf4 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationAccountsInner.java @@ -0,0 +1,1609 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.collection.InnerSupportsGet; +import com.microsoft.azure.arm.collection.InnerSupportsDelete; +import com.microsoft.azure.arm.collection.InnerSupportsListing; +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.management.logic.v2019_05_01.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2019_05_01.KeyType; +import com.microsoft.azure.management.logic.v2019_05_01.ListKeyVaultKeysDefinition; +import com.microsoft.azure.management.logic.v2019_05_01.RegenerateActionParameter; +import com.microsoft.azure.management.logic.v2019_05_01.TrackingEventsDefinition; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import com.microsoft.rest.Validator; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.Body; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.HTTP; +import retrofit2.http.PATCH; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.PUT; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationAccounts. + */ +public class IntegrationAccountsInner implements InnerSupportsGet, InnerSupportsDelete, InnerSupportsListing { + /** The Retrofit service to perform REST calls. */ + private IntegrationAccountsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationAccountsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationAccountsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationAccountsService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationAccounts to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationAccountsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts list" }) + @GET("subscriptions/{subscriptionId}/providers/Microsoft.Logic/integrationAccounts") + Observable> list(@Path("subscriptionId") String subscriptionId, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts listByResourceGroup" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts") + Observable> listByResourceGroup(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts getByResourceGroup" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}") + Observable> getByResourceGroup(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts createOrUpdate" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}") + Observable> createOrUpdate(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Body IntegrationAccountInner integrationAccount, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts update" }) + @PATCH("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}") + Observable> update(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Body IntegrationAccountInner integrationAccount, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts delete" }) + @HTTP(path = "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}", method = "DELETE", hasBody = true) + Observable> delete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts listCallbackUrl" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/listCallbackUrl") + Observable> listCallbackUrl(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Body GetCallbackUrlParameters parameters, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts listKeyVaultKeys" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/listKeyVaultKeys") + Observable> listKeyVaultKeys(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Body ListKeyVaultKeysDefinition listKeyVaultKeys, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts logTrackingEvents" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/logTrackingEvents") + Observable> logTrackingEvents(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Body TrackingEventsDefinition logTrackingEvents, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts regenerateAccessKey" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/integrationAccounts/{integrationAccountName}/regenerateAccessKey") + Observable> regenerateAccessKey(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("integrationAccountName") String integrationAccountName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Body RegenerateActionParameter regenerateAccessKey, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts listByResourceGroupNext" }) + @GET + Observable> listByResourceGroupNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of integration accounts by subscription. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountInner> object if successful. + */ + public PagedList list() { + ServiceResponse> response = listSinglePageAsync().toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration accounts by subscription. + * + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration accounts by subscription. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountInner> object + */ + public Observable> listAsync() { + return listWithServiceResponseAsync() + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration accounts by subscription. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountInner> object + */ + public Observable>> listWithServiceResponseAsync() { + return listSinglePageAsync() + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration accounts by subscription. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync() { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + return service.list(this.client.subscriptionId(), this.client.apiVersion(), top, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of integration accounts by subscription. + * + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountInner> object if successful. + */ + public PagedList list(final Integer top) { + ServiceResponse> response = listSinglePageAsync(top).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration accounts by subscription. + * + * @param top The number of items to be included in the result. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final Integer top, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(top), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration accounts by subscription. + * + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountInner> object + */ + public Observable> listAsync(final Integer top) { + return listWithServiceResponseAsync(top) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration accounts by subscription. + * + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountInner> object + */ + public Observable>> listWithServiceResponseAsync(final Integer top) { + return listSinglePageAsync(top) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration accounts by subscription. + * + ServiceResponse> * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final Integer top) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), this.client.apiVersion(), top, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of integration accounts by resource group. + * + * @param resourceGroupName The resource group name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountInner> object if successful. + */ + public PagedList listByResourceGroup(final String resourceGroupName) { + ServiceResponse> response = listByResourceGroupSinglePageAsync(resourceGroupName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration accounts by resource group. + * + * @param resourceGroupName The resource group name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listByResourceGroupAsync(final String resourceGroupName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listByResourceGroupSinglePageAsync(resourceGroupName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration accounts by resource group. + * + * @param resourceGroupName The resource group name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountInner> object + */ + public Observable> listByResourceGroupAsync(final String resourceGroupName) { + return listByResourceGroupWithServiceResponseAsync(resourceGroupName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration accounts by resource group. + * + * @param resourceGroupName The resource group name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountInner> object + */ + public Observable>> listByResourceGroupWithServiceResponseAsync(final String resourceGroupName) { + return listByResourceGroupSinglePageAsync(resourceGroupName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listByResourceGroupNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration accounts by resource group. + * + * @param resourceGroupName The resource group name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listByResourceGroupSinglePageAsync(final String resourceGroupName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + return service.listByResourceGroup(this.client.subscriptionId(), resourceGroupName, this.client.apiVersion(), top, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listByResourceGroupDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of integration accounts by resource group. + * + * @param resourceGroupName The resource group name. + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountInner> object if successful. + */ + public PagedList listByResourceGroup(final String resourceGroupName, final Integer top) { + ServiceResponse> response = listByResourceGroupSinglePageAsync(resourceGroupName, top).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration accounts by resource group. + * + * @param resourceGroupName The resource group name. + * @param top The number of items to be included in the result. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listByResourceGroupAsync(final String resourceGroupName, final Integer top, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listByResourceGroupSinglePageAsync(resourceGroupName, top), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration accounts by resource group. + * + * @param resourceGroupName The resource group name. + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountInner> object + */ + public Observable> listByResourceGroupAsync(final String resourceGroupName, final Integer top) { + return listByResourceGroupWithServiceResponseAsync(resourceGroupName, top) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration accounts by resource group. + * + * @param resourceGroupName The resource group name. + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountInner> object + */ + public Observable>> listByResourceGroupWithServiceResponseAsync(final String resourceGroupName, final Integer top) { + return listByResourceGroupSinglePageAsync(resourceGroupName, top) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listByResourceGroupNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration accounts by resource group. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listByResourceGroupSinglePageAsync(final String resourceGroupName, final Integer top) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.listByResourceGroup(this.client.subscriptionId(), resourceGroupName, this.client.apiVersion(), top, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listByResourceGroupDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listByResourceGroupDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountInner object if successful. + */ + public IntegrationAccountInner getByResourceGroup(String resourceGroupName, String integrationAccountName) { + return getByResourceGroupWithServiceResponseAsync(resourceGroupName, integrationAccountName).toBlocking().single().body(); + } + + /** + * Gets an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getByResourceGroupAsync(String resourceGroupName, String integrationAccountName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getByResourceGroupWithServiceResponseAsync(resourceGroupName, integrationAccountName), serviceCallback); + } + + /** + * Gets an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountInner object + */ + public Observable getByResourceGroupAsync(String resourceGroupName, String integrationAccountName) { + return getByResourceGroupWithServiceResponseAsync(resourceGroupName, integrationAccountName).map(new Func1, IntegrationAccountInner>() { + @Override + public IntegrationAccountInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountInner object + */ + public Observable> getByResourceGroupWithServiceResponseAsync(String resourceGroupName, String integrationAccountName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.getByResourceGroup(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getByResourceGroupDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getByResourceGroupDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Creates or updates an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param integrationAccount The integration account. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountInner object if successful. + */ + public IntegrationAccountInner createOrUpdate(String resourceGroupName, String integrationAccountName, IntegrationAccountInner integrationAccount) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, integrationAccount).toBlocking().single().body(); + } + + /** + * Creates or updates an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param integrationAccount The integration account. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture createOrUpdateAsync(String resourceGroupName, String integrationAccountName, IntegrationAccountInner integrationAccount, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, integrationAccount), serviceCallback); + } + + /** + * Creates or updates an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param integrationAccount The integration account. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountInner object + */ + public Observable createOrUpdateAsync(String resourceGroupName, String integrationAccountName, IntegrationAccountInner integrationAccount) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, integrationAccountName, integrationAccount).map(new Func1, IntegrationAccountInner>() { + @Override + public IntegrationAccountInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Creates or updates an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param integrationAccount The integration account. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountInner object + */ + public Observable> createOrUpdateWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, IntegrationAccountInner integrationAccount) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (integrationAccount == null) { + throw new IllegalArgumentException("Parameter integrationAccount is required and cannot be null."); + } + Validator.validate(integrationAccount); + return service.createOrUpdate(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), integrationAccount, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = createOrUpdateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse createOrUpdateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Updates an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param integrationAccount The integration account. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountInner object if successful. + */ + public IntegrationAccountInner update(String resourceGroupName, String integrationAccountName, IntegrationAccountInner integrationAccount) { + return updateWithServiceResponseAsync(resourceGroupName, integrationAccountName, integrationAccount).toBlocking().single().body(); + } + + /** + * Updates an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param integrationAccount The integration account. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture updateAsync(String resourceGroupName, String integrationAccountName, IntegrationAccountInner integrationAccount, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(updateWithServiceResponseAsync(resourceGroupName, integrationAccountName, integrationAccount), serviceCallback); + } + + /** + * Updates an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param integrationAccount The integration account. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountInner object + */ + public Observable updateAsync(String resourceGroupName, String integrationAccountName, IntegrationAccountInner integrationAccount) { + return updateWithServiceResponseAsync(resourceGroupName, integrationAccountName, integrationAccount).map(new Func1, IntegrationAccountInner>() { + @Override + public IntegrationAccountInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Updates an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param integrationAccount The integration account. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountInner object + */ + public Observable> updateWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, IntegrationAccountInner integrationAccount) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (integrationAccount == null) { + throw new IllegalArgumentException("Parameter integrationAccount is required and cannot be null."); + } + Validator.validate(integrationAccount); + return service.update(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), integrationAccount, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = updateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse updateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Deletes an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void delete(String resourceGroupName, String integrationAccountName) { + deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName).toBlocking().single().body(); + } + + /** + * Deletes an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture deleteAsync(String resourceGroupName, String integrationAccountName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName), serviceCallback); + } + + /** + * Deletes an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable deleteAsync(String resourceGroupName, String integrationAccountName) { + return deleteWithServiceResponseAsync(resourceGroupName, integrationAccountName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Deletes an integration account. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> deleteWithServiceResponseAsync(String resourceGroupName, String integrationAccountName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.delete(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = deleteDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse deleteDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets the integration account callback URL. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param parameters The callback URL parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the CallbackUrlInner object if successful. + */ + public CallbackUrlInner listCallbackUrl(String resourceGroupName, String integrationAccountName, GetCallbackUrlParameters parameters) { + return listCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, parameters).toBlocking().single().body(); + } + + /** + * Gets the integration account callback URL. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param parameters The callback URL parameters. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture listCallbackUrlAsync(String resourceGroupName, String integrationAccountName, GetCallbackUrlParameters parameters, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, parameters), serviceCallback); + } + + /** + * Gets the integration account callback URL. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param parameters The callback URL parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the CallbackUrlInner object + */ + public Observable listCallbackUrlAsync(String resourceGroupName, String integrationAccountName, GetCallbackUrlParameters parameters) { + return listCallbackUrlWithServiceResponseAsync(resourceGroupName, integrationAccountName, parameters).map(new Func1, CallbackUrlInner>() { + @Override + public CallbackUrlInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets the integration account callback URL. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param parameters The callback URL parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the CallbackUrlInner object + */ + public Observable> listCallbackUrlWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, GetCallbackUrlParameters parameters) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (parameters == null) { + throw new IllegalArgumentException("Parameter parameters is required and cannot be null."); + } + Validator.validate(parameters); + return service.listCallbackUrl(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), parameters, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = listCallbackUrlDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse listCallbackUrlDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets the integration account's Key Vault keys. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param listKeyVaultKeys The key vault parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the List<KeyVaultKeyInner> object if successful. + */ + public List listKeyVaultKeys(String resourceGroupName, String integrationAccountName, ListKeyVaultKeysDefinition listKeyVaultKeys) { + return listKeyVaultKeysWithServiceResponseAsync(resourceGroupName, integrationAccountName, listKeyVaultKeys).toBlocking().single().body(); + } + + /** + * Gets the integration account's Key Vault keys. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param listKeyVaultKeys The key vault parameters. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listKeyVaultKeysAsync(String resourceGroupName, String integrationAccountName, ListKeyVaultKeysDefinition listKeyVaultKeys, final ServiceCallback> serviceCallback) { + return ServiceFuture.fromResponse(listKeyVaultKeysWithServiceResponseAsync(resourceGroupName, integrationAccountName, listKeyVaultKeys), serviceCallback); + } + + /** + * Gets the integration account's Key Vault keys. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param listKeyVaultKeys The key vault parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<KeyVaultKeyInner> object + */ + public Observable> listKeyVaultKeysAsync(String resourceGroupName, String integrationAccountName, ListKeyVaultKeysDefinition listKeyVaultKeys) { + return listKeyVaultKeysWithServiceResponseAsync(resourceGroupName, integrationAccountName, listKeyVaultKeys).map(new Func1>, List>() { + @Override + public List call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets the integration account's Key Vault keys. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param listKeyVaultKeys The key vault parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<KeyVaultKeyInner> object + */ + public Observable>> listKeyVaultKeysWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, ListKeyVaultKeysDefinition listKeyVaultKeys) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (listKeyVaultKeys == null) { + throw new IllegalArgumentException("Parameter listKeyVaultKeys is required and cannot be null."); + } + Validator.validate(listKeyVaultKeys); + return service.listKeyVaultKeys(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), listKeyVaultKeys, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listKeyVaultKeysDelegate(response); + List items = null; + if (result.body() != null) { + items = result.body().items(); + } + ServiceResponse> clientResponse = new ServiceResponse>(items, result.response()); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listKeyVaultKeysDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Logs the integration account's tracking events. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param logTrackingEvents The callback URL parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void logTrackingEvents(String resourceGroupName, String integrationAccountName, TrackingEventsDefinition logTrackingEvents) { + logTrackingEventsWithServiceResponseAsync(resourceGroupName, integrationAccountName, logTrackingEvents).toBlocking().single().body(); + } + + /** + * Logs the integration account's tracking events. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param logTrackingEvents The callback URL parameters. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture logTrackingEventsAsync(String resourceGroupName, String integrationAccountName, TrackingEventsDefinition logTrackingEvents, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(logTrackingEventsWithServiceResponseAsync(resourceGroupName, integrationAccountName, logTrackingEvents), serviceCallback); + } + + /** + * Logs the integration account's tracking events. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param logTrackingEvents The callback URL parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable logTrackingEventsAsync(String resourceGroupName, String integrationAccountName, TrackingEventsDefinition logTrackingEvents) { + return logTrackingEventsWithServiceResponseAsync(resourceGroupName, integrationAccountName, logTrackingEvents).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Logs the integration account's tracking events. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param logTrackingEvents The callback URL parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> logTrackingEventsWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, TrackingEventsDefinition logTrackingEvents) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (logTrackingEvents == null) { + throw new IllegalArgumentException("Parameter logTrackingEvents is required and cannot be null."); + } + Validator.validate(logTrackingEvents); + return service.logTrackingEvents(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), logTrackingEvents, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = logTrackingEventsDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse logTrackingEventsDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Regenerates the integration account access key. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountInner object if successful. + */ + public IntegrationAccountInner regenerateAccessKey(String resourceGroupName, String integrationAccountName) { + return regenerateAccessKeyWithServiceResponseAsync(resourceGroupName, integrationAccountName).toBlocking().single().body(); + } + + /** + * Regenerates the integration account access key. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture regenerateAccessKeyAsync(String resourceGroupName, String integrationAccountName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(regenerateAccessKeyWithServiceResponseAsync(resourceGroupName, integrationAccountName), serviceCallback); + } + + /** + * Regenerates the integration account access key. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountInner object + */ + public Observable regenerateAccessKeyAsync(String resourceGroupName, String integrationAccountName) { + return regenerateAccessKeyWithServiceResponseAsync(resourceGroupName, integrationAccountName).map(new Func1, IntegrationAccountInner>() { + @Override + public IntegrationAccountInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Regenerates the integration account access key. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountInner object + */ + public Observable> regenerateAccessKeyWithServiceResponseAsync(String resourceGroupName, String integrationAccountName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final KeyType keyType = null; + RegenerateActionParameter regenerateAccessKey = new RegenerateActionParameter(); + regenerateAccessKey.withKeyType(null); + return service.regenerateAccessKey(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), this.client.acceptLanguage(), regenerateAccessKey, this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = regenerateAccessKeyDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Regenerates the integration account access key. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param keyType The key type. Possible values include: 'NotSpecified', 'Primary', 'Secondary' + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationAccountInner object if successful. + */ + public IntegrationAccountInner regenerateAccessKey(String resourceGroupName, String integrationAccountName, KeyType keyType) { + return regenerateAccessKeyWithServiceResponseAsync(resourceGroupName, integrationAccountName, keyType).toBlocking().single().body(); + } + + /** + * Regenerates the integration account access key. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param keyType The key type. Possible values include: 'NotSpecified', 'Primary', 'Secondary' + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture regenerateAccessKeyAsync(String resourceGroupName, String integrationAccountName, KeyType keyType, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(regenerateAccessKeyWithServiceResponseAsync(resourceGroupName, integrationAccountName, keyType), serviceCallback); + } + + /** + * Regenerates the integration account access key. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param keyType The key type. Possible values include: 'NotSpecified', 'Primary', 'Secondary' + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountInner object + */ + public Observable regenerateAccessKeyAsync(String resourceGroupName, String integrationAccountName, KeyType keyType) { + return regenerateAccessKeyWithServiceResponseAsync(resourceGroupName, integrationAccountName, keyType).map(new Func1, IntegrationAccountInner>() { + @Override + public IntegrationAccountInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Regenerates the integration account access key. + * + * @param resourceGroupName The resource group name. + * @param integrationAccountName The integration account name. + * @param keyType The key type. Possible values include: 'NotSpecified', 'Primary', 'Secondary' + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationAccountInner object + */ + public Observable> regenerateAccessKeyWithServiceResponseAsync(String resourceGroupName, String integrationAccountName, KeyType keyType) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (integrationAccountName == null) { + throw new IllegalArgumentException("Parameter integrationAccountName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + RegenerateActionParameter regenerateAccessKey = new RegenerateActionParameter(); + regenerateAccessKey.withKeyType(keyType); + return service.regenerateAccessKey(this.client.subscriptionId(), resourceGroupName, integrationAccountName, this.client.apiVersion(), this.client.acceptLanguage(), regenerateAccessKey, this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = regenerateAccessKeyDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse regenerateAccessKeyDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of integration accounts by subscription. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration accounts by subscription. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration accounts by subscription. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration accounts by subscription. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration accounts by subscription. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of integration accounts by resource group. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationAccountInner> object if successful. + */ + public PagedList listByResourceGroupNext(final String nextPageLink) { + ServiceResponse> response = listByResourceGroupNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration accounts by resource group. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listByResourceGroupNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listByResourceGroupNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration accounts by resource group. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountInner> object + */ + public Observable> listByResourceGroupNextAsync(final String nextPageLink) { + return listByResourceGroupNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration accounts by resource group. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationAccountInner> object + */ + public Observable>> listByResourceGroupNextWithServiceResponseAsync(final String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listByResourceGroupNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration accounts by resource group. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationAccountInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listByResourceGroupNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listByResourceGroupNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listByResourceGroupNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listByResourceGroupNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentImpl.java new file mode 100644 index 000000000000..7a660e6e63f6 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentImpl.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.resources.models.implementation.GroupableResourceCoreImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironment; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentProperties; + +class IntegrationServiceEnvironmentImpl extends GroupableResourceCoreImpl implements IntegrationServiceEnvironment, IntegrationServiceEnvironment.Definition, IntegrationServiceEnvironment.Update { + IntegrationServiceEnvironmentImpl(String name, IntegrationServiceEnvironmentInner inner, LogicManager manager) { + super(name, inner, manager); + } + + @Override + public Observable createResourceAsync() { + IntegrationServiceEnvironmentsInner client = this.manager().inner().integrationServiceEnvironments(); + return client.createOrUpdateAsync(this.resourceGroupName(), this.name(), this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + public Observable updateResourceAsync() { + IntegrationServiceEnvironmentsInner client = this.manager().inner().integrationServiceEnvironments(); + return client.updateAsync(this.resourceGroupName(), this.name(), this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + protected Observable getInnerAsync() { + IntegrationServiceEnvironmentsInner client = this.manager().inner().integrationServiceEnvironments(); + return client.getByResourceGroupAsync(this.resourceGroupName(), this.name()); + } + + @Override + public boolean isInCreateMode() { + return this.inner().id() == null; + } + + + @Override + public IntegrationServiceEnvironmentProperties properties() { + return this.inner().properties(); + } + + @Override + public IntegrationServiceEnvironmentSkuInner sku() { + return this.inner().sku(); + } + + @Override + public IntegrationServiceEnvironmentImpl withProperties(IntegrationServiceEnvironmentProperties properties) { + this.inner().withProperties(properties); + return this; + } + + @Override + public IntegrationServiceEnvironmentImpl withSku(IntegrationServiceEnvironmentSkuInner sku) { + this.inner().withSku(sku); + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentInner.java new file mode 100644 index 000000000000..ef2170ab35d7 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentInner.java @@ -0,0 +1,73 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentProperties; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The integration service environment. + */ +@SkipParentValidation +public class IntegrationServiceEnvironmentInner extends Resource { + /** + * The integration service environment properties. + */ + @JsonProperty(value = "properties") + private IntegrationServiceEnvironmentProperties properties; + + /** + * The sku. + */ + @JsonProperty(value = "sku") + private IntegrationServiceEnvironmentSkuInner sku; + + /** + * Get the integration service environment properties. + * + * @return the properties value + */ + public IntegrationServiceEnvironmentProperties properties() { + return this.properties; + } + + /** + * Set the integration service environment properties. + * + * @param properties the properties value to set + * @return the IntegrationServiceEnvironmentInner object itself. + */ + public IntegrationServiceEnvironmentInner withProperties(IntegrationServiceEnvironmentProperties properties) { + this.properties = properties; + return this; + } + + /** + * Get the sku. + * + * @return the sku value + */ + public IntegrationServiceEnvironmentSkuInner sku() { + return this.sku; + } + + /** + * Set the sku. + * + * @param sku the sku value to set + * @return the IntegrationServiceEnvironmentInner object itself. + */ + public IntegrationServiceEnvironmentInner withSku(IntegrationServiceEnvironmentSkuInner sku) { + this.sku = sku; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentManagedApiOperationsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentManagedApiOperationsImpl.java new file mode 100644 index 000000000000..4b9bc5381361 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentManagedApiOperationsImpl.java @@ -0,0 +1,53 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentManagedApiOperations; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.ApiOperation; + +class IntegrationServiceEnvironmentManagedApiOperationsImpl extends WrapperImpl implements IntegrationServiceEnvironmentManagedApiOperations { + private final LogicManager manager; + + IntegrationServiceEnvironmentManagedApiOperationsImpl(LogicManager manager) { + super(manager.inner().integrationServiceEnvironmentManagedApiOperations()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + private ApiOperationImpl wrapModel(ApiOperationInner inner) { + return new ApiOperationImpl(inner, manager()); + } + + @Override + public Observable listAsync(final String resourceGroup, final String integrationServiceEnvironmentName, final String apiName) { + IntegrationServiceEnvironmentManagedApiOperationsInner client = this.inner(); + return client.listAsync(resourceGroup, integrationServiceEnvironmentName, apiName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public ApiOperation call(ApiOperationInner inner) { + return wrapModel(inner); + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentManagedApiOperationsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentManagedApiOperationsInner.java new file mode 100644 index 000000000000..0eedb90d4fab --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentManagedApiOperationsInner.java @@ -0,0 +1,311 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationServiceEnvironmentManagedApiOperations. + */ +public class IntegrationServiceEnvironmentManagedApiOperationsInner { + /** The Retrofit service to perform REST calls. */ + private IntegrationServiceEnvironmentManagedApiOperationsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationServiceEnvironmentManagedApiOperationsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationServiceEnvironmentManagedApiOperationsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationServiceEnvironmentManagedApiOperationsService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationServiceEnvironmentManagedApiOperations to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationServiceEnvironmentManagedApiOperationsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentManagedApiOperations list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}/managedApis/{apiName}/apiOperations") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Path("apiName") String apiName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentManagedApiOperations listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets the managed Api operations. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<ApiOperationInner> object if successful. + */ + public PagedList list(final String resourceGroup, final String integrationServiceEnvironmentName, final String apiName) { + ServiceResponse> response = listSinglePageAsync(resourceGroup, integrationServiceEnvironmentName, apiName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets the managed Api operations. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroup, final String integrationServiceEnvironmentName, final String apiName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroup, integrationServiceEnvironmentName, apiName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets the managed Api operations. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<ApiOperationInner> object + */ + public Observable> listAsync(final String resourceGroup, final String integrationServiceEnvironmentName, final String apiName) { + return listWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets the managed Api operations. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<ApiOperationInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroup, final String integrationServiceEnvironmentName, final String apiName) { + return listSinglePageAsync(resourceGroup, integrationServiceEnvironmentName, apiName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets the managed Api operations. + * + ServiceResponse> * @param resourceGroup The resource group. + ServiceResponse> * @param integrationServiceEnvironmentName The integration service environment name. + ServiceResponse> * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<ApiOperationInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroup, final String integrationServiceEnvironmentName, final String apiName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (apiName == null) { + throw new IllegalArgumentException("Parameter apiName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, apiName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets the managed Api operations. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<ApiOperationInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets the managed Api operations. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets the managed Api operations. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<ApiOperationInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets the managed Api operations. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<ApiOperationInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets the managed Api operations. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<ApiOperationInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentManagedApisImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentManagedApisImpl.java new file mode 100644 index 000000000000..ab3ed985cd8f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentManagedApisImpl.java @@ -0,0 +1,85 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentManagedApis; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.ManagedApi; + +class IntegrationServiceEnvironmentManagedApisImpl extends WrapperImpl implements IntegrationServiceEnvironmentManagedApis { + private final LogicManager manager; + + IntegrationServiceEnvironmentManagedApisImpl(LogicManager manager) { + super(manager.inner().integrationServiceEnvironmentManagedApis()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + @Override + public ManagedApiImpl define(String name) { + return wrapModel(name); + } + + private ManagedApiImpl wrapModel(ManagedApiInner inner) { + return new ManagedApiImpl(inner, manager()); + } + + private ManagedApiImpl wrapModel(String name) { + return new ManagedApiImpl(name, this.manager()); + } + + @Override + public Observable listAsync(final String resourceGroup, final String integrationServiceEnvironmentName) { + IntegrationServiceEnvironmentManagedApisInner client = this.inner(); + return client.listAsync(resourceGroup, integrationServiceEnvironmentName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public ManagedApi call(ManagedApiInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + IntegrationServiceEnvironmentManagedApisInner client = this.inner(); + return client.getAsync(resourceGroup, integrationServiceEnvironmentName, apiName) + .flatMap(new Func1>() { + @Override + public Observable call(ManagedApiInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((ManagedApi)wrapModel(inner)); + } + } + }); + } + + @Override + public Completable deleteAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + IntegrationServiceEnvironmentManagedApisInner client = this.inner(); + return client.deleteAsync(resourceGroup, integrationServiceEnvironmentName, apiName).toCompletable(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentManagedApisInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentManagedApisInner.java new file mode 100644 index 000000000000..cb271a110f74 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentManagedApisInner.java @@ -0,0 +1,757 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.HTTP; +import retrofit2.http.Path; +import retrofit2.http.PUT; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationServiceEnvironmentManagedApis. + */ +public class IntegrationServiceEnvironmentManagedApisInner { + /** The Retrofit service to perform REST calls. */ + private IntegrationServiceEnvironmentManagedApisService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationServiceEnvironmentManagedApisInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationServiceEnvironmentManagedApisInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationServiceEnvironmentManagedApisService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationServiceEnvironmentManagedApis to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationServiceEnvironmentManagedApisService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentManagedApis list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}/managedApis") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentManagedApis get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}/managedApis/{apiName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Path("apiName") String apiName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentManagedApis put" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}/managedApis/{apiName}") + Observable> put(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Path("apiName") String apiName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentManagedApis beginPut" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}/managedApis/{apiName}") + Observable> beginPut(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Path("apiName") String apiName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentManagedApis delete" }) + @HTTP(path = "subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}/managedApis/{apiName}", method = "DELETE", hasBody = true) + Observable> delete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Path("apiName") String apiName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentManagedApis beginDelete" }) + @HTTP(path = "subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}/managedApis/{apiName}", method = "DELETE", hasBody = true) + Observable> beginDelete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Path("apiName") String apiName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentManagedApis listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets the integration service environment managed Apis. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<ManagedApiInner> object if successful. + */ + public PagedList list(final String resourceGroup, final String integrationServiceEnvironmentName) { + ServiceResponse> response = listSinglePageAsync(resourceGroup, integrationServiceEnvironmentName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets the integration service environment managed Apis. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroup, final String integrationServiceEnvironmentName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroup, integrationServiceEnvironmentName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets the integration service environment managed Apis. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<ManagedApiInner> object + */ + public Observable> listAsync(final String resourceGroup, final String integrationServiceEnvironmentName) { + return listWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets the integration service environment managed Apis. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<ManagedApiInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroup, final String integrationServiceEnvironmentName) { + return listSinglePageAsync(resourceGroup, integrationServiceEnvironmentName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets the integration service environment managed Apis. + * + ServiceResponse> * @param resourceGroup The resource group. + ServiceResponse> * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<ManagedApiInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroup, final String integrationServiceEnvironmentName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets the integration service environment managed Api. + * + * @param resourceGroup The resource group name. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the ManagedApiInner object if successful. + */ + public ManagedApiInner get(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + return getWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName).toBlocking().single().body(); + } + + /** + * Gets the integration service environment managed Api. + * + * @param resourceGroup The resource group name. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName), serviceCallback); + } + + /** + * Gets the integration service environment managed Api. + * + * @param resourceGroup The resource group name. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the ManagedApiInner object + */ + public Observable getAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + return getWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName).map(new Func1, ManagedApiInner>() { + @Override + public ManagedApiInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets the integration service environment managed Api. + * + * @param resourceGroup The resource group name. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the ManagedApiInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (apiName == null) { + throw new IllegalArgumentException("Parameter apiName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, apiName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Puts the integration service environment managed Api. + * + * @param resourceGroup The resource group name. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the ManagedApiInner object if successful. + */ + public ManagedApiInner put(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + return putWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName).toBlocking().last().body(); + } + + /** + * Puts the integration service environment managed Api. + * + * @param resourceGroup The resource group name. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture putAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(putWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName), serviceCallback); + } + + /** + * Puts the integration service environment managed Api. + * + * @param resourceGroup The resource group name. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + public Observable putAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + return putWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName).map(new Func1, ManagedApiInner>() { + @Override + public ManagedApiInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Puts the integration service environment managed Api. + * + * @param resourceGroup The resource group name. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + public Observable> putWithServiceResponseAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (apiName == null) { + throw new IllegalArgumentException("Parameter apiName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + Observable> observable = service.put(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, apiName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()); + return client.getAzureClient().getPutOrPatchResultAsync(observable, new TypeToken() { }.getType()); + } + + /** + * Puts the integration service environment managed Api. + * + * @param resourceGroup The resource group name. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the ManagedApiInner object if successful. + */ + public ManagedApiInner beginPut(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + return beginPutWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName).toBlocking().single().body(); + } + + /** + * Puts the integration service environment managed Api. + * + * @param resourceGroup The resource group name. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture beginPutAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(beginPutWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName), serviceCallback); + } + + /** + * Puts the integration service environment managed Api. + * + * @param resourceGroup The resource group name. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the ManagedApiInner object + */ + public Observable beginPutAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + return beginPutWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName).map(new Func1, ManagedApiInner>() { + @Override + public ManagedApiInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Puts the integration service environment managed Api. + * + * @param resourceGroup The resource group name. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the ManagedApiInner object + */ + public Observable> beginPutWithServiceResponseAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (apiName == null) { + throw new IllegalArgumentException("Parameter apiName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.beginPut(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, apiName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = beginPutDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse beginPutDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Deletes the integration service environment managed Api. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void delete(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + deleteWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName).toBlocking().last().body(); + } + + /** + * Deletes the integration service environment managed Api. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture deleteAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName), serviceCallback); + } + + /** + * Deletes the integration service environment managed Api. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + public Observable deleteAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + return deleteWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Deletes the integration service environment managed Api. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + public Observable> deleteWithServiceResponseAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (apiName == null) { + throw new IllegalArgumentException("Parameter apiName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + Observable> observable = service.delete(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, apiName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()); + return client.getAzureClient().getPostOrDeleteResultAsync(observable, new TypeToken() { }.getType()); + } + + /** + * Deletes the integration service environment managed Api. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void beginDelete(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + beginDeleteWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName).toBlocking().single().body(); + } + + /** + * Deletes the integration service environment managed Api. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture beginDeleteAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(beginDeleteWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName), serviceCallback); + } + + /** + * Deletes the integration service environment managed Api. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable beginDeleteAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + return beginDeleteWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, apiName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Deletes the integration service environment managed Api. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param apiName The api name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> beginDeleteWithServiceResponseAsync(String resourceGroup, String integrationServiceEnvironmentName, String apiName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (apiName == null) { + throw new IllegalArgumentException("Parameter apiName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.beginDelete(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, apiName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = beginDeleteDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse beginDeleteDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(202, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets the integration service environment managed Apis. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<ManagedApiInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets the integration service environment managed Apis. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets the integration service environment managed Apis. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<ManagedApiInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets the integration service environment managed Apis. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<ManagedApiInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets the integration service environment managed Apis. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<ManagedApiInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentNetworkHealthsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentNetworkHealthsImpl.java new file mode 100644 index 000000000000..532c87a88148 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentNetworkHealthsImpl.java @@ -0,0 +1,35 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * abc + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentNetworkHealths; +import rx.functions.Func1; +import rx.Observable; + +class IntegrationServiceEnvironmentNetworkHealthsImpl extends WrapperImpl implements IntegrationServiceEnvironmentNetworkHealths { + private final LogicManager manager; + + IntegrationServiceEnvironmentNetworkHealthsImpl(LogicManager manager) { + super(manager.inner().integrationServiceEnvironmentNetworkHealths()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + @Override + public Observable> getAsync(String resourceGroup, String integrationServiceEnvironmentName) { + IntegrationServiceEnvironmentNetworkHealthsInner client = this.inner(); + return client.getAsync(resourceGroup, integrationServiceEnvironmentName) + ;} + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentNetworkHealthsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentNetworkHealthsInner.java new file mode 100644 index 000000000000..e59e549a451c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentNetworkHealthsInner.java @@ -0,0 +1,147 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import java.util.Map; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.Query; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationServiceEnvironmentNetworkHealths. + */ +public class IntegrationServiceEnvironmentNetworkHealthsInner { + /** The Retrofit service to perform REST calls. */ + private IntegrationServiceEnvironmentNetworkHealthsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationServiceEnvironmentNetworkHealthsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationServiceEnvironmentNetworkHealthsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationServiceEnvironmentNetworkHealthsService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationServiceEnvironmentNetworkHealths to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationServiceEnvironmentNetworkHealthsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentNetworkHealths get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}/health/network") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets the integration service environment network health. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the Map<String, IntegrationServiceEnvironmentSubnetNetworkHealthInner> object if successful. + */ + public Map get(String resourceGroup, String integrationServiceEnvironmentName) { + return getWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName).toBlocking().single().body(); + } + + /** + * Gets the integration service environment network health. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> getAsync(String resourceGroup, String integrationServiceEnvironmentName, final ServiceCallback> serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName), serviceCallback); + } + + /** + * Gets the integration service environment network health. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the Map<String, IntegrationServiceEnvironmentSubnetNetworkHealthInner> object + */ + public Observable> getAsync(String resourceGroup, String integrationServiceEnvironmentName) { + return getWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName).map(new Func1>, Map>() { + @Override + public Map call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets the integration service environment network health. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the Map<String, IntegrationServiceEnvironmentSubnetNetworkHealthInner> object + */ + public Observable>> getWithServiceResponseAsync(String resourceGroup, String integrationServiceEnvironmentName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkuDefinitionImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkuDefinitionImpl.java new file mode 100644 index 000000000000..20ba17d38d5d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkuDefinitionImpl.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentSkuDefinition; +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentSkuCapacity; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentSkuDefinitionSku; + +class IntegrationServiceEnvironmentSkuDefinitionImpl extends WrapperImpl implements IntegrationServiceEnvironmentSkuDefinition { + private final LogicManager manager; + + IntegrationServiceEnvironmentSkuDefinitionImpl(IntegrationServiceEnvironmentSkuDefinitionInner inner, LogicManager manager) { + super(inner); + this.manager = manager; + } + + @Override + public LogicManager manager() { + return this.manager; + } + + + + @Override + public IntegrationServiceEnvironmentSkuCapacity capacity() { + return this.inner().capacity(); + } + + @Override + public String resourceType() { + return this.inner().resourceType(); + } + + @Override + public IntegrationServiceEnvironmentSkuDefinitionSku sku() { + return this.inner().sku(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkuDefinitionInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkuDefinitionInner.java new file mode 100644 index 000000000000..bdc8d788b07b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkuDefinitionInner.java @@ -0,0 +1,97 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentSkuDefinitionSku; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentSkuCapacity; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration service environment sku definition. + */ +public class IntegrationServiceEnvironmentSkuDefinitionInner { + /** + * The resource type. + */ + @JsonProperty(value = "resourceType") + private String resourceType; + + /** + * The sku. + */ + @JsonProperty(value = "sku") + private IntegrationServiceEnvironmentSkuDefinitionSku sku; + + /** + * The sku capacity. + */ + @JsonProperty(value = "capacity") + private IntegrationServiceEnvironmentSkuCapacity capacity; + + /** + * Get the resource type. + * + * @return the resourceType value + */ + public String resourceType() { + return this.resourceType; + } + + /** + * Set the resource type. + * + * @param resourceType the resourceType value to set + * @return the IntegrationServiceEnvironmentSkuDefinitionInner object itself. + */ + public IntegrationServiceEnvironmentSkuDefinitionInner withResourceType(String resourceType) { + this.resourceType = resourceType; + return this; + } + + /** + * Get the sku. + * + * @return the sku value + */ + public IntegrationServiceEnvironmentSkuDefinitionSku sku() { + return this.sku; + } + + /** + * Set the sku. + * + * @param sku the sku value to set + * @return the IntegrationServiceEnvironmentSkuDefinitionInner object itself. + */ + public IntegrationServiceEnvironmentSkuDefinitionInner withSku(IntegrationServiceEnvironmentSkuDefinitionSku sku) { + this.sku = sku; + return this; + } + + /** + * Get the sku capacity. + * + * @return the capacity value + */ + public IntegrationServiceEnvironmentSkuCapacity capacity() { + return this.capacity; + } + + /** + * Set the sku capacity. + * + * @param capacity the capacity value to set + * @return the IntegrationServiceEnvironmentSkuDefinitionInner object itself. + */ + public IntegrationServiceEnvironmentSkuDefinitionInner withCapacity(IntegrationServiceEnvironmentSkuCapacity capacity) { + this.capacity = capacity; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkuInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkuInner.java new file mode 100644 index 000000000000..d93ed3029f3f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkuInner.java @@ -0,0 +1,71 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentSkuName; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration service environment sku. + */ +public class IntegrationServiceEnvironmentSkuInner { + /** + * The sku name. Possible values include: 'NotSpecified', 'Premium', + * 'Developer'. + */ + @JsonProperty(value = "name") + private IntegrationServiceEnvironmentSkuName name; + + /** + * The sku capacity. + */ + @JsonProperty(value = "capacity") + private Integer capacity; + + /** + * Get the sku name. Possible values include: 'NotSpecified', 'Premium', 'Developer'. + * + * @return the name value + */ + public IntegrationServiceEnvironmentSkuName name() { + return this.name; + } + + /** + * Set the sku name. Possible values include: 'NotSpecified', 'Premium', 'Developer'. + * + * @param name the name value to set + * @return the IntegrationServiceEnvironmentSkuInner object itself. + */ + public IntegrationServiceEnvironmentSkuInner withName(IntegrationServiceEnvironmentSkuName name) { + this.name = name; + return this; + } + + /** + * Get the sku capacity. + * + * @return the capacity value + */ + public Integer capacity() { + return this.capacity; + } + + /** + * Set the sku capacity. + * + * @param capacity the capacity value to set + * @return the IntegrationServiceEnvironmentSkuInner object itself. + */ + public IntegrationServiceEnvironmentSkuInner withCapacity(Integer capacity) { + this.capacity = capacity; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkusImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkusImpl.java new file mode 100644 index 000000000000..9aa159ee01d5 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkusImpl.java @@ -0,0 +1,53 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentSkus; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentSkuDefinition; + +class IntegrationServiceEnvironmentSkusImpl extends WrapperImpl implements IntegrationServiceEnvironmentSkus { + private final LogicManager manager; + + IntegrationServiceEnvironmentSkusImpl(LogicManager manager) { + super(manager.inner().integrationServiceEnvironmentSkus()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + private IntegrationServiceEnvironmentSkuDefinitionImpl wrapModel(IntegrationServiceEnvironmentSkuDefinitionInner inner) { + return new IntegrationServiceEnvironmentSkuDefinitionImpl(inner, manager()); + } + + @Override + public Observable listAsync(final String resourceGroup, final String integrationServiceEnvironmentName) { + IntegrationServiceEnvironmentSkusInner client = this.inner(); + return client.listAsync(resourceGroup, integrationServiceEnvironmentName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public IntegrationServiceEnvironmentSkuDefinition call(IntegrationServiceEnvironmentSkuDefinitionInner inner) { + return wrapModel(inner); + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkusInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkusInner.java new file mode 100644 index 000000000000..f3caab1d316b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSkusInner.java @@ -0,0 +1,303 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationServiceEnvironmentSkus. + */ +public class IntegrationServiceEnvironmentSkusInner { + /** The Retrofit service to perform REST calls. */ + private IntegrationServiceEnvironmentSkusService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationServiceEnvironmentSkusInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationServiceEnvironmentSkusInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationServiceEnvironmentSkusService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationServiceEnvironmentSkus to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationServiceEnvironmentSkusService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentSkus list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}/skus") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentSkus listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of integration service environment Skus. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationServiceEnvironmentSkuDefinitionInner> object if successful. + */ + public PagedList list(final String resourceGroup, final String integrationServiceEnvironmentName) { + ServiceResponse> response = listSinglePageAsync(resourceGroup, integrationServiceEnvironmentName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration service environment Skus. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroup, final String integrationServiceEnvironmentName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroup, integrationServiceEnvironmentName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration service environment Skus. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentSkuDefinitionInner> object + */ + public Observable> listAsync(final String resourceGroup, final String integrationServiceEnvironmentName) { + return listWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration service environment Skus. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentSkuDefinitionInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroup, final String integrationServiceEnvironmentName) { + return listSinglePageAsync(resourceGroup, integrationServiceEnvironmentName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration service environment Skus. + * + ServiceResponse> * @param resourceGroup The resource group. + ServiceResponse> * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationServiceEnvironmentSkuDefinitionInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroup, final String integrationServiceEnvironmentName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of integration service environment Skus. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationServiceEnvironmentSkuDefinitionInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration service environment Skus. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration service environment Skus. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentSkuDefinitionInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration service environment Skus. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentSkuDefinitionInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration service environment Skus. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationServiceEnvironmentSkuDefinitionInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSubnetNetworkHealthInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSubnetNetworkHealthInner.java new file mode 100644 index 000000000000..b579076315bb --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentSubnetNetworkHealthInner.java @@ -0,0 +1,100 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentNetworkDependency; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentNetworkDependencyHealth; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentNetworkEndPointAccessibilityState; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The integration service environment subnet network health. + */ +public class IntegrationServiceEnvironmentSubnetNetworkHealthInner { + /** + * The outbound network dependencies. + */ + @JsonProperty(value = "outboundNetworkDependencies") + private List outboundNetworkDependencies; + + /** + * The integration service environment network health. + */ + @JsonProperty(value = "outboundNetworkHealth") + private IntegrationServiceEnvironmentNetworkDependencyHealth outboundNetworkHealth; + + /** + * The integration service environment network health state. Possible + * values include: 'NotSpecified', 'Unknown', 'Available', 'NotAvailable'. + */ + @JsonProperty(value = "networkDependencyHealthState", required = true) + private IntegrationServiceEnvironmentNetworkEndPointAccessibilityState networkDependencyHealthState; + + /** + * Get the outbound network dependencies. + * + * @return the outboundNetworkDependencies value + */ + public List outboundNetworkDependencies() { + return this.outboundNetworkDependencies; + } + + /** + * Set the outbound network dependencies. + * + * @param outboundNetworkDependencies the outboundNetworkDependencies value to set + * @return the IntegrationServiceEnvironmentSubnetNetworkHealthInner object itself. + */ + public IntegrationServiceEnvironmentSubnetNetworkHealthInner withOutboundNetworkDependencies(List outboundNetworkDependencies) { + this.outboundNetworkDependencies = outboundNetworkDependencies; + return this; + } + + /** + * Get the integration service environment network health. + * + * @return the outboundNetworkHealth value + */ + public IntegrationServiceEnvironmentNetworkDependencyHealth outboundNetworkHealth() { + return this.outboundNetworkHealth; + } + + /** + * Set the integration service environment network health. + * + * @param outboundNetworkHealth the outboundNetworkHealth value to set + * @return the IntegrationServiceEnvironmentSubnetNetworkHealthInner object itself. + */ + public IntegrationServiceEnvironmentSubnetNetworkHealthInner withOutboundNetworkHealth(IntegrationServiceEnvironmentNetworkDependencyHealth outboundNetworkHealth) { + this.outboundNetworkHealth = outboundNetworkHealth; + return this; + } + + /** + * Get the integration service environment network health state. Possible values include: 'NotSpecified', 'Unknown', 'Available', 'NotAvailable'. + * + * @return the networkDependencyHealthState value + */ + public IntegrationServiceEnvironmentNetworkEndPointAccessibilityState networkDependencyHealthState() { + return this.networkDependencyHealthState; + } + + /** + * Set the integration service environment network health state. Possible values include: 'NotSpecified', 'Unknown', 'Available', 'NotAvailable'. + * + * @param networkDependencyHealthState the networkDependencyHealthState value to set + * @return the IntegrationServiceEnvironmentSubnetNetworkHealthInner object itself. + */ + public IntegrationServiceEnvironmentSubnetNetworkHealthInner withNetworkDependencyHealthState(IntegrationServiceEnvironmentNetworkEndPointAccessibilityState networkDependencyHealthState) { + this.networkDependencyHealthState = networkDependencyHealthState; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentsImpl.java new file mode 100644 index 000000000000..907daa429f52 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentsImpl.java @@ -0,0 +1,144 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * def + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.resources.collection.implementation.GroupableResourcesCoreImpl; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironments; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironment; +import rx.Observable; +import rx.Completable; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; +import com.microsoft.azure.arm.resources.ResourceUtilsCore; +import com.microsoft.azure.arm.utils.RXMapper; +import rx.functions.Func1; +import com.microsoft.azure.PagedList; +import com.microsoft.azure.Page; + +class IntegrationServiceEnvironmentsImpl extends GroupableResourcesCoreImpl implements IntegrationServiceEnvironments { + protected IntegrationServiceEnvironmentsImpl(LogicManager manager) { + super(manager.inner().integrationServiceEnvironments(), manager); + } + + @Override + protected Observable getInnerAsync(String resourceGroupName, String name) { + IntegrationServiceEnvironmentsInner client = this.inner(); + return client.getByResourceGroupAsync(resourceGroupName, name); + } + + @Override + protected Completable deleteInnerAsync(String resourceGroupName, String name) { + IntegrationServiceEnvironmentsInner client = this.inner(); + return client.deleteAsync(resourceGroupName, name).toCompletable(); + } + + @Override + public Observable deleteByIdsAsync(Collection ids) { + if (ids == null || ids.isEmpty()) { + return Observable.empty(); + } + Collection> observables = new ArrayList<>(); + for (String id : ids) { + final String resourceGroupName = ResourceUtilsCore.groupFromResourceId(id); + final String name = ResourceUtilsCore.nameFromResourceId(id); + Observable o = RXMapper.map(this.inner().deleteAsync(resourceGroupName, name), id); + observables.add(o); + } + return Observable.mergeDelayError(observables); + } + + @Override + public Observable deleteByIdsAsync(String...ids) { + return this.deleteByIdsAsync(new ArrayList(Arrays.asList(ids))); + } + + @Override + public void deleteByIds(Collection ids) { + if (ids != null && !ids.isEmpty()) { + this.deleteByIdsAsync(ids).toBlocking().last(); + } + } + + @Override + public void deleteByIds(String...ids) { + this.deleteByIds(new ArrayList(Arrays.asList(ids))); + } + + @Override + public PagedList listByResourceGroup(String resourceGroupName) { + IntegrationServiceEnvironmentsInner client = this.inner(); + return this.wrapList(client.listByResourceGroup(resourceGroupName)); + } + + @Override + public Observable listByResourceGroupAsync(String resourceGroupName) { + IntegrationServiceEnvironmentsInner client = this.inner(); + return client.listByResourceGroupAsync(resourceGroupName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public IntegrationServiceEnvironment call(IntegrationServiceEnvironmentInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public PagedList list() { + IntegrationServiceEnvironmentsInner client = this.inner(); + return this.wrapList(client.list()); + } + + @Override + public Observable listAsync() { + IntegrationServiceEnvironmentsInner client = this.inner(); + return client.listAsync() + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public IntegrationServiceEnvironment call(IntegrationServiceEnvironmentInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public IntegrationServiceEnvironmentImpl define(String name) { + return wrapModel(name); + } + + @Override + public Completable restartAsync(String resourceGroup, String integrationServiceEnvironmentName) { + IntegrationServiceEnvironmentsInner client = this.inner(); + return client.restartAsync(resourceGroup, integrationServiceEnvironmentName).toCompletable(); + } + + @Override + protected IntegrationServiceEnvironmentImpl wrapModel(IntegrationServiceEnvironmentInner inner) { + return new IntegrationServiceEnvironmentImpl(inner.name(), inner, manager()); + } + + @Override + protected IntegrationServiceEnvironmentImpl wrapModel(String name) { + return new IntegrationServiceEnvironmentImpl(name, new IntegrationServiceEnvironmentInner(), this.manager()); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentsInner.java new file mode 100644 index 000000000000..e2907908a667 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/IntegrationServiceEnvironmentsInner.java @@ -0,0 +1,1379 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.collection.InnerSupportsGet; +import com.microsoft.azure.arm.collection.InnerSupportsDelete; +import com.microsoft.azure.arm.collection.InnerSupportsListing; +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import com.microsoft.rest.Validator; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.Body; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.HTTP; +import retrofit2.http.PATCH; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.PUT; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in IntegrationServiceEnvironments. + */ +public class IntegrationServiceEnvironmentsInner implements InnerSupportsGet, InnerSupportsDelete, InnerSupportsListing { + /** The Retrofit service to perform REST calls. */ + private IntegrationServiceEnvironmentsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of IntegrationServiceEnvironmentsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public IntegrationServiceEnvironmentsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(IntegrationServiceEnvironmentsService.class); + this.client = client; + } + + /** + * The interface defining all the services for IntegrationServiceEnvironments to be + * used by Retrofit to perform actually REST calls. + */ + interface IntegrationServiceEnvironmentsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironments list" }) + @GET("subscriptions/{subscriptionId}/providers/Microsoft.Logic/integrationServiceEnvironments") + Observable> list(@Path("subscriptionId") String subscriptionId, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironments listByResourceGroup" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments") + Observable> listByResourceGroup(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironments getByResourceGroup" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}") + Observable> getByResourceGroup(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironments createOrUpdate" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}") + Observable> createOrUpdate(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Query("api-version") String apiVersion, @Body IntegrationServiceEnvironmentInner integrationServiceEnvironment, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironments beginCreateOrUpdate" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}") + Observable> beginCreateOrUpdate(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Query("api-version") String apiVersion, @Body IntegrationServiceEnvironmentInner integrationServiceEnvironment, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironments update" }) + @PATCH("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}") + Observable> update(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Query("api-version") String apiVersion, @Body IntegrationServiceEnvironmentInner integrationServiceEnvironment, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironments beginUpdate" }) + @PATCH("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}") + Observable> beginUpdate(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Query("api-version") String apiVersion, @Body IntegrationServiceEnvironmentInner integrationServiceEnvironment, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironments delete" }) + @HTTP(path = "subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}", method = "DELETE", hasBody = true) + Observable> delete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironments restart" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Logic/integrationServiceEnvironments/{integrationServiceEnvironmentName}/restart") + Observable> restart(@Path("subscriptionId") String subscriptionId, @Path("resourceGroup") String resourceGroup, @Path("integrationServiceEnvironmentName") String integrationServiceEnvironmentName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironments listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironments listByResourceGroupNext" }) + @GET + Observable> listByResourceGroupNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of integration service environments by subscription. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationServiceEnvironmentInner> object if successful. + */ + public PagedList list() { + ServiceResponse> response = listSinglePageAsync().toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration service environments by subscription. + * + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration service environments by subscription. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentInner> object + */ + public Observable> listAsync() { + return listWithServiceResponseAsync() + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration service environments by subscription. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentInner> object + */ + public Observable>> listWithServiceResponseAsync() { + return listSinglePageAsync() + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration service environments by subscription. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationServiceEnvironmentInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync() { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + return service.list(this.client.subscriptionId(), this.client.apiVersion(), top, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of integration service environments by subscription. + * + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationServiceEnvironmentInner> object if successful. + */ + public PagedList list(final Integer top) { + ServiceResponse> response = listSinglePageAsync(top).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration service environments by subscription. + * + * @param top The number of items to be included in the result. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final Integer top, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(top), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration service environments by subscription. + * + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentInner> object + */ + public Observable> listAsync(final Integer top) { + return listWithServiceResponseAsync(top) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration service environments by subscription. + * + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentInner> object + */ + public Observable>> listWithServiceResponseAsync(final Integer top) { + return listSinglePageAsync(top) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration service environments by subscription. + * + ServiceResponse> * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationServiceEnvironmentInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final Integer top) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), this.client.apiVersion(), top, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of integration service environments by resource group. + * + * @param resourceGroup The resource group. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationServiceEnvironmentInner> object if successful. + */ + public PagedList listByResourceGroup(final String resourceGroup) { + ServiceResponse> response = listByResourceGroupSinglePageAsync(resourceGroup).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration service environments by resource group. + * + * @param resourceGroup The resource group. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listByResourceGroupAsync(final String resourceGroup, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listByResourceGroupSinglePageAsync(resourceGroup), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration service environments by resource group. + * + * @param resourceGroup The resource group. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentInner> object + */ + public Observable> listByResourceGroupAsync(final String resourceGroup) { + return listByResourceGroupWithServiceResponseAsync(resourceGroup) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration service environments by resource group. + * + * @param resourceGroup The resource group. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentInner> object + */ + public Observable>> listByResourceGroupWithServiceResponseAsync(final String resourceGroup) { + return listByResourceGroupSinglePageAsync(resourceGroup) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listByResourceGroupNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration service environments by resource group. + * + * @param resourceGroup The resource group. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationServiceEnvironmentInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listByResourceGroupSinglePageAsync(final String resourceGroup) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + return service.listByResourceGroup(this.client.subscriptionId(), resourceGroup, this.client.apiVersion(), top, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listByResourceGroupDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of integration service environments by resource group. + * + * @param resourceGroup The resource group. + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationServiceEnvironmentInner> object if successful. + */ + public PagedList listByResourceGroup(final String resourceGroup, final Integer top) { + ServiceResponse> response = listByResourceGroupSinglePageAsync(resourceGroup, top).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration service environments by resource group. + * + * @param resourceGroup The resource group. + * @param top The number of items to be included in the result. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listByResourceGroupAsync(final String resourceGroup, final Integer top, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listByResourceGroupSinglePageAsync(resourceGroup, top), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration service environments by resource group. + * + * @param resourceGroup The resource group. + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentInner> object + */ + public Observable> listByResourceGroupAsync(final String resourceGroup, final Integer top) { + return listByResourceGroupWithServiceResponseAsync(resourceGroup, top) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration service environments by resource group. + * + * @param resourceGroup The resource group. + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentInner> object + */ + public Observable>> listByResourceGroupWithServiceResponseAsync(final String resourceGroup, final Integer top) { + return listByResourceGroupSinglePageAsync(resourceGroup, top) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listByResourceGroupNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration service environments by resource group. + * + ServiceResponse> * @param resourceGroup The resource group. + ServiceResponse> * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationServiceEnvironmentInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listByResourceGroupSinglePageAsync(final String resourceGroup, final Integer top) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.listByResourceGroup(this.client.subscriptionId(), resourceGroup, this.client.apiVersion(), top, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listByResourceGroupDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listByResourceGroupDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationServiceEnvironmentInner object if successful. + */ + public IntegrationServiceEnvironmentInner getByResourceGroup(String resourceGroup, String integrationServiceEnvironmentName) { + return getByResourceGroupWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName).toBlocking().single().body(); + } + + /** + * Gets an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getByResourceGroupAsync(String resourceGroup, String integrationServiceEnvironmentName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getByResourceGroupWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName), serviceCallback); + } + + /** + * Gets an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationServiceEnvironmentInner object + */ + public Observable getByResourceGroupAsync(String resourceGroup, String integrationServiceEnvironmentName) { + return getByResourceGroupWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName).map(new Func1, IntegrationServiceEnvironmentInner>() { + @Override + public IntegrationServiceEnvironmentInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationServiceEnvironmentInner object + */ + public Observable> getByResourceGroupWithServiceResponseAsync(String resourceGroup, String integrationServiceEnvironmentName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.getByResourceGroup(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getByResourceGroupDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getByResourceGroupDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Creates or updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationServiceEnvironmentInner object if successful. + */ + public IntegrationServiceEnvironmentInner createOrUpdate(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + return createOrUpdateWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, integrationServiceEnvironment).toBlocking().last().body(); + } + + /** + * Creates or updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture createOrUpdateAsync(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(createOrUpdateWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, integrationServiceEnvironment), serviceCallback); + } + + /** + * Creates or updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + public Observable createOrUpdateAsync(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + return createOrUpdateWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, integrationServiceEnvironment).map(new Func1, IntegrationServiceEnvironmentInner>() { + @Override + public IntegrationServiceEnvironmentInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Creates or updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + public Observable> createOrUpdateWithServiceResponseAsync(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (integrationServiceEnvironment == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironment is required and cannot be null."); + } + Validator.validate(integrationServiceEnvironment); + Observable> observable = service.createOrUpdate(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, this.client.apiVersion(), integrationServiceEnvironment, this.client.acceptLanguage(), this.client.userAgent()); + return client.getAzureClient().getPutOrPatchResultAsync(observable, new TypeToken() { }.getType()); + } + + /** + * Creates or updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationServiceEnvironmentInner object if successful. + */ + public IntegrationServiceEnvironmentInner beginCreateOrUpdate(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + return beginCreateOrUpdateWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, integrationServiceEnvironment).toBlocking().single().body(); + } + + /** + * Creates or updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture beginCreateOrUpdateAsync(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(beginCreateOrUpdateWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, integrationServiceEnvironment), serviceCallback); + } + + /** + * Creates or updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationServiceEnvironmentInner object + */ + public Observable beginCreateOrUpdateAsync(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + return beginCreateOrUpdateWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, integrationServiceEnvironment).map(new Func1, IntegrationServiceEnvironmentInner>() { + @Override + public IntegrationServiceEnvironmentInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Creates or updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationServiceEnvironmentInner object + */ + public Observable> beginCreateOrUpdateWithServiceResponseAsync(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (integrationServiceEnvironment == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironment is required and cannot be null."); + } + Validator.validate(integrationServiceEnvironment); + return service.beginCreateOrUpdate(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, this.client.apiVersion(), integrationServiceEnvironment, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = beginCreateOrUpdateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse beginCreateOrUpdateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationServiceEnvironmentInner object if successful. + */ + public IntegrationServiceEnvironmentInner update(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + return updateWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, integrationServiceEnvironment).toBlocking().last().body(); + } + + /** + * Updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture updateAsync(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(updateWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, integrationServiceEnvironment), serviceCallback); + } + + /** + * Updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + public Observable updateAsync(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + return updateWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, integrationServiceEnvironment).map(new Func1, IntegrationServiceEnvironmentInner>() { + @Override + public IntegrationServiceEnvironmentInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + public Observable> updateWithServiceResponseAsync(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (integrationServiceEnvironment == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironment is required and cannot be null."); + } + Validator.validate(integrationServiceEnvironment); + Observable> observable = service.update(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, this.client.apiVersion(), integrationServiceEnvironment, this.client.acceptLanguage(), this.client.userAgent()); + return client.getAzureClient().getPutOrPatchResultAsync(observable, new TypeToken() { }.getType()); + } + + /** + * Updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the IntegrationServiceEnvironmentInner object if successful. + */ + public IntegrationServiceEnvironmentInner beginUpdate(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + return beginUpdateWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, integrationServiceEnvironment).toBlocking().single().body(); + } + + /** + * Updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture beginUpdateAsync(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(beginUpdateWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, integrationServiceEnvironment), serviceCallback); + } + + /** + * Updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationServiceEnvironmentInner object + */ + public Observable beginUpdateAsync(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + return beginUpdateWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName, integrationServiceEnvironment).map(new Func1, IntegrationServiceEnvironmentInner>() { + @Override + public IntegrationServiceEnvironmentInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Updates an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param integrationServiceEnvironment The integration service environment. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the IntegrationServiceEnvironmentInner object + */ + public Observable> beginUpdateWithServiceResponseAsync(String resourceGroup, String integrationServiceEnvironmentName, IntegrationServiceEnvironmentInner integrationServiceEnvironment) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (integrationServiceEnvironment == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironment is required and cannot be null."); + } + Validator.validate(integrationServiceEnvironment); + return service.beginUpdate(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, this.client.apiVersion(), integrationServiceEnvironment, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = beginUpdateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse beginUpdateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Deletes an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void delete(String resourceGroup, String integrationServiceEnvironmentName) { + deleteWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName).toBlocking().single().body(); + } + + /** + * Deletes an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture deleteAsync(String resourceGroup, String integrationServiceEnvironmentName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName), serviceCallback); + } + + /** + * Deletes an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable deleteAsync(String resourceGroup, String integrationServiceEnvironmentName) { + return deleteWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Deletes an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> deleteWithServiceResponseAsync(String resourceGroup, String integrationServiceEnvironmentName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.delete(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = deleteDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse deleteDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Restarts an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void restart(String resourceGroup, String integrationServiceEnvironmentName) { + restartWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName).toBlocking().single().body(); + } + + /** + * Restarts an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture restartAsync(String resourceGroup, String integrationServiceEnvironmentName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(restartWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName), serviceCallback); + } + + /** + * Restarts an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable restartAsync(String resourceGroup, String integrationServiceEnvironmentName) { + return restartWithServiceResponseAsync(resourceGroup, integrationServiceEnvironmentName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Restarts an integration service environment. + * + * @param resourceGroup The resource group. + * @param integrationServiceEnvironmentName The integration service environment name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> restartWithServiceResponseAsync(String resourceGroup, String integrationServiceEnvironmentName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroup == null) { + throw new IllegalArgumentException("Parameter resourceGroup is required and cannot be null."); + } + if (integrationServiceEnvironmentName == null) { + throw new IllegalArgumentException("Parameter integrationServiceEnvironmentName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.restart(this.client.subscriptionId(), resourceGroup, integrationServiceEnvironmentName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = restartDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse restartDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of integration service environments by subscription. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationServiceEnvironmentInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration service environments by subscription. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration service environments by subscription. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration service environments by subscription. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration service environments by subscription. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationServiceEnvironmentInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of integration service environments by resource group. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<IntegrationServiceEnvironmentInner> object if successful. + */ + public PagedList listByResourceGroupNext(final String nextPageLink) { + ServiceResponse> response = listByResourceGroupNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of integration service environments by resource group. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listByResourceGroupNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listByResourceGroupNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of integration service environments by resource group. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentInner> object + */ + public Observable> listByResourceGroupNextAsync(final String nextPageLink) { + return listByResourceGroupNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of integration service environments by resource group. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<IntegrationServiceEnvironmentInner> object + */ + public Observable>> listByResourceGroupNextWithServiceResponseAsync(final String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listByResourceGroupNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of integration service environments by resource group. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<IntegrationServiceEnvironmentInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listByResourceGroupNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listByResourceGroupNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listByResourceGroupNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listByResourceGroupNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/JsonSchemaImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/JsonSchemaImpl.java new file mode 100644 index 000000000000..cbb7b539822e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/JsonSchemaImpl.java @@ -0,0 +1,36 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.JsonSchema; +import com.microsoft.azure.arm.model.implementation.WrapperImpl; + +class JsonSchemaImpl extends WrapperImpl implements JsonSchema { + private final LogicManager manager; + JsonSchemaImpl(JsonSchemaInner inner, LogicManager manager) { + super(inner); + this.manager = manager; + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public String content() { + return this.inner().content(); + } + + @Override + public String title() { + return this.inner().title(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/JsonSchemaInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/JsonSchemaInner.java new file mode 100644 index 000000000000..f35fb8d8f52a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/JsonSchemaInner.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The JSON schema. + */ +public class JsonSchemaInner { + /** + * The JSON title. + */ + @JsonProperty(value = "title") + private String title; + + /** + * The JSON content. + */ + @JsonProperty(value = "content") + private String content; + + /** + * Get the JSON title. + * + * @return the title value + */ + public String title() { + return this.title; + } + + /** + * Set the JSON title. + * + * @param title the title value to set + * @return the JsonSchemaInner object itself. + */ + public JsonSchemaInner withTitle(String title) { + this.title = title; + return this; + } + + /** + * Get the JSON content. + * + * @return the content value + */ + public String content() { + return this.content; + } + + /** + * Set the JSON content. + * + * @param content the content value to set + * @return the JsonSchemaInner object itself. + */ + public JsonSchemaInner withContent(String content) { + this.content = content; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/KeyVaultKeyImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/KeyVaultKeyImpl.java new file mode 100644 index 000000000000..dd9ad81d6ad4 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/KeyVaultKeyImpl.java @@ -0,0 +1,37 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.KeyVaultKey; +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.KeyVaultKeyAttributes; + +class KeyVaultKeyImpl extends WrapperImpl implements KeyVaultKey { + private final LogicManager manager; + KeyVaultKeyImpl(KeyVaultKeyInner inner, LogicManager manager) { + super(inner); + this.manager = manager; + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public KeyVaultKeyAttributes attributes() { + return this.inner().attributes(); + } + + @Override + public String kid() { + return this.inner().kid(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/KeyVaultKeyInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/KeyVaultKeyInner.java new file mode 100644 index 000000000000..088d2e5c3807 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/KeyVaultKeyInner.java @@ -0,0 +1,70 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.KeyVaultKeyAttributes; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The key vault key. + */ +public class KeyVaultKeyInner { + /** + * The key id. + */ + @JsonProperty(value = "kid") + private String kid; + + /** + * The key attributes. + */ + @JsonProperty(value = "attributes") + private KeyVaultKeyAttributes attributes; + + /** + * Get the key id. + * + * @return the kid value + */ + public String kid() { + return this.kid; + } + + /** + * Set the key id. + * + * @param kid the kid value to set + * @return the KeyVaultKeyInner object itself. + */ + public KeyVaultKeyInner withKid(String kid) { + this.kid = kid; + return this; + } + + /** + * Get the key attributes. + * + * @return the attributes value + */ + public KeyVaultKeyAttributes attributes() { + return this.attributes; + } + + /** + * Set the key attributes. + * + * @param attributes the attributes value to set + * @return the KeyVaultKeyInner object itself. + */ + public KeyVaultKeyInner withAttributes(KeyVaultKeyAttributes attributes) { + this.attributes = attributes; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/LogicManagementClientImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/LogicManagementClientImpl.java new file mode 100644 index 000000000000..fd31de72a23a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/LogicManagementClientImpl.java @@ -0,0 +1,560 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.AzureClient; +import com.microsoft.azure.AzureServiceClient; +import com.microsoft.rest.credentials.ServiceClientCredentials; +import com.microsoft.rest.RestClient; + +/** + * Initializes a new instance of the LogicManagementClientImpl class. + */ +public class LogicManagementClientImpl extends AzureServiceClient { + /** the {@link AzureClient} used for long running operations. */ + private AzureClient azureClient; + + /** + * Gets the {@link AzureClient} used for long running operations. + * @return the azure client; + */ + public AzureClient getAzureClient() { + return this.azureClient; + } + + /** The subscription id. */ + private String subscriptionId; + + /** + * Gets The subscription id. + * + * @return the subscriptionId value. + */ + public String subscriptionId() { + return this.subscriptionId; + } + + /** + * Sets The subscription id. + * + * @param subscriptionId the subscriptionId value. + * @return the service client itself + */ + public LogicManagementClientImpl withSubscriptionId(String subscriptionId) { + this.subscriptionId = subscriptionId; + return this; + } + + /** The API version. */ + private String apiVersion; + + /** + * Gets The API version. + * + * @return the apiVersion value. + */ + public String apiVersion() { + return this.apiVersion; + } + + /** The preferred language for the response. */ + private String acceptLanguage; + + /** + * Gets The preferred language for the response. + * + * @return the acceptLanguage value. + */ + public String acceptLanguage() { + return this.acceptLanguage; + } + + /** + * Sets The preferred language for the response. + * + * @param acceptLanguage the acceptLanguage value. + * @return the service client itself + */ + public LogicManagementClientImpl withAcceptLanguage(String acceptLanguage) { + this.acceptLanguage = acceptLanguage; + return this; + } + + /** The retry timeout in seconds for Long Running Operations. Default value is 30. */ + private int longRunningOperationRetryTimeout; + + /** + * Gets The retry timeout in seconds for Long Running Operations. Default value is 30. + * + * @return the longRunningOperationRetryTimeout value. + */ + public int longRunningOperationRetryTimeout() { + return this.longRunningOperationRetryTimeout; + } + + /** + * Sets The retry timeout in seconds for Long Running Operations. Default value is 30. + * + * @param longRunningOperationRetryTimeout the longRunningOperationRetryTimeout value. + * @return the service client itself + */ + public LogicManagementClientImpl withLongRunningOperationRetryTimeout(int longRunningOperationRetryTimeout) { + this.longRunningOperationRetryTimeout = longRunningOperationRetryTimeout; + return this; + } + + /** Whether a unique x-ms-client-request-id should be generated. When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true. */ + private boolean generateClientRequestId; + + /** + * Gets Whether a unique x-ms-client-request-id should be generated. When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true. + * + * @return the generateClientRequestId value. + */ + public boolean generateClientRequestId() { + return this.generateClientRequestId; + } + + /** + * Sets Whether a unique x-ms-client-request-id should be generated. When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true. + * + * @param generateClientRequestId the generateClientRequestId value. + * @return the service client itself + */ + public LogicManagementClientImpl withGenerateClientRequestId(boolean generateClientRequestId) { + this.generateClientRequestId = generateClientRequestId; + return this; + } + + /** + * The WorkflowsInner object to access its operations. + */ + private WorkflowsInner workflows; + + /** + * Gets the WorkflowsInner object to access its operations. + * @return the WorkflowsInner object. + */ + public WorkflowsInner workflows() { + return this.workflows; + } + + /** + * The WorkflowVersionsInner object to access its operations. + */ + private WorkflowVersionsInner workflowVersions; + + /** + * Gets the WorkflowVersionsInner object to access its operations. + * @return the WorkflowVersionsInner object. + */ + public WorkflowVersionsInner workflowVersions() { + return this.workflowVersions; + } + + /** + * The WorkflowTriggersInner object to access its operations. + */ + private WorkflowTriggersInner workflowTriggers; + + /** + * Gets the WorkflowTriggersInner object to access its operations. + * @return the WorkflowTriggersInner object. + */ + public WorkflowTriggersInner workflowTriggers() { + return this.workflowTriggers; + } + + /** + * The WorkflowVersionTriggersInner object to access its operations. + */ + private WorkflowVersionTriggersInner workflowVersionTriggers; + + /** + * Gets the WorkflowVersionTriggersInner object to access its operations. + * @return the WorkflowVersionTriggersInner object. + */ + public WorkflowVersionTriggersInner workflowVersionTriggers() { + return this.workflowVersionTriggers; + } + + /** + * The WorkflowTriggerHistoriesInner object to access its operations. + */ + private WorkflowTriggerHistoriesInner workflowTriggerHistories; + + /** + * Gets the WorkflowTriggerHistoriesInner object to access its operations. + * @return the WorkflowTriggerHistoriesInner object. + */ + public WorkflowTriggerHistoriesInner workflowTriggerHistories() { + return this.workflowTriggerHistories; + } + + /** + * The WorkflowRunsInner object to access its operations. + */ + private WorkflowRunsInner workflowRuns; + + /** + * Gets the WorkflowRunsInner object to access its operations. + * @return the WorkflowRunsInner object. + */ + public WorkflowRunsInner workflowRuns() { + return this.workflowRuns; + } + + /** + * The WorkflowRunActionsInner object to access its operations. + */ + private WorkflowRunActionsInner workflowRunActions; + + /** + * Gets the WorkflowRunActionsInner object to access its operations. + * @return the WorkflowRunActionsInner object. + */ + public WorkflowRunActionsInner workflowRunActions() { + return this.workflowRunActions; + } + + /** + * The WorkflowRunActionRepetitionsInner object to access its operations. + */ + private WorkflowRunActionRepetitionsInner workflowRunActionRepetitions; + + /** + * Gets the WorkflowRunActionRepetitionsInner object to access its operations. + * @return the WorkflowRunActionRepetitionsInner object. + */ + public WorkflowRunActionRepetitionsInner workflowRunActionRepetitions() { + return this.workflowRunActionRepetitions; + } + + /** + * The WorkflowRunActionRepetitionsRequestHistoriesInner object to access its operations. + */ + private WorkflowRunActionRepetitionsRequestHistoriesInner workflowRunActionRepetitionsRequestHistories; + + /** + * Gets the WorkflowRunActionRepetitionsRequestHistoriesInner object to access its operations. + * @return the WorkflowRunActionRepetitionsRequestHistoriesInner object. + */ + public WorkflowRunActionRepetitionsRequestHistoriesInner workflowRunActionRepetitionsRequestHistories() { + return this.workflowRunActionRepetitionsRequestHistories; + } + + /** + * The WorkflowRunActionRequestHistoriesInner object to access its operations. + */ + private WorkflowRunActionRequestHistoriesInner workflowRunActionRequestHistories; + + /** + * Gets the WorkflowRunActionRequestHistoriesInner object to access its operations. + * @return the WorkflowRunActionRequestHistoriesInner object. + */ + public WorkflowRunActionRequestHistoriesInner workflowRunActionRequestHistories() { + return this.workflowRunActionRequestHistories; + } + + /** + * The WorkflowRunActionScopeRepetitionsInner object to access its operations. + */ + private WorkflowRunActionScopeRepetitionsInner workflowRunActionScopeRepetitions; + + /** + * Gets the WorkflowRunActionScopeRepetitionsInner object to access its operations. + * @return the WorkflowRunActionScopeRepetitionsInner object. + */ + public WorkflowRunActionScopeRepetitionsInner workflowRunActionScopeRepetitions() { + return this.workflowRunActionScopeRepetitions; + } + + /** + * The WorkflowRunOperationsInner object to access its operations. + */ + private WorkflowRunOperationsInner workflowRunOperations; + + /** + * Gets the WorkflowRunOperationsInner object to access its operations. + * @return the WorkflowRunOperationsInner object. + */ + public WorkflowRunOperationsInner workflowRunOperations() { + return this.workflowRunOperations; + } + + /** + * The IntegrationAccountsInner object to access its operations. + */ + private IntegrationAccountsInner integrationAccounts; + + /** + * Gets the IntegrationAccountsInner object to access its operations. + * @return the IntegrationAccountsInner object. + */ + public IntegrationAccountsInner integrationAccounts() { + return this.integrationAccounts; + } + + /** + * The IntegrationAccountAssembliesInner object to access its operations. + */ + private IntegrationAccountAssembliesInner integrationAccountAssemblies; + + /** + * Gets the IntegrationAccountAssembliesInner object to access its operations. + * @return the IntegrationAccountAssembliesInner object. + */ + public IntegrationAccountAssembliesInner integrationAccountAssemblies() { + return this.integrationAccountAssemblies; + } + + /** + * The IntegrationAccountBatchConfigurationsInner object to access its operations. + */ + private IntegrationAccountBatchConfigurationsInner integrationAccountBatchConfigurations; + + /** + * Gets the IntegrationAccountBatchConfigurationsInner object to access its operations. + * @return the IntegrationAccountBatchConfigurationsInner object. + */ + public IntegrationAccountBatchConfigurationsInner integrationAccountBatchConfigurations() { + return this.integrationAccountBatchConfigurations; + } + + /** + * The IntegrationAccountSchemasInner object to access its operations. + */ + private IntegrationAccountSchemasInner integrationAccountSchemas; + + /** + * Gets the IntegrationAccountSchemasInner object to access its operations. + * @return the IntegrationAccountSchemasInner object. + */ + public IntegrationAccountSchemasInner integrationAccountSchemas() { + return this.integrationAccountSchemas; + } + + /** + * The IntegrationAccountMapsInner object to access its operations. + */ + private IntegrationAccountMapsInner integrationAccountMaps; + + /** + * Gets the IntegrationAccountMapsInner object to access its operations. + * @return the IntegrationAccountMapsInner object. + */ + public IntegrationAccountMapsInner integrationAccountMaps() { + return this.integrationAccountMaps; + } + + /** + * The IntegrationAccountPartnersInner object to access its operations. + */ + private IntegrationAccountPartnersInner integrationAccountPartners; + + /** + * Gets the IntegrationAccountPartnersInner object to access its operations. + * @return the IntegrationAccountPartnersInner object. + */ + public IntegrationAccountPartnersInner integrationAccountPartners() { + return this.integrationAccountPartners; + } + + /** + * The IntegrationAccountAgreementsInner object to access its operations. + */ + private IntegrationAccountAgreementsInner integrationAccountAgreements; + + /** + * Gets the IntegrationAccountAgreementsInner object to access its operations. + * @return the IntegrationAccountAgreementsInner object. + */ + public IntegrationAccountAgreementsInner integrationAccountAgreements() { + return this.integrationAccountAgreements; + } + + /** + * The IntegrationAccountCertificatesInner object to access its operations. + */ + private IntegrationAccountCertificatesInner integrationAccountCertificates; + + /** + * Gets the IntegrationAccountCertificatesInner object to access its operations. + * @return the IntegrationAccountCertificatesInner object. + */ + public IntegrationAccountCertificatesInner integrationAccountCertificates() { + return this.integrationAccountCertificates; + } + + /** + * The IntegrationAccountSessionsInner object to access its operations. + */ + private IntegrationAccountSessionsInner integrationAccountSessions; + + /** + * Gets the IntegrationAccountSessionsInner object to access its operations. + * @return the IntegrationAccountSessionsInner object. + */ + public IntegrationAccountSessionsInner integrationAccountSessions() { + return this.integrationAccountSessions; + } + + /** + * The IntegrationServiceEnvironmentsInner object to access its operations. + */ + private IntegrationServiceEnvironmentsInner integrationServiceEnvironments; + + /** + * Gets the IntegrationServiceEnvironmentsInner object to access its operations. + * @return the IntegrationServiceEnvironmentsInner object. + */ + public IntegrationServiceEnvironmentsInner integrationServiceEnvironments() { + return this.integrationServiceEnvironments; + } + + /** + * The IntegrationServiceEnvironmentSkusInner object to access its operations. + */ + private IntegrationServiceEnvironmentSkusInner integrationServiceEnvironmentSkus; + + /** + * Gets the IntegrationServiceEnvironmentSkusInner object to access its operations. + * @return the IntegrationServiceEnvironmentSkusInner object. + */ + public IntegrationServiceEnvironmentSkusInner integrationServiceEnvironmentSkus() { + return this.integrationServiceEnvironmentSkus; + } + + /** + * The IntegrationServiceEnvironmentNetworkHealthsInner object to access its operations. + */ + private IntegrationServiceEnvironmentNetworkHealthsInner integrationServiceEnvironmentNetworkHealths; + + /** + * Gets the IntegrationServiceEnvironmentNetworkHealthsInner object to access its operations. + * @return the IntegrationServiceEnvironmentNetworkHealthsInner object. + */ + public IntegrationServiceEnvironmentNetworkHealthsInner integrationServiceEnvironmentNetworkHealths() { + return this.integrationServiceEnvironmentNetworkHealths; + } + + /** + * The IntegrationServiceEnvironmentManagedApisInner object to access its operations. + */ + private IntegrationServiceEnvironmentManagedApisInner integrationServiceEnvironmentManagedApis; + + /** + * Gets the IntegrationServiceEnvironmentManagedApisInner object to access its operations. + * @return the IntegrationServiceEnvironmentManagedApisInner object. + */ + public IntegrationServiceEnvironmentManagedApisInner integrationServiceEnvironmentManagedApis() { + return this.integrationServiceEnvironmentManagedApis; + } + + /** + * The IntegrationServiceEnvironmentManagedApiOperationsInner object to access its operations. + */ + private IntegrationServiceEnvironmentManagedApiOperationsInner integrationServiceEnvironmentManagedApiOperations; + + /** + * Gets the IntegrationServiceEnvironmentManagedApiOperationsInner object to access its operations. + * @return the IntegrationServiceEnvironmentManagedApiOperationsInner object. + */ + public IntegrationServiceEnvironmentManagedApiOperationsInner integrationServiceEnvironmentManagedApiOperations() { + return this.integrationServiceEnvironmentManagedApiOperations; + } + + /** + * The OperationsInner object to access its operations. + */ + private OperationsInner operations; + + /** + * Gets the OperationsInner object to access its operations. + * @return the OperationsInner object. + */ + public OperationsInner operations() { + return this.operations; + } + + /** + * Initializes an instance of LogicManagementClient client. + * + * @param credentials the management credentials for Azure + */ + public LogicManagementClientImpl(ServiceClientCredentials credentials) { + this("https://management.azure.com", credentials); + } + + /** + * Initializes an instance of LogicManagementClient client. + * + * @param baseUrl the base URL of the host + * @param credentials the management credentials for Azure + */ + public LogicManagementClientImpl(String baseUrl, ServiceClientCredentials credentials) { + super(baseUrl, credentials); + initialize(); + } + + /** + * Initializes an instance of LogicManagementClient client. + * + * @param restClient the REST client to connect to Azure. + */ + public LogicManagementClientImpl(RestClient restClient) { + super(restClient); + initialize(); + } + + protected void initialize() { + this.apiVersion = "2019-05-01"; + this.acceptLanguage = "en-US"; + this.longRunningOperationRetryTimeout = 30; + this.generateClientRequestId = true; + this.workflows = new WorkflowsInner(restClient().retrofit(), this); + this.workflowVersions = new WorkflowVersionsInner(restClient().retrofit(), this); + this.workflowTriggers = new WorkflowTriggersInner(restClient().retrofit(), this); + this.workflowVersionTriggers = new WorkflowVersionTriggersInner(restClient().retrofit(), this); + this.workflowTriggerHistories = new WorkflowTriggerHistoriesInner(restClient().retrofit(), this); + this.workflowRuns = new WorkflowRunsInner(restClient().retrofit(), this); + this.workflowRunActions = new WorkflowRunActionsInner(restClient().retrofit(), this); + this.workflowRunActionRepetitions = new WorkflowRunActionRepetitionsInner(restClient().retrofit(), this); + this.workflowRunActionRepetitionsRequestHistories = new WorkflowRunActionRepetitionsRequestHistoriesInner(restClient().retrofit(), this); + this.workflowRunActionRequestHistories = new WorkflowRunActionRequestHistoriesInner(restClient().retrofit(), this); + this.workflowRunActionScopeRepetitions = new WorkflowRunActionScopeRepetitionsInner(restClient().retrofit(), this); + this.workflowRunOperations = new WorkflowRunOperationsInner(restClient().retrofit(), this); + this.integrationAccounts = new IntegrationAccountsInner(restClient().retrofit(), this); + this.integrationAccountAssemblies = new IntegrationAccountAssembliesInner(restClient().retrofit(), this); + this.integrationAccountBatchConfigurations = new IntegrationAccountBatchConfigurationsInner(restClient().retrofit(), this); + this.integrationAccountSchemas = new IntegrationAccountSchemasInner(restClient().retrofit(), this); + this.integrationAccountMaps = new IntegrationAccountMapsInner(restClient().retrofit(), this); + this.integrationAccountPartners = new IntegrationAccountPartnersInner(restClient().retrofit(), this); + this.integrationAccountAgreements = new IntegrationAccountAgreementsInner(restClient().retrofit(), this); + this.integrationAccountCertificates = new IntegrationAccountCertificatesInner(restClient().retrofit(), this); + this.integrationAccountSessions = new IntegrationAccountSessionsInner(restClient().retrofit(), this); + this.integrationServiceEnvironments = new IntegrationServiceEnvironmentsInner(restClient().retrofit(), this); + this.integrationServiceEnvironmentSkus = new IntegrationServiceEnvironmentSkusInner(restClient().retrofit(), this); + this.integrationServiceEnvironmentNetworkHealths = new IntegrationServiceEnvironmentNetworkHealthsInner(restClient().retrofit(), this); + this.integrationServiceEnvironmentManagedApis = new IntegrationServiceEnvironmentManagedApisInner(restClient().retrofit(), this); + this.integrationServiceEnvironmentManagedApiOperations = new IntegrationServiceEnvironmentManagedApiOperationsInner(restClient().retrofit(), this); + this.operations = new OperationsInner(restClient().retrofit(), this); + this.azureClient = new AzureClient(this); + } + + /** + * Gets the User-Agent header for the client. + * + * @return the user agent string. + */ + @Override + public String userAgent() { + return String.format("%s (%s, %s, auto-generated)", super.userAgent(), "LogicManagementClient", "2019-05-01"); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/LogicManager.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/LogicManager.java new file mode 100644 index 000000000000..ae642c1684a0 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/LogicManager.java @@ -0,0 +1,411 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.AzureEnvironment; +import com.microsoft.azure.AzureResponseBuilder; +import com.microsoft.azure.credentials.AzureTokenCredentials; +import com.microsoft.azure.management.apigeneration.Beta; +import com.microsoft.azure.management.apigeneration.Beta.SinceVersion; +import com.microsoft.azure.arm.resources.AzureConfigurable; +import com.microsoft.azure.serializer.AzureJacksonAdapter; +import com.microsoft.rest.RestClient; +import com.microsoft.azure.management.logic.v2019_05_01.Workflows; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowVersions; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggers; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowVersionTriggers; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerHistories; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRuns; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActions; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRepetitions; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRepetitionsRequestHistories; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRequestHistories; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionScopeRepetitions; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunOperations; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccounts; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAssemblies; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountBatchConfigurations; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSchemas; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountMaps; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountPartners; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountAgreements; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountCertificates; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationAccountSessions; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironments; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentSkus; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentNetworkHealths; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentManagedApis; +import com.microsoft.azure.management.logic.v2019_05_01.IntegrationServiceEnvironmentManagedApiOperations; +import com.microsoft.azure.management.logic.v2019_05_01.Operations; +import com.microsoft.azure.arm.resources.implementation.AzureConfigurableCoreImpl; +import com.microsoft.azure.arm.resources.implementation.ManagerCore; + +/** + * Entry point to Azure Logic resource management. + */ +public final class LogicManager extends ManagerCore { + private Workflows workflows; + private WorkflowVersions workflowVersions; + private WorkflowTriggers workflowTriggers; + private WorkflowVersionTriggers workflowVersionTriggers; + private WorkflowTriggerHistories workflowTriggerHistories; + private WorkflowRuns workflowRuns; + private WorkflowRunActions workflowRunActions; + private WorkflowRunActionRepetitions workflowRunActionRepetitions; + private WorkflowRunActionRepetitionsRequestHistories workflowRunActionRepetitionsRequestHistories; + private WorkflowRunActionRequestHistories workflowRunActionRequestHistories; + private WorkflowRunActionScopeRepetitions workflowRunActionScopeRepetitions; + private WorkflowRunOperations workflowRunOperations; + private IntegrationAccounts integrationAccounts; + private IntegrationAccountAssemblies integrationAccountAssemblies; + private IntegrationAccountBatchConfigurations integrationAccountBatchConfigurations; + private IntegrationAccountSchemas integrationAccountSchemas; + private IntegrationAccountMaps integrationAccountMaps; + private IntegrationAccountPartners integrationAccountPartners; + private IntegrationAccountAgreements integrationAccountAgreements; + private IntegrationAccountCertificates integrationAccountCertificates; + private IntegrationAccountSessions integrationAccountSessions; + private IntegrationServiceEnvironments integrationServiceEnvironments; + private IntegrationServiceEnvironmentSkus integrationServiceEnvironmentSkus; + private IntegrationServiceEnvironmentNetworkHealths integrationServiceEnvironmentNetworkHealths; + private IntegrationServiceEnvironmentManagedApis integrationServiceEnvironmentManagedApis; + private IntegrationServiceEnvironmentManagedApiOperations integrationServiceEnvironmentManagedApiOperations; + private Operations operations; + /** + * Get a Configurable instance that can be used to create LogicManager with optional configuration. + * + * @return the instance allowing configurations + */ + public static Configurable configure() { + return new LogicManager.ConfigurableImpl(); + } + /** + * Creates an instance of LogicManager that exposes Logic resource management API entry points. + * + * @param credentials the credentials to use + * @param subscriptionId the subscription UUID + * @return the LogicManager + */ + public static LogicManager authenticate(AzureTokenCredentials credentials, String subscriptionId) { + return new LogicManager(new RestClient.Builder() + .withBaseUrl(credentials.environment(), AzureEnvironment.Endpoint.RESOURCE_MANAGER) + .withCredentials(credentials) + .withSerializerAdapter(new AzureJacksonAdapter()) + .withResponseBuilderFactory(new AzureResponseBuilder.Factory()) + .build(), subscriptionId); + } + /** + * Creates an instance of LogicManager that exposes Logic resource management API entry points. + * + * @param restClient the RestClient to be used for API calls. + * @param subscriptionId the subscription UUID + * @return the LogicManager + */ + public static LogicManager authenticate(RestClient restClient, String subscriptionId) { + return new LogicManager(restClient, subscriptionId); + } + /** + * The interface allowing configurations to be set. + */ + public interface Configurable extends AzureConfigurable { + /** + * Creates an instance of LogicManager that exposes Logic management API entry points. + * + * @param credentials the credentials to use + * @param subscriptionId the subscription UUID + * @return the interface exposing Logic management API entry points that work across subscriptions + */ + LogicManager authenticate(AzureTokenCredentials credentials, String subscriptionId); + } + + /** + * @return Entry point to manage Workflows. + */ + public Workflows workflows() { + if (this.workflows == null) { + this.workflows = new WorkflowsImpl(this); + } + return this.workflows; + } + + /** + * @return Entry point to manage WorkflowVersions. + */ + public WorkflowVersions workflowVersions() { + if (this.workflowVersions == null) { + this.workflowVersions = new WorkflowVersionsImpl(this); + } + return this.workflowVersions; + } + + /** + * @return Entry point to manage WorkflowTriggers. + */ + public WorkflowTriggers workflowTriggers() { + if (this.workflowTriggers == null) { + this.workflowTriggers = new WorkflowTriggersImpl(this); + } + return this.workflowTriggers; + } + + /** + * @return Entry point to manage WorkflowVersionTriggers. + */ + public WorkflowVersionTriggers workflowVersionTriggers() { + if (this.workflowVersionTriggers == null) { + this.workflowVersionTriggers = new WorkflowVersionTriggersImpl(this); + } + return this.workflowVersionTriggers; + } + + /** + * @return Entry point to manage WorkflowTriggerHistories. + */ + public WorkflowTriggerHistories workflowTriggerHistories() { + if (this.workflowTriggerHistories == null) { + this.workflowTriggerHistories = new WorkflowTriggerHistoriesImpl(this); + } + return this.workflowTriggerHistories; + } + + /** + * @return Entry point to manage WorkflowRuns. + */ + public WorkflowRuns workflowRuns() { + if (this.workflowRuns == null) { + this.workflowRuns = new WorkflowRunsImpl(this); + } + return this.workflowRuns; + } + + /** + * @return Entry point to manage WorkflowRunActions. + */ + public WorkflowRunActions workflowRunActions() { + if (this.workflowRunActions == null) { + this.workflowRunActions = new WorkflowRunActionsImpl(this); + } + return this.workflowRunActions; + } + + /** + * @return Entry point to manage WorkflowRunActionRepetitions. + */ + public WorkflowRunActionRepetitions workflowRunActionRepetitions() { + if (this.workflowRunActionRepetitions == null) { + this.workflowRunActionRepetitions = new WorkflowRunActionRepetitionsImpl(this); + } + return this.workflowRunActionRepetitions; + } + + /** + * @return Entry point to manage WorkflowRunActionRepetitionsRequestHistories. + */ + public WorkflowRunActionRepetitionsRequestHistories workflowRunActionRepetitionsRequestHistories() { + if (this.workflowRunActionRepetitionsRequestHistories == null) { + this.workflowRunActionRepetitionsRequestHistories = new WorkflowRunActionRepetitionsRequestHistoriesImpl(this); + } + return this.workflowRunActionRepetitionsRequestHistories; + } + + /** + * @return Entry point to manage WorkflowRunActionRequestHistories. + */ + public WorkflowRunActionRequestHistories workflowRunActionRequestHistories() { + if (this.workflowRunActionRequestHistories == null) { + this.workflowRunActionRequestHistories = new WorkflowRunActionRequestHistoriesImpl(this); + } + return this.workflowRunActionRequestHistories; + } + + /** + * @return Entry point to manage WorkflowRunActionScopeRepetitions. + */ + public WorkflowRunActionScopeRepetitions workflowRunActionScopeRepetitions() { + if (this.workflowRunActionScopeRepetitions == null) { + this.workflowRunActionScopeRepetitions = new WorkflowRunActionScopeRepetitionsImpl(this); + } + return this.workflowRunActionScopeRepetitions; + } + + /** + * @return Entry point to manage WorkflowRunOperations. + */ + public WorkflowRunOperations workflowRunOperations() { + if (this.workflowRunOperations == null) { + this.workflowRunOperations = new WorkflowRunOperationsImpl(this); + } + return this.workflowRunOperations; + } + + /** + * @return Entry point to manage IntegrationAccounts. + */ + public IntegrationAccounts integrationAccounts() { + if (this.integrationAccounts == null) { + this.integrationAccounts = new IntegrationAccountsImpl(this); + } + return this.integrationAccounts; + } + + /** + * @return Entry point to manage IntegrationAccountAssemblies. + */ + public IntegrationAccountAssemblies integrationAccountAssemblies() { + if (this.integrationAccountAssemblies == null) { + this.integrationAccountAssemblies = new IntegrationAccountAssembliesImpl(this); + } + return this.integrationAccountAssemblies; + } + + /** + * @return Entry point to manage IntegrationAccountBatchConfigurations. + */ + public IntegrationAccountBatchConfigurations integrationAccountBatchConfigurations() { + if (this.integrationAccountBatchConfigurations == null) { + this.integrationAccountBatchConfigurations = new IntegrationAccountBatchConfigurationsImpl(this); + } + return this.integrationAccountBatchConfigurations; + } + + /** + * @return Entry point to manage IntegrationAccountSchemas. + */ + public IntegrationAccountSchemas integrationAccountSchemas() { + if (this.integrationAccountSchemas == null) { + this.integrationAccountSchemas = new IntegrationAccountSchemasImpl(this); + } + return this.integrationAccountSchemas; + } + + /** + * @return Entry point to manage IntegrationAccountMaps. + */ + public IntegrationAccountMaps integrationAccountMaps() { + if (this.integrationAccountMaps == null) { + this.integrationAccountMaps = new IntegrationAccountMapsImpl(this); + } + return this.integrationAccountMaps; + } + + /** + * @return Entry point to manage IntegrationAccountPartners. + */ + public IntegrationAccountPartners integrationAccountPartners() { + if (this.integrationAccountPartners == null) { + this.integrationAccountPartners = new IntegrationAccountPartnersImpl(this); + } + return this.integrationAccountPartners; + } + + /** + * @return Entry point to manage IntegrationAccountAgreements. + */ + public IntegrationAccountAgreements integrationAccountAgreements() { + if (this.integrationAccountAgreements == null) { + this.integrationAccountAgreements = new IntegrationAccountAgreementsImpl(this); + } + return this.integrationAccountAgreements; + } + + /** + * @return Entry point to manage IntegrationAccountCertificates. + */ + public IntegrationAccountCertificates integrationAccountCertificates() { + if (this.integrationAccountCertificates == null) { + this.integrationAccountCertificates = new IntegrationAccountCertificatesImpl(this); + } + return this.integrationAccountCertificates; + } + + /** + * @return Entry point to manage IntegrationAccountSessions. + */ + public IntegrationAccountSessions integrationAccountSessions() { + if (this.integrationAccountSessions == null) { + this.integrationAccountSessions = new IntegrationAccountSessionsImpl(this); + } + return this.integrationAccountSessions; + } + + /** + * @return Entry point to manage IntegrationServiceEnvironments. + */ + public IntegrationServiceEnvironments integrationServiceEnvironments() { + if (this.integrationServiceEnvironments == null) { + this.integrationServiceEnvironments = new IntegrationServiceEnvironmentsImpl(this); + } + return this.integrationServiceEnvironments; + } + + /** + * @return Entry point to manage IntegrationServiceEnvironmentSkus. + */ + public IntegrationServiceEnvironmentSkus integrationServiceEnvironmentSkus() { + if (this.integrationServiceEnvironmentSkus == null) { + this.integrationServiceEnvironmentSkus = new IntegrationServiceEnvironmentSkusImpl(this); + } + return this.integrationServiceEnvironmentSkus; + } + + /** + * @return Entry point to manage IntegrationServiceEnvironmentNetworkHealths. + */ + public IntegrationServiceEnvironmentNetworkHealths integrationServiceEnvironmentNetworkHealths() { + if (this.integrationServiceEnvironmentNetworkHealths == null) { + this.integrationServiceEnvironmentNetworkHealths = new IntegrationServiceEnvironmentNetworkHealthsImpl(this); + } + return this.integrationServiceEnvironmentNetworkHealths; + } + + /** + * @return Entry point to manage IntegrationServiceEnvironmentManagedApis. + */ + public IntegrationServiceEnvironmentManagedApis integrationServiceEnvironmentManagedApis() { + if (this.integrationServiceEnvironmentManagedApis == null) { + this.integrationServiceEnvironmentManagedApis = new IntegrationServiceEnvironmentManagedApisImpl(this); + } + return this.integrationServiceEnvironmentManagedApis; + } + + /** + * @return Entry point to manage IntegrationServiceEnvironmentManagedApiOperations. + */ + public IntegrationServiceEnvironmentManagedApiOperations integrationServiceEnvironmentManagedApiOperations() { + if (this.integrationServiceEnvironmentManagedApiOperations == null) { + this.integrationServiceEnvironmentManagedApiOperations = new IntegrationServiceEnvironmentManagedApiOperationsImpl(this); + } + return this.integrationServiceEnvironmentManagedApiOperations; + } + + /** + * @return Entry point to manage Operations. + */ + public Operations operations() { + if (this.operations == null) { + this.operations = new OperationsImpl(this); + } + return this.operations; + } + + /** + * The implementation for Configurable interface. + */ + private static final class ConfigurableImpl extends AzureConfigurableCoreImpl implements Configurable { + public LogicManager authenticate(AzureTokenCredentials credentials, String subscriptionId) { + return LogicManager.authenticate(buildRestClient(credentials), subscriptionId); + } + } + private LogicManager(RestClient restClient, String subscriptionId) { + super( + restClient, + subscriptionId, + new LogicManagementClientImpl(restClient).withSubscriptionId(subscriptionId)); + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ManagedApiImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ManagedApiImpl.java new file mode 100644 index 000000000000..778046c1f7e6 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ManagedApiImpl.java @@ -0,0 +1,111 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.ManagedApi; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.ApiResourceProperties; +import java.util.Map; + +class ManagedApiImpl extends CreatableUpdatableImpl implements ManagedApi, ManagedApi.Definition, ManagedApi.Update { + private final LogicManager manager; + private String resourceGroup; + private String integrationServiceEnvironmentName; + private String apiName; + + ManagedApiImpl(String name, LogicManager manager) { + super(name, new ManagedApiInner()); + this.manager = manager; + // Set resource name + this.apiName = name; + // + } + + ManagedApiImpl(ManagedApiInner inner, LogicManager manager) { + super(inner.name(), inner); + this.manager = manager; + // Set resource name + this.apiName = inner.name(); + // set resource ancestor and positional variables + this.resourceGroup = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.integrationServiceEnvironmentName = IdParsingUtils.getValueFromIdByName(inner.id(), "integrationServiceEnvironments"); + this.apiName = IdParsingUtils.getValueFromIdByName(inner.id(), "managedApis"); + // + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public Observable createResourceAsync() { + IntegrationServiceEnvironmentManagedApisInner client = this.manager().inner().integrationServiceEnvironmentManagedApis(); + return client.putAsync(this.resourceGroup, this.integrationServiceEnvironmentName, this.apiName) + .map(innerToFluentMap(this)); + } + + @Override + public Observable updateResourceAsync() { + IntegrationServiceEnvironmentManagedApisInner client = this.manager().inner().integrationServiceEnvironmentManagedApis(); + return client.putAsync(this.resourceGroup, this.integrationServiceEnvironmentName, this.apiName) + .map(innerToFluentMap(this)); + } + + @Override + protected Observable getInnerAsync() { + IntegrationServiceEnvironmentManagedApisInner client = this.manager().inner().integrationServiceEnvironmentManagedApis(); + return client.getAsync(this.resourceGroup, this.integrationServiceEnvironmentName, this.apiName); + } + + @Override + public boolean isInCreateMode() { + return this.inner().id() == null; + } + + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public ApiResourceProperties properties() { + return this.inner().properties(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public String type() { + return this.inner().type(); + } + + @Override + public ManagedApiImpl withExistingIntegrationServiceEnvironment(String resourceGroup, String integrationServiceEnvironmentName) { + this.resourceGroup = resourceGroup; + this.integrationServiceEnvironmentName = integrationServiceEnvironmentName; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ManagedApiInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ManagedApiInner.java new file mode 100644 index 000000000000..528f102857da --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/ManagedApiInner.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.ApiResourceProperties; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The managed api definition. + */ +@SkipParentValidation +public class ManagedApiInner extends Resource { + /** + * The api resource properties. + */ + @JsonProperty(value = "properties") + private ApiResourceProperties properties; + + /** + * Get the api resource properties. + * + * @return the properties value + */ + public ApiResourceProperties properties() { + return this.properties; + } + + /** + * Set the api resource properties. + * + * @param properties the properties value to set + * @return the ManagedApiInner object itself. + */ + public ManagedApiInner withProperties(ApiResourceProperties properties) { + this.properties = properties; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/OperationImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/OperationImpl.java new file mode 100644 index 000000000000..f83f24ae1468 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/OperationImpl.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.Operation; +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.OperationDisplay; + +class OperationImpl extends WrapperImpl implements Operation { + private final LogicManager manager; + OperationImpl(OperationInner inner, LogicManager manager) { + super(inner); + this.manager = manager; + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public OperationDisplay display() { + return this.inner().display(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public String origin() { + return this.inner().origin(); + } + + @Override + public Object properties() { + return this.inner().properties(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/OperationInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/OperationInner.java new file mode 100644 index 000000000000..cbe9c2b4b40d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/OperationInner.java @@ -0,0 +1,122 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.OperationDisplay; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Logic REST API operation. + */ +public class OperationInner { + /** + * Operation: origin. + */ + @JsonProperty(value = "origin") + private String origin; + + /** + * Operation name: {provider}/{resource}/{operation}. + */ + @JsonProperty(value = "name") + private String name; + + /** + * The object that represents the operation. + */ + @JsonProperty(value = "display") + private OperationDisplay display; + + /** + * The properties. + */ + @JsonProperty(value = "properties") + private Object properties; + + /** + * Get operation: origin. + * + * @return the origin value + */ + public String origin() { + return this.origin; + } + + /** + * Set operation: origin. + * + * @param origin the origin value to set + * @return the OperationInner object itself. + */ + public OperationInner withOrigin(String origin) { + this.origin = origin; + return this; + } + + /** + * Get operation name: {provider}/{resource}/{operation}. + * + * @return the name value + */ + public String name() { + return this.name; + } + + /** + * Set operation name: {provider}/{resource}/{operation}. + * + * @param name the name value to set + * @return the OperationInner object itself. + */ + public OperationInner withName(String name) { + this.name = name; + return this; + } + + /** + * Get the object that represents the operation. + * + * @return the display value + */ + public OperationDisplay display() { + return this.display; + } + + /** + * Set the object that represents the operation. + * + * @param display the display value to set + * @return the OperationInner object itself. + */ + public OperationInner withDisplay(OperationDisplay display) { + this.display = display; + return this; + } + + /** + * Get the properties. + * + * @return the properties value + */ + public Object properties() { + return this.properties; + } + + /** + * Set the properties. + * + * @param properties the properties value to set + * @return the OperationInner object itself. + */ + public OperationInner withProperties(Object properties) { + this.properties = properties; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/OperationsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/OperationsImpl.java new file mode 100644 index 000000000000..7ca3269d8dbc --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/OperationsImpl.java @@ -0,0 +1,49 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * abc + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.Operations; +import rx.functions.Func1; +import rx.Observable; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.Operation; + +class OperationsImpl extends WrapperImpl implements Operations { + private final LogicManager manager; + + OperationsImpl(LogicManager manager) { + super(manager.inner().operations()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + @Override + public Observable listAsync() { + OperationsInner client = this.inner(); + return client.listAsync() + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public Operation call(OperationInner inner) { + return new OperationImpl(inner, manager()); + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/OperationsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/OperationsInner.java new file mode 100644 index 000000000000..3ae6d1a02de8 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/OperationsInner.java @@ -0,0 +1,283 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in Operations. + */ +public class OperationsInner { + /** The Retrofit service to perform REST calls. */ + private OperationsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of OperationsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public OperationsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(OperationsService.class); + this.client = client; + } + + /** + * The interface defining all the services for Operations to be + * used by Retrofit to perform actually REST calls. + */ + interface OperationsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Operations list" }) + @GET("providers/Microsoft.Logic/operations") + Observable> list(@Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Operations listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Lists all of the available Logic REST API operations. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<OperationInner> object if successful. + */ + public PagedList list() { + ServiceResponse> response = listSinglePageAsync().toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Lists all of the available Logic REST API operations. + * + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Lists all of the available Logic REST API operations. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<OperationInner> object + */ + public Observable> listAsync() { + return listWithServiceResponseAsync() + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Lists all of the available Logic REST API operations. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<OperationInner> object + */ + public Observable>> listWithServiceResponseAsync() { + return listSinglePageAsync() + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Lists all of the available Logic REST API operations. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<OperationInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync() { + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Lists all of the available Logic REST API operations. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<OperationInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Lists all of the available Logic REST API operations. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Lists all of the available Logic REST API operations. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<OperationInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Lists all of the available Logic REST API operations. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<OperationInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Lists all of the available Logic REST API operations. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<OperationInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/PageImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/PageImpl.java new file mode 100644 index 000000000000..e62b12a56d3d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/PageImpl.java @@ -0,0 +1,75 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.azure.Page; +import java.util.List; + +/** + * An instance of this class defines a page of Azure resources and a link to + * get the next page of resources, if any. + * + * @param type of Azure resource + */ +public class PageImpl implements Page { + /** + * The link to the next page. + */ + @JsonProperty("nextLink") + private String nextPageLink; + + /** + * The list of items. + */ + @JsonProperty("value") + private List items; + + /** + * Gets the link to the next page. + * + * @return the link to the next page. + */ + @Override + public String nextPageLink() { + return this.nextPageLink; + } + + /** + * Gets the list of items. + * + * @return the list of items in {@link List}. + */ + @Override + public List items() { + return items; + } + + /** + * Sets the link to the next page. + * + * @param nextPageLink the link to the next page. + * @return this Page object itself. + */ + public PageImpl setNextPageLink(String nextPageLink) { + this.nextPageLink = nextPageLink; + return this; + } + + /** + * Sets the list of items. + * + * @param items the list of items in {@link List}. + * @return this Page object itself. + */ + public PageImpl setItems(List items) { + this.items = items; + return this; + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/PageImpl1.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/PageImpl1.java new file mode 100644 index 000000000000..7c28909143f6 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/PageImpl1.java @@ -0,0 +1,75 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.azure.Page; +import java.util.List; + +/** + * An instance of this class defines a page of Azure resources and a link to + * get the next page of resources, if any. + * + * @param type of Azure resource + */ +public class PageImpl1 implements Page { + /** + * The link to the next page. + */ + @JsonProperty("") + private String nextPageLink; + + /** + * The list of items. + */ + @JsonProperty("inputs") + private List items; + + /** + * Gets the link to the next page. + * + * @return the link to the next page. + */ + @Override + public String nextPageLink() { + return this.nextPageLink; + } + + /** + * Gets the list of items. + * + * @return the list of items in {@link List}. + */ + @Override + public List items() { + return items; + } + + /** + * Sets the link to the next page. + * + * @param nextPageLink the link to the next page. + * @return this Page object itself. + */ + public PageImpl1 setNextPageLink(String nextPageLink) { + this.nextPageLink = nextPageLink; + return this; + } + + /** + * Sets the list of items. + * + * @param items the list of items in {@link List}. + * @return this Page object itself. + */ + public PageImpl1 setItems(List items) { + this.items = items; + return this; + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/PageImpl2.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/PageImpl2.java new file mode 100644 index 000000000000..523810e24848 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/PageImpl2.java @@ -0,0 +1,75 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.azure.Page; +import java.util.List; + +/** + * An instance of this class defines a page of Azure resources and a link to + * get the next page of resources, if any. + * + * @param type of Azure resource + */ +public class PageImpl2 implements Page { + /** + * The link to the next page. + */ + @JsonProperty("") + private String nextPageLink; + + /** + * The list of items. + */ + @JsonProperty("value") + private List items; + + /** + * Gets the link to the next page. + * + * @return the link to the next page. + */ + @Override + public String nextPageLink() { + return this.nextPageLink; + } + + /** + * Gets the list of items. + * + * @return the list of items in {@link List}. + */ + @Override + public List items() { + return items; + } + + /** + * Sets the link to the next page. + * + * @param nextPageLink the link to the next page. + * @return this Page object itself. + */ + public PageImpl2 setNextPageLink(String nextPageLink) { + this.nextPageLink = nextPageLink; + return this; + } + + /** + * Sets the list of items. + * + * @param items the list of items in {@link List}. + * @return this Page object itself. + */ + public PageImpl2 setItems(List items) { + this.items = items; + return this; + } +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/RepetitionActionRunWorkflowRequestHistoryImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/RepetitionActionRunWorkflowRequestHistoryImpl.java new file mode 100644 index 000000000000..766c5a6bb63f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/RepetitionActionRunWorkflowRequestHistoryImpl.java @@ -0,0 +1,81 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.RepetitionActionRunWorkflowRequestHistory; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.RequestHistoryProperties; +import java.util.Map; + +class RepetitionActionRunWorkflowRequestHistoryImpl extends IndexableRefreshableWrapperImpl implements RepetitionActionRunWorkflowRequestHistory { + private final LogicManager manager; + private String resourceGroupName; + private String workflowName; + private String runName; + private String actionName; + private String repetitionName; + private String requestHistoryName; + + RepetitionActionRunWorkflowRequestHistoryImpl(RequestHistoryInner inner, LogicManager manager) { + super(null, inner); + this.manager = manager; + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.workflowName = IdParsingUtils.getValueFromIdByName(inner.id(), "workflows"); + this.runName = IdParsingUtils.getValueFromIdByName(inner.id(), "runs"); + this.actionName = IdParsingUtils.getValueFromIdByName(inner.id(), "actions"); + this.repetitionName = IdParsingUtils.getValueFromIdByName(inner.id(), "repetitions"); + this.requestHistoryName = IdParsingUtils.getValueFromIdByName(inner.id(), "requestHistories"); + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + protected Observable getInnerAsync() { + WorkflowRunActionRepetitionsRequestHistoriesInner client = this.manager().inner().workflowRunActionRepetitionsRequestHistories(); + return client.getAsync(this.resourceGroupName, this.workflowName, this.runName, this.actionName, this.repetitionName, this.requestHistoryName); + } + + + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public RequestHistoryProperties properties() { + return this.inner().properties(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public String type() { + return this.inner().type(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/RequestHistoryInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/RequestHistoryInner.java new file mode 100644 index 000000000000..3b269e8df49b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/RequestHistoryInner.java @@ -0,0 +1,47 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.RequestHistoryProperties; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The request history. + */ +@SkipParentValidation +public class RequestHistoryInner extends Resource { + /** + * The request history properties. + */ + @JsonProperty(value = "properties") + private RequestHistoryProperties properties; + + /** + * Get the request history properties. + * + * @return the properties value + */ + public RequestHistoryProperties properties() { + return this.properties; + } + + /** + * Set the request history properties. + * + * @param properties the properties value to set + * @return the RequestHistoryInner object itself. + */ + public RequestHistoryInner withProperties(RequestHistoryProperties properties) { + this.properties = properties; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/RunWorkflowWorkflowRunImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/RunWorkflowWorkflowRunImpl.java new file mode 100644 index 000000000000..5b250173759b --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/RunWorkflowWorkflowRunImpl.java @@ -0,0 +1,127 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.RunWorkflowWorkflowRun; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.Correlation; +import org.joda.time.DateTime; +import java.util.Map; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowOutputParameter; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunTrigger; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowStatus; +import com.microsoft.azure.management.logic.v2019_05_01.ResourceReference; + +class RunWorkflowWorkflowRunImpl extends IndexableRefreshableWrapperImpl implements RunWorkflowWorkflowRun { + private final LogicManager manager; + private String resourceGroupName; + private String workflowName; + private String runName; + private String operationId; + + RunWorkflowWorkflowRunImpl(WorkflowRunInner inner, LogicManager manager) { + super(null, inner); + this.manager = manager; + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.workflowName = IdParsingUtils.getValueFromIdByName(inner.id(), "workflows"); + this.runName = IdParsingUtils.getValueFromIdByName(inner.id(), "runs"); + this.operationId = IdParsingUtils.getValueFromIdByName(inner.id(), "operations"); + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + protected Observable getInnerAsync() { + WorkflowRunOperationsInner client = this.manager().inner().workflowRunOperations(); + return client.getAsync(this.resourceGroupName, this.workflowName, this.runName, this.operationId); + } + + + + @Override + public String code() { + return this.inner().code(); + } + + @Override + public Correlation correlation() { + return this.inner().correlation(); + } + + @Override + public String correlationId() { + return this.inner().correlationId(); + } + + @Override + public DateTime endTime() { + return this.inner().endTime(); + } + + @Override + public Object error() { + return this.inner().error(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public Map outputs() { + return this.inner().outputs(); + } + + @Override + public WorkflowRunTrigger response() { + return this.inner().response(); + } + + @Override + public DateTime startTime() { + return this.inner().startTime(); + } + + @Override + public WorkflowStatus status() { + return this.inner().status(); + } + + @Override + public WorkflowRunTrigger trigger() { + return this.inner().trigger(); + } + + @Override + public String type() { + return this.inner().type(); + } + + @Override + public DateTime waitEndTime() { + return this.inner().waitEndTime(); + } + + @Override + public ResourceReference workflow() { + return this.inner().workflow(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowImpl.java new file mode 100644 index 000000000000..19032f5ed0f6 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowImpl.java @@ -0,0 +1,162 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.resources.models.implementation.GroupableResourceCoreImpl; +import com.microsoft.azure.management.logic.v2019_05_01.Workflow; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowProvisioningState; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowState; +import com.microsoft.azure.management.logic.v2019_05_01.FlowEndpointsConfiguration; +import com.microsoft.azure.management.logic.v2019_05_01.FlowAccessControlConfiguration; +import com.microsoft.azure.management.logic.v2019_05_01.Sku; +import com.microsoft.azure.management.logic.v2019_05_01.ResourceReference; +import java.util.Map; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowParameter; + +class WorkflowImpl extends GroupableResourceCoreImpl implements Workflow, Workflow.Definition, Workflow.Update { + WorkflowImpl(String name, WorkflowInner inner, LogicManager manager) { + super(name, inner, manager); + } + + @Override + public Observable createResourceAsync() { + WorkflowsInner client = this.manager().inner().workflows(); + return client.createOrUpdateAsync(this.resourceGroupName(), this.name(), this.inner()) + .map(innerToFluentMap(this)); + } + + @Override + public Observable updateResourceAsync() { + WorkflowsInner client = this.manager().inner().workflows(); + return client.updateAsync(this.resourceGroupName(), this.name()) + .map(innerToFluentMap(this)); + } + + @Override + protected Observable getInnerAsync() { + WorkflowsInner client = this.manager().inner().workflows(); + return client.getByResourceGroupAsync(this.resourceGroupName(), this.name()); + } + + @Override + public boolean isInCreateMode() { + return this.inner().id() == null; + } + + + @Override + public FlowAccessControlConfiguration accessControl() { + return this.inner().accessControl(); + } + + @Override + public String accessEndpoint() { + return this.inner().accessEndpoint(); + } + + @Override + public DateTime changedTime() { + return this.inner().changedTime(); + } + + @Override + public DateTime createdTime() { + return this.inner().createdTime(); + } + + @Override + public Object definition() { + return this.inner().definition(); + } + + @Override + public FlowEndpointsConfiguration endpointsConfiguration() { + return this.inner().endpointsConfiguration(); + } + + @Override + public ResourceReference integrationAccount() { + return this.inner().integrationAccount(); + } + + @Override + public ResourceReference integrationServiceEnvironment() { + return this.inner().integrationServiceEnvironment(); + } + + @Override + public Map parameters() { + return this.inner().parameters(); + } + + @Override + public WorkflowProvisioningState provisioningState() { + return this.inner().provisioningState(); + } + + @Override + public Sku sku() { + return this.inner().sku(); + } + + @Override + public WorkflowState state() { + return this.inner().state(); + } + + @Override + public String version() { + return this.inner().version(); + } + + @Override + public WorkflowImpl withAccessControl(FlowAccessControlConfiguration accessControl) { + this.inner().withAccessControl(accessControl); + return this; + } + + @Override + public WorkflowImpl withDefinition(Object definition) { + this.inner().withDefinition(definition); + return this; + } + + @Override + public WorkflowImpl withEndpointsConfiguration(FlowEndpointsConfiguration endpointsConfiguration) { + this.inner().withEndpointsConfiguration(endpointsConfiguration); + return this; + } + + @Override + public WorkflowImpl withIntegrationAccount(ResourceReference integrationAccount) { + this.inner().withIntegrationAccount(integrationAccount); + return this; + } + + @Override + public WorkflowImpl withIntegrationServiceEnvironment(ResourceReference integrationServiceEnvironment) { + this.inner().withIntegrationServiceEnvironment(integrationServiceEnvironment); + return this; + } + + @Override + public WorkflowImpl withParameters(Map parameters) { + this.inner().withParameters(parameters); + return this; + } + + @Override + public WorkflowImpl withState(WorkflowState state) { + this.inner().withState(state); + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowInner.java new file mode 100644 index 000000000000..32b3d2e5afea --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowInner.java @@ -0,0 +1,308 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowProvisioningState; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowState; +import com.microsoft.azure.management.logic.v2019_05_01.FlowEndpointsConfiguration; +import com.microsoft.azure.management.logic.v2019_05_01.FlowAccessControlConfiguration; +import com.microsoft.azure.management.logic.v2019_05_01.Sku; +import com.microsoft.azure.management.logic.v2019_05_01.ResourceReference; +import java.util.Map; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowParameter; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The workflow type. + */ +@JsonFlatten +@SkipParentValidation +public class WorkflowInner extends Resource { + /** + * Gets the provisioning state. Possible values include: 'NotSpecified', + * 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', + * 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', + * 'Registering', 'Registered', 'Unregistering', 'Unregistered', + * 'Completed', 'Renewing', 'Pending', 'Waiting', 'InProgress'. + */ + @JsonProperty(value = "properties.provisioningState", access = JsonProperty.Access.WRITE_ONLY) + private WorkflowProvisioningState provisioningState; + + /** + * Gets the created time. + */ + @JsonProperty(value = "properties.createdTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime createdTime; + + /** + * Gets the changed time. + */ + @JsonProperty(value = "properties.changedTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime changedTime; + + /** + * The state. Possible values include: 'NotSpecified', 'Completed', + * 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + */ + @JsonProperty(value = "properties.state") + private WorkflowState state; + + /** + * Gets the version. + */ + @JsonProperty(value = "properties.version", access = JsonProperty.Access.WRITE_ONLY) + private String version; + + /** + * Gets the access endpoint. + */ + @JsonProperty(value = "properties.accessEndpoint", access = JsonProperty.Access.WRITE_ONLY) + private String accessEndpoint; + + /** + * The endpoints configuration. + */ + @JsonProperty(value = "properties.endpointsConfiguration") + private FlowEndpointsConfiguration endpointsConfiguration; + + /** + * The access control configuration. + */ + @JsonProperty(value = "properties.accessControl") + private FlowAccessControlConfiguration accessControl; + + /** + * The sku. + */ + @JsonProperty(value = "properties.sku", access = JsonProperty.Access.WRITE_ONLY) + private Sku sku; + + /** + * The integration account. + */ + @JsonProperty(value = "properties.integrationAccount") + private ResourceReference integrationAccount; + + /** + * The integration service environment. + */ + @JsonProperty(value = "properties.integrationServiceEnvironment") + private ResourceReference integrationServiceEnvironment; + + /** + * The definition. + */ + @JsonProperty(value = "properties.definition") + private Object definition; + + /** + * The parameters. + */ + @JsonProperty(value = "properties.parameters") + private Map parameters; + + /** + * Get gets the provisioning state. Possible values include: 'NotSpecified', 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', 'Registering', 'Registered', 'Unregistering', 'Unregistered', 'Completed', 'Renewing', 'Pending', 'Waiting', 'InProgress'. + * + * @return the provisioningState value + */ + public WorkflowProvisioningState provisioningState() { + return this.provisioningState; + } + + /** + * Get gets the created time. + * + * @return the createdTime value + */ + public DateTime createdTime() { + return this.createdTime; + } + + /** + * Get gets the changed time. + * + * @return the changedTime value + */ + public DateTime changedTime() { + return this.changedTime; + } + + /** + * Get the state. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + * + * @return the state value + */ + public WorkflowState state() { + return this.state; + } + + /** + * Set the state. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + * + * @param state the state value to set + * @return the WorkflowInner object itself. + */ + public WorkflowInner withState(WorkflowState state) { + this.state = state; + return this; + } + + /** + * Get gets the version. + * + * @return the version value + */ + public String version() { + return this.version; + } + + /** + * Get gets the access endpoint. + * + * @return the accessEndpoint value + */ + public String accessEndpoint() { + return this.accessEndpoint; + } + + /** + * Get the endpoints configuration. + * + * @return the endpointsConfiguration value + */ + public FlowEndpointsConfiguration endpointsConfiguration() { + return this.endpointsConfiguration; + } + + /** + * Set the endpoints configuration. + * + * @param endpointsConfiguration the endpointsConfiguration value to set + * @return the WorkflowInner object itself. + */ + public WorkflowInner withEndpointsConfiguration(FlowEndpointsConfiguration endpointsConfiguration) { + this.endpointsConfiguration = endpointsConfiguration; + return this; + } + + /** + * Get the access control configuration. + * + * @return the accessControl value + */ + public FlowAccessControlConfiguration accessControl() { + return this.accessControl; + } + + /** + * Set the access control configuration. + * + * @param accessControl the accessControl value to set + * @return the WorkflowInner object itself. + */ + public WorkflowInner withAccessControl(FlowAccessControlConfiguration accessControl) { + this.accessControl = accessControl; + return this; + } + + /** + * Get the sku. + * + * @return the sku value + */ + public Sku sku() { + return this.sku; + } + + /** + * Get the integration account. + * + * @return the integrationAccount value + */ + public ResourceReference integrationAccount() { + return this.integrationAccount; + } + + /** + * Set the integration account. + * + * @param integrationAccount the integrationAccount value to set + * @return the WorkflowInner object itself. + */ + public WorkflowInner withIntegrationAccount(ResourceReference integrationAccount) { + this.integrationAccount = integrationAccount; + return this; + } + + /** + * Get the integration service environment. + * + * @return the integrationServiceEnvironment value + */ + public ResourceReference integrationServiceEnvironment() { + return this.integrationServiceEnvironment; + } + + /** + * Set the integration service environment. + * + * @param integrationServiceEnvironment the integrationServiceEnvironment value to set + * @return the WorkflowInner object itself. + */ + public WorkflowInner withIntegrationServiceEnvironment(ResourceReference integrationServiceEnvironment) { + this.integrationServiceEnvironment = integrationServiceEnvironment; + return this; + } + + /** + * Get the definition. + * + * @return the definition value + */ + public Object definition() { + return this.definition; + } + + /** + * Set the definition. + * + * @param definition the definition value to set + * @return the WorkflowInner object itself. + */ + public WorkflowInner withDefinition(Object definition) { + this.definition = definition; + return this; + } + + /** + * Get the parameters. + * + * @return the parameters value + */ + public Map parameters() { + return this.parameters; + } + + /** + * Set the parameters. + * + * @param parameters the parameters value to set + * @return the WorkflowInner object itself. + */ + public WorkflowInner withParameters(Map parameters) { + this.parameters = parameters; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionImpl.java new file mode 100644 index 000000000000..efa4bac12f9c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionImpl.java @@ -0,0 +1,121 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunAction; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.RunActionCorrelation; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.ContentLink; +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.RetryHistory; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowStatus; + +class WorkflowRunActionImpl extends IndexableRefreshableWrapperImpl implements WorkflowRunAction { + private final LogicManager manager; + private String resourceGroupName; + private String workflowName; + private String runName; + private String actionName; + + WorkflowRunActionImpl(WorkflowRunActionInner inner, LogicManager manager) { + super(null, inner); + this.manager = manager; + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.workflowName = IdParsingUtils.getValueFromIdByName(inner.id(), "workflows"); + this.runName = IdParsingUtils.getValueFromIdByName(inner.id(), "runs"); + this.actionName = IdParsingUtils.getValueFromIdByName(inner.id(), "actions"); + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + protected Observable getInnerAsync() { + WorkflowRunActionsInner client = this.manager().inner().workflowRunActions(); + return client.getAsync(this.resourceGroupName, this.workflowName, this.runName, this.actionName); + } + + + + @Override + public String code() { + return this.inner().code(); + } + + @Override + public RunActionCorrelation correlation() { + return this.inner().correlation(); + } + + @Override + public DateTime endTime() { + return this.inner().endTime(); + } + + @Override + public Object error() { + return this.inner().error(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public ContentLink inputsLink() { + return this.inner().inputsLink(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public ContentLink outputsLink() { + return this.inner().outputsLink(); + } + + @Override + public List retryHistory() { + return this.inner().retryHistory(); + } + + @Override + public DateTime startTime() { + return this.inner().startTime(); + } + + @Override + public WorkflowStatus status() { + return this.inner().status(); + } + + @Override + public Object trackedProperties() { + return this.inner().trackedProperties(); + } + + @Override + public String trackingId() { + return this.inner().trackingId(); + } + + @Override + public String type() { + return this.inner().type(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionInner.java new file mode 100644 index 000000000000..62c4c9badfa2 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionInner.java @@ -0,0 +1,245 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowStatus; +import com.microsoft.azure.management.logic.v2019_05_01.RunActionCorrelation; +import com.microsoft.azure.management.logic.v2019_05_01.ContentLink; +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.RetryHistory; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.azure.SubResource; + +/** + * The workflow run action. + */ +@JsonFlatten +public class WorkflowRunActionInner extends SubResource { + /** + * Gets the start time. + */ + @JsonProperty(value = "properties.startTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime startTime; + + /** + * Gets the end time. + */ + @JsonProperty(value = "properties.endTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime endTime; + + /** + * Gets the status. Possible values include: 'NotSpecified', 'Paused', + * 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', + * 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + */ + @JsonProperty(value = "properties.status", access = JsonProperty.Access.WRITE_ONLY) + private WorkflowStatus status; + + /** + * Gets the code. + */ + @JsonProperty(value = "properties.code", access = JsonProperty.Access.WRITE_ONLY) + private String code; + + /** + * Gets the error. + */ + @JsonProperty(value = "properties.error", access = JsonProperty.Access.WRITE_ONLY) + private Object error; + + /** + * Gets the tracking id. + */ + @JsonProperty(value = "properties.trackingId", access = JsonProperty.Access.WRITE_ONLY) + private String trackingId; + + /** + * The correlation properties. + */ + @JsonProperty(value = "properties.correlation") + private RunActionCorrelation correlation; + + /** + * Gets the link to inputs. + */ + @JsonProperty(value = "properties.inputsLink", access = JsonProperty.Access.WRITE_ONLY) + private ContentLink inputsLink; + + /** + * Gets the link to outputs. + */ + @JsonProperty(value = "properties.outputsLink", access = JsonProperty.Access.WRITE_ONLY) + private ContentLink outputsLink; + + /** + * Gets the tracked properties. + */ + @JsonProperty(value = "properties.trackedProperties", access = JsonProperty.Access.WRITE_ONLY) + private Object trackedProperties; + + /** + * Gets the retry histories. + */ + @JsonProperty(value = "properties.retryHistory") + private List retryHistory; + + /** + * Gets the workflow run action name. + */ + @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY) + private String name; + + /** + * Gets the workflow run action type. + */ + @JsonProperty(value = "type", access = JsonProperty.Access.WRITE_ONLY) + private String type; + + /** + * Get gets the start time. + * + * @return the startTime value + */ + public DateTime startTime() { + return this.startTime; + } + + /** + * Get gets the end time. + * + * @return the endTime value + */ + public DateTime endTime() { + return this.endTime; + } + + /** + * Get gets the status. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @return the status value + */ + public WorkflowStatus status() { + return this.status; + } + + /** + * Get gets the code. + * + * @return the code value + */ + public String code() { + return this.code; + } + + /** + * Get gets the error. + * + * @return the error value + */ + public Object error() { + return this.error; + } + + /** + * Get gets the tracking id. + * + * @return the trackingId value + */ + public String trackingId() { + return this.trackingId; + } + + /** + * Get the correlation properties. + * + * @return the correlation value + */ + public RunActionCorrelation correlation() { + return this.correlation; + } + + /** + * Set the correlation properties. + * + * @param correlation the correlation value to set + * @return the WorkflowRunActionInner object itself. + */ + public WorkflowRunActionInner withCorrelation(RunActionCorrelation correlation) { + this.correlation = correlation; + return this; + } + + /** + * Get gets the link to inputs. + * + * @return the inputsLink value + */ + public ContentLink inputsLink() { + return this.inputsLink; + } + + /** + * Get gets the link to outputs. + * + * @return the outputsLink value + */ + public ContentLink outputsLink() { + return this.outputsLink; + } + + /** + * Get gets the tracked properties. + * + * @return the trackedProperties value + */ + public Object trackedProperties() { + return this.trackedProperties; + } + + /** + * Get gets the retry histories. + * + * @return the retryHistory value + */ + public List retryHistory() { + return this.retryHistory; + } + + /** + * Set gets the retry histories. + * + * @param retryHistory the retryHistory value to set + * @return the WorkflowRunActionInner object itself. + */ + public WorkflowRunActionInner withRetryHistory(List retryHistory) { + this.retryHistory = retryHistory; + return this; + } + + /** + * Get gets the workflow run action name. + * + * @return the name value + */ + public String name() { + return this.name; + } + + /** + * Get gets the workflow run action type. + * + * @return the type value + */ + public String type() { + return this.type; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionDefinitionInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionDefinitionInner.java new file mode 100644 index 000000000000..d88d5751a470 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionDefinitionInner.java @@ -0,0 +1,356 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.RunActionCorrelation; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowStatus; +import com.microsoft.azure.management.logic.v2019_05_01.ContentLink; +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.RetryHistory; +import com.microsoft.azure.management.logic.v2019_05_01.RepetitionIndex; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The workflow run action repetition definition. + */ +@JsonFlatten +@SkipParentValidation +public class WorkflowRunActionRepetitionDefinitionInner extends Resource { + /** + * The start time of the workflow scope repetition. + */ + @JsonProperty(value = "properties.startTime") + private DateTime startTime; + + /** + * The end time of the workflow scope repetition. + */ + @JsonProperty(value = "properties.endTime") + private DateTime endTime; + + /** + * The correlation properties. + */ + @JsonProperty(value = "properties.correlation") + private RunActionCorrelation correlation; + + /** + * The status of the workflow scope repetition. Possible values include: + * 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', + * 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', + * 'Ignored'. + */ + @JsonProperty(value = "properties.status") + private WorkflowStatus status; + + /** + * The workflow scope repetition code. + */ + @JsonProperty(value = "properties.code") + private String code; + + /** + * The error property. + */ + @JsonProperty(value = "properties.error") + private Object error; + + /** + * Gets the tracking id. + */ + @JsonProperty(value = "properties.trackingId", access = JsonProperty.Access.WRITE_ONLY) + private String trackingId; + + /** + * Gets the inputs. + */ + @JsonProperty(value = "properties.inputs", access = JsonProperty.Access.WRITE_ONLY) + private Object inputs; + + /** + * Gets the link to inputs. + */ + @JsonProperty(value = "properties.inputsLink", access = JsonProperty.Access.WRITE_ONLY) + private ContentLink inputsLink; + + /** + * Gets the outputs. + */ + @JsonProperty(value = "properties.outputs", access = JsonProperty.Access.WRITE_ONLY) + private Object outputs; + + /** + * Gets the link to outputs. + */ + @JsonProperty(value = "properties.outputsLink", access = JsonProperty.Access.WRITE_ONLY) + private ContentLink outputsLink; + + /** + * Gets the tracked properties. + */ + @JsonProperty(value = "properties.trackedProperties", access = JsonProperty.Access.WRITE_ONLY) + private Object trackedProperties; + + /** + * Gets the retry histories. + */ + @JsonProperty(value = "properties.retryHistory") + private List retryHistory; + + /** + * The iterationCount property. + */ + @JsonProperty(value = "properties.iterationCount") + private Integer iterationCount; + + /** + * The repetition indexes. + */ + @JsonProperty(value = "properties.repetitionIndexes") + private List repetitionIndexes; + + /** + * Get the start time of the workflow scope repetition. + * + * @return the startTime value + */ + public DateTime startTime() { + return this.startTime; + } + + /** + * Set the start time of the workflow scope repetition. + * + * @param startTime the startTime value to set + * @return the WorkflowRunActionRepetitionDefinitionInner object itself. + */ + public WorkflowRunActionRepetitionDefinitionInner withStartTime(DateTime startTime) { + this.startTime = startTime; + return this; + } + + /** + * Get the end time of the workflow scope repetition. + * + * @return the endTime value + */ + public DateTime endTime() { + return this.endTime; + } + + /** + * Set the end time of the workflow scope repetition. + * + * @param endTime the endTime value to set + * @return the WorkflowRunActionRepetitionDefinitionInner object itself. + */ + public WorkflowRunActionRepetitionDefinitionInner withEndTime(DateTime endTime) { + this.endTime = endTime; + return this; + } + + /** + * Get the correlation properties. + * + * @return the correlation value + */ + public RunActionCorrelation correlation() { + return this.correlation; + } + + /** + * Set the correlation properties. + * + * @param correlation the correlation value to set + * @return the WorkflowRunActionRepetitionDefinitionInner object itself. + */ + public WorkflowRunActionRepetitionDefinitionInner withCorrelation(RunActionCorrelation correlation) { + this.correlation = correlation; + return this; + } + + /** + * Get the status of the workflow scope repetition. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @return the status value + */ + public WorkflowStatus status() { + return this.status; + } + + /** + * Set the status of the workflow scope repetition. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @param status the status value to set + * @return the WorkflowRunActionRepetitionDefinitionInner object itself. + */ + public WorkflowRunActionRepetitionDefinitionInner withStatus(WorkflowStatus status) { + this.status = status; + return this; + } + + /** + * Get the workflow scope repetition code. + * + * @return the code value + */ + public String code() { + return this.code; + } + + /** + * Set the workflow scope repetition code. + * + * @param code the code value to set + * @return the WorkflowRunActionRepetitionDefinitionInner object itself. + */ + public WorkflowRunActionRepetitionDefinitionInner withCode(String code) { + this.code = code; + return this; + } + + /** + * Get the error value. + * + * @return the error value + */ + public Object error() { + return this.error; + } + + /** + * Set the error value. + * + * @param error the error value to set + * @return the WorkflowRunActionRepetitionDefinitionInner object itself. + */ + public WorkflowRunActionRepetitionDefinitionInner withError(Object error) { + this.error = error; + return this; + } + + /** + * Get gets the tracking id. + * + * @return the trackingId value + */ + public String trackingId() { + return this.trackingId; + } + + /** + * Get gets the inputs. + * + * @return the inputs value + */ + public Object inputs() { + return this.inputs; + } + + /** + * Get gets the link to inputs. + * + * @return the inputsLink value + */ + public ContentLink inputsLink() { + return this.inputsLink; + } + + /** + * Get gets the outputs. + * + * @return the outputs value + */ + public Object outputs() { + return this.outputs; + } + + /** + * Get gets the link to outputs. + * + * @return the outputsLink value + */ + public ContentLink outputsLink() { + return this.outputsLink; + } + + /** + * Get gets the tracked properties. + * + * @return the trackedProperties value + */ + public Object trackedProperties() { + return this.trackedProperties; + } + + /** + * Get gets the retry histories. + * + * @return the retryHistory value + */ + public List retryHistory() { + return this.retryHistory; + } + + /** + * Set gets the retry histories. + * + * @param retryHistory the retryHistory value to set + * @return the WorkflowRunActionRepetitionDefinitionInner object itself. + */ + public WorkflowRunActionRepetitionDefinitionInner withRetryHistory(List retryHistory) { + this.retryHistory = retryHistory; + return this; + } + + /** + * Get the iterationCount value. + * + * @return the iterationCount value + */ + public Integer iterationCount() { + return this.iterationCount; + } + + /** + * Set the iterationCount value. + * + * @param iterationCount the iterationCount value to set + * @return the WorkflowRunActionRepetitionDefinitionInner object itself. + */ + public WorkflowRunActionRepetitionDefinitionInner withIterationCount(Integer iterationCount) { + this.iterationCount = iterationCount; + return this; + } + + /** + * Get the repetition indexes. + * + * @return the repetitionIndexes value + */ + public List repetitionIndexes() { + return this.repetitionIndexes; + } + + /** + * Set the repetition indexes. + * + * @param repetitionIndexes the repetitionIndexes value to set + * @return the WorkflowRunActionRepetitionDefinitionInner object itself. + */ + public WorkflowRunActionRepetitionDefinitionInner withRepetitionIndexes(List repetitionIndexes) { + this.repetitionIndexes = repetitionIndexes; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionsImpl.java new file mode 100644 index 000000000000..f11e95b056b2 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionsImpl.java @@ -0,0 +1,88 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRepetitions; +import rx.Observable; +import rx.functions.Func1; +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.ExpressionRoot; +import com.microsoft.azure.management.logic.v2019_05_01.ActionRunWorkflowWorkflowRunActionRepetitionDefinition; + +class WorkflowRunActionRepetitionsImpl extends WrapperImpl implements WorkflowRunActionRepetitions { + private final LogicManager manager; + + WorkflowRunActionRepetitionsImpl(LogicManager manager) { + super(manager.inner().workflowRunActionRepetitions()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + private ActionRunWorkflowWorkflowRunActionRepetitionDefinitionImpl wrapModel(WorkflowRunActionRepetitionDefinitionInner inner) { + return new ActionRunWorkflowWorkflowRunActionRepetitionDefinitionImpl(inner, manager()); + } + + @Override + public Observable listExpressionTracesAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { + WorkflowRunActionRepetitionsInner client = this.inner(); + return client.listExpressionTracesAsync(resourceGroupName, workflowName, runName, actionName, repetitionName) + .flatMap(new Func1, Observable>() { + @Override + public Observable call(List innerList) { + return Observable.from(innerList); + } + }) + .map(new Func1() { + @Override + public ExpressionRoot call(ExpressionRootInner inner) { + return new ExpressionRootImpl(inner, manager()); + } + }); + } + + @Override + public Observable listAsync(String resourceGroupName, String workflowName, String runName, String actionName) { + WorkflowRunActionRepetitionsInner client = this.inner(); + return client.listAsync(resourceGroupName, workflowName, runName, actionName) + .flatMap(new Func1, Observable>() { + @Override + public Observable call(List innerList) { + return Observable.from(innerList); + } + }) + .map(new Func1() { + @Override + public ActionRunWorkflowWorkflowRunActionRepetitionDefinition call(WorkflowRunActionRepetitionDefinitionInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { + WorkflowRunActionRepetitionsInner client = this.inner(); + return client.getAsync(resourceGroupName, workflowName, runName, actionName, repetitionName) + .flatMap(new Func1>() { + @Override + public Observable call(WorkflowRunActionRepetitionDefinitionInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((ActionRunWorkflowWorkflowRunActionRepetitionDefinition)wrapModel(inner)); + } + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionsInner.java new file mode 100644 index 000000000000..4b281e45671c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionsInner.java @@ -0,0 +1,394 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.Query; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in WorkflowRunActionRepetitions. + */ +public class WorkflowRunActionRepetitionsInner { + /** The Retrofit service to perform REST calls. */ + private WorkflowRunActionRepetitionsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of WorkflowRunActionRepetitionsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public WorkflowRunActionRepetitionsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(WorkflowRunActionRepetitionsService.class); + this.client = client; + } + + /** + * The interface defining all the services for WorkflowRunActionRepetitions to be + * used by Retrofit to perform actually REST calls. + */ + interface WorkflowRunActionRepetitionsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRepetitions list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/actions/{actionName}/repetitions") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Path("actionName") String actionName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRepetitions get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/actions/{actionName}/repetitions/{repetitionName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Path("actionName") String actionName, @Path("repetitionName") String repetitionName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRepetitions listExpressionTraces" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/actions/{actionName}/repetitions/{repetitionName}/listExpressionTraces") + Observable> listExpressionTraces(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Path("actionName") String actionName, @Path("repetitionName") String repetitionName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Get all of a workflow run action repetitions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the List<WorkflowRunActionRepetitionDefinitionInner> object if successful. + */ + public List list(String resourceGroupName, String workflowName, String runName, String actionName) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName).toBlocking().single().body(); + } + + /** + * Get all of a workflow run action repetitions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(String resourceGroupName, String workflowName, String runName, String actionName, final ServiceCallback> serviceCallback) { + return ServiceFuture.fromResponse(listWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName), serviceCallback); + } + + /** + * Get all of a workflow run action repetitions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<WorkflowRunActionRepetitionDefinitionInner> object + */ + public Observable> listAsync(String resourceGroupName, String workflowName, String runName, String actionName) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName).map(new Func1>, List>() { + @Override + public List call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Get all of a workflow run action repetitions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<WorkflowRunActionRepetitionDefinitionInner> object + */ + public Observable>> listWithServiceResponseAsync(String resourceGroupName, String workflowName, String runName, String actionName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (actionName == null) { + throw new IllegalArgumentException("Parameter actionName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, runName, actionName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + List items = null; + if (result.body() != null) { + items = result.body().items(); + } + ServiceResponse> clientResponse = new ServiceResponse>(items, result.response()); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Get a workflow run action repetition. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowRunActionRepetitionDefinitionInner object if successful. + */ + public WorkflowRunActionRepetitionDefinitionInner get(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName).toBlocking().single().body(); + } + + /** + * Get a workflow run action repetition. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName), serviceCallback); + } + + /** + * Get a workflow run action repetition. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowRunActionRepetitionDefinitionInner object + */ + public Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName).map(new Func1, WorkflowRunActionRepetitionDefinitionInner>() { + @Override + public WorkflowRunActionRepetitionDefinitionInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get a workflow run action repetition. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowRunActionRepetitionDefinitionInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (actionName == null) { + throw new IllegalArgumentException("Parameter actionName is required and cannot be null."); + } + if (repetitionName == null) { + throw new IllegalArgumentException("Parameter repetitionName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, workflowName, runName, actionName, repetitionName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Lists a workflow run expression trace. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the List<ExpressionRootInner> object if successful. + */ + public List listExpressionTraces(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { + return listExpressionTracesWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName).toBlocking().single().body(); + } + + /** + * Lists a workflow run expression trace. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listExpressionTracesAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName, final ServiceCallback> serviceCallback) { + return ServiceFuture.fromResponse(listExpressionTracesWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName), serviceCallback); + } + + /** + * Lists a workflow run expression trace. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<ExpressionRootInner> object + */ + public Observable> listExpressionTracesAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { + return listExpressionTracesWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName).map(new Func1>, List>() { + @Override + public List call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Lists a workflow run expression trace. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<ExpressionRootInner> object + */ + public Observable>> listExpressionTracesWithServiceResponseAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (actionName == null) { + throw new IllegalArgumentException("Parameter actionName is required and cannot be null."); + } + if (repetitionName == null) { + throw new IllegalArgumentException("Parameter repetitionName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.listExpressionTraces(this.client.subscriptionId(), resourceGroupName, workflowName, runName, actionName, repetitionName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listExpressionTracesDelegate(response); + List items = null; + if (result.body() != null) { + items = result.body().items(); + } + ServiceResponse> clientResponse = new ServiceResponse>(items, result.response()); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listExpressionTracesDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionsRequestHistoriesImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionsRequestHistoriesImpl.java new file mode 100644 index 000000000000..9eda0ba12819 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionsRequestHistoriesImpl.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRepetitionsRequestHistories; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.RepetitionActionRunWorkflowRequestHistory; + +class WorkflowRunActionRepetitionsRequestHistoriesImpl extends WrapperImpl implements WorkflowRunActionRepetitionsRequestHistories { + private final LogicManager manager; + + WorkflowRunActionRepetitionsRequestHistoriesImpl(LogicManager manager) { + super(manager.inner().workflowRunActionRepetitionsRequestHistories()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + private RepetitionActionRunWorkflowRequestHistoryImpl wrapModel(RequestHistoryInner inner) { + return new RepetitionActionRunWorkflowRequestHistoryImpl(inner, manager()); + } + + @Override + public Observable listAsync(final String resourceGroupName, final String workflowName, final String runName, final String actionName, final String repetitionName) { + WorkflowRunActionRepetitionsRequestHistoriesInner client = this.inner(); + return client.listAsync(resourceGroupName, workflowName, runName, actionName, repetitionName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public RepetitionActionRunWorkflowRequestHistory call(RequestHistoryInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName, String requestHistoryName) { + WorkflowRunActionRepetitionsRequestHistoriesInner client = this.inner(); + return client.getAsync(resourceGroupName, workflowName, runName, actionName, repetitionName, requestHistoryName) + .flatMap(new Func1>() { + @Override + public Observable call(RequestHistoryInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((RepetitionActionRunWorkflowRequestHistory)wrapModel(inner)); + } + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionsRequestHistoriesInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionsRequestHistoriesInner.java new file mode 100644 index 000000000000..d8f92a0f510c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRepetitionsRequestHistoriesInner.java @@ -0,0 +1,446 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in WorkflowRunActionRepetitionsRequestHistories. + */ +public class WorkflowRunActionRepetitionsRequestHistoriesInner { + /** The Retrofit service to perform REST calls. */ + private WorkflowRunActionRepetitionsRequestHistoriesService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of WorkflowRunActionRepetitionsRequestHistoriesInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public WorkflowRunActionRepetitionsRequestHistoriesInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(WorkflowRunActionRepetitionsRequestHistoriesService.class); + this.client = client; + } + + /** + * The interface defining all the services for WorkflowRunActionRepetitionsRequestHistories to be + * used by Retrofit to perform actually REST calls. + */ + interface WorkflowRunActionRepetitionsRequestHistoriesService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRepetitionsRequestHistories list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/actions/{actionName}/repetitions/{repetitionName}/requestHistories") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Path("actionName") String actionName, @Path("repetitionName") String repetitionName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRepetitionsRequestHistories get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/actions/{actionName}/repetitions/{repetitionName}/requestHistories/{requestHistoryName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Path("actionName") String actionName, @Path("repetitionName") String repetitionName, @Path("requestHistoryName") String requestHistoryName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRepetitionsRequestHistories listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * List a workflow run repetition request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<RequestHistoryInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String workflowName, final String runName, final String actionName, final String repetitionName) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, workflowName, runName, actionName, repetitionName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * List a workflow run repetition request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String workflowName, final String runName, final String actionName, final String repetitionName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, workflowName, runName, actionName, repetitionName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * List a workflow run repetition request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<RequestHistoryInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String workflowName, final String runName, final String actionName, final String repetitionName) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * List a workflow run repetition request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<RequestHistoryInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String workflowName, final String runName, final String actionName, final String repetitionName) { + return listSinglePageAsync(resourceGroupName, workflowName, runName, actionName, repetitionName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * List a workflow run repetition request history. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param workflowName The workflow name. + ServiceResponse> * @param runName The workflow run name. + ServiceResponse> * @param actionName The workflow action name. + ServiceResponse> * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<RequestHistoryInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String workflowName, final String runName, final String actionName, final String repetitionName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (actionName == null) { + throw new IllegalArgumentException("Parameter actionName is required and cannot be null."); + } + if (repetitionName == null) { + throw new IllegalArgumentException("Parameter repetitionName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, runName, actionName, repetitionName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a workflow run repetition request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @param requestHistoryName The request history name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the RequestHistoryInner object if successful. + */ + public RequestHistoryInner get(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName, String requestHistoryName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName, requestHistoryName).toBlocking().single().body(); + } + + /** + * Gets a workflow run repetition request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @param requestHistoryName The request history name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName, String requestHistoryName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName, requestHistoryName), serviceCallback); + } + + /** + * Gets a workflow run repetition request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @param requestHistoryName The request history name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the RequestHistoryInner object + */ + public Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName, String requestHistoryName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName, requestHistoryName).map(new Func1, RequestHistoryInner>() { + @Override + public RequestHistoryInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets a workflow run repetition request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @param requestHistoryName The request history name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the RequestHistoryInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName, String requestHistoryName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (actionName == null) { + throw new IllegalArgumentException("Parameter actionName is required and cannot be null."); + } + if (repetitionName == null) { + throw new IllegalArgumentException("Parameter repetitionName is required and cannot be null."); + } + if (requestHistoryName == null) { + throw new IllegalArgumentException("Parameter requestHistoryName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, workflowName, runName, actionName, repetitionName, requestHistoryName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * List a workflow run repetition request history. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<RequestHistoryInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * List a workflow run repetition request history. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * List a workflow run repetition request history. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<RequestHistoryInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * List a workflow run repetition request history. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<RequestHistoryInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * List a workflow run repetition request history. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<RequestHistoryInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRequestHistoriesImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRequestHistoriesImpl.java new file mode 100644 index 000000000000..11a4ac31f4fd --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRequestHistoriesImpl.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRequestHistories; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.ActionRunWorkflowRequestHistory; + +class WorkflowRunActionRequestHistoriesImpl extends WrapperImpl implements WorkflowRunActionRequestHistories { + private final LogicManager manager; + + WorkflowRunActionRequestHistoriesImpl(LogicManager manager) { + super(manager.inner().workflowRunActionRequestHistories()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + private ActionRunWorkflowRequestHistoryImpl wrapModel(RequestHistoryInner inner) { + return new ActionRunWorkflowRequestHistoryImpl(inner, manager()); + } + + @Override + public Observable listAsync(final String resourceGroupName, final String workflowName, final String runName, final String actionName) { + WorkflowRunActionRequestHistoriesInner client = this.inner(); + return client.listAsync(resourceGroupName, workflowName, runName, actionName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public ActionRunWorkflowRequestHistory call(RequestHistoryInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String requestHistoryName) { + WorkflowRunActionRequestHistoriesInner client = this.inner(); + return client.getAsync(resourceGroupName, workflowName, runName, actionName, requestHistoryName) + .flatMap(new Func1>() { + @Override + public Observable call(RequestHistoryInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((ActionRunWorkflowRequestHistory)wrapModel(inner)); + } + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRequestHistoriesInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRequestHistoriesInner.java new file mode 100644 index 000000000000..694a6ea22ece --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionRequestHistoriesInner.java @@ -0,0 +1,431 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in WorkflowRunActionRequestHistories. + */ +public class WorkflowRunActionRequestHistoriesInner { + /** The Retrofit service to perform REST calls. */ + private WorkflowRunActionRequestHistoriesService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of WorkflowRunActionRequestHistoriesInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public WorkflowRunActionRequestHistoriesInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(WorkflowRunActionRequestHistoriesService.class); + this.client = client; + } + + /** + * The interface defining all the services for WorkflowRunActionRequestHistories to be + * used by Retrofit to perform actually REST calls. + */ + interface WorkflowRunActionRequestHistoriesService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRequestHistories list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/actions/{actionName}/requestHistories") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Path("actionName") String actionName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRequestHistories get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/actions/{actionName}/requestHistories/{requestHistoryName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Path("actionName") String actionName, @Path("requestHistoryName") String requestHistoryName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionRequestHistories listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * List a workflow run request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<RequestHistoryInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String workflowName, final String runName, final String actionName) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, workflowName, runName, actionName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * List a workflow run request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String workflowName, final String runName, final String actionName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, workflowName, runName, actionName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * List a workflow run request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<RequestHistoryInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String workflowName, final String runName, final String actionName) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * List a workflow run request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<RequestHistoryInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String workflowName, final String runName, final String actionName) { + return listSinglePageAsync(resourceGroupName, workflowName, runName, actionName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * List a workflow run request history. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param workflowName The workflow name. + ServiceResponse> * @param runName The workflow run name. + ServiceResponse> * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<RequestHistoryInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String workflowName, final String runName, final String actionName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (actionName == null) { + throw new IllegalArgumentException("Parameter actionName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, runName, actionName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a workflow run request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param requestHistoryName The request history name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the RequestHistoryInner object if successful. + */ + public RequestHistoryInner get(String resourceGroupName, String workflowName, String runName, String actionName, String requestHistoryName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, requestHistoryName).toBlocking().single().body(); + } + + /** + * Gets a workflow run request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param requestHistoryName The request history name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String requestHistoryName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, requestHistoryName), serviceCallback); + } + + /** + * Gets a workflow run request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param requestHistoryName The request history name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the RequestHistoryInner object + */ + public Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String requestHistoryName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, requestHistoryName).map(new Func1, RequestHistoryInner>() { + @Override + public RequestHistoryInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets a workflow run request history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param requestHistoryName The request history name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the RequestHistoryInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String workflowName, String runName, String actionName, String requestHistoryName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (actionName == null) { + throw new IllegalArgumentException("Parameter actionName is required and cannot be null."); + } + if (requestHistoryName == null) { + throw new IllegalArgumentException("Parameter requestHistoryName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, workflowName, runName, actionName, requestHistoryName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * List a workflow run request history. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<RequestHistoryInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * List a workflow run request history. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * List a workflow run request history. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<RequestHistoryInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * List a workflow run request history. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<RequestHistoryInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * List a workflow run request history. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<RequestHistoryInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionScopeRepetitionsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionScopeRepetitionsImpl.java new file mode 100644 index 000000000000..92ddbd824690 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionScopeRepetitionsImpl.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionScopeRepetitions; +import rx.Observable; +import rx.functions.Func1; +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel; + +class WorkflowRunActionScopeRepetitionsImpl extends WrapperImpl implements WorkflowRunActionScopeRepetitions { + private final LogicManager manager; + + WorkflowRunActionScopeRepetitionsImpl(LogicManager manager) { + super(manager.inner().workflowRunActionScopeRepetitions()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + private ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModelImpl wrapModel(WorkflowRunActionRepetitionDefinitionInner inner) { + return new ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModelImpl(inner, manager()); + } + + @Override + public Observable listAsync(String resourceGroupName, String workflowName, String runName, String actionName) { + WorkflowRunActionScopeRepetitionsInner client = this.inner(); + return client.listAsync(resourceGroupName, workflowName, runName, actionName) + .flatMap(new Func1, Observable>() { + @Override + public Observable call(List innerList) { + return Observable.from(innerList); + } + }) + .map(new Func1() { + @Override + public ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel call(WorkflowRunActionRepetitionDefinitionInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { + WorkflowRunActionScopeRepetitionsInner client = this.inner(); + return client.getAsync(resourceGroupName, workflowName, runName, actionName, repetitionName) + .flatMap(new Func1>() { + @Override + public Observable call(WorkflowRunActionRepetitionDefinitionInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel)wrapModel(inner)); + } + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionScopeRepetitionsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionScopeRepetitionsInner.java new file mode 100644 index 000000000000..9e39d1999326 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionScopeRepetitionsInner.java @@ -0,0 +1,277 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.Query; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in WorkflowRunActionScopeRepetitions. + */ +public class WorkflowRunActionScopeRepetitionsInner { + /** The Retrofit service to perform REST calls. */ + private WorkflowRunActionScopeRepetitionsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of WorkflowRunActionScopeRepetitionsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public WorkflowRunActionScopeRepetitionsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(WorkflowRunActionScopeRepetitionsService.class); + this.client = client; + } + + /** + * The interface defining all the services for WorkflowRunActionScopeRepetitions to be + * used by Retrofit to perform actually REST calls. + */ + interface WorkflowRunActionScopeRepetitionsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionScopeRepetitions list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/actions/{actionName}/scopeRepetitions") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Path("actionName") String actionName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActionScopeRepetitions get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/actions/{actionName}/scopeRepetitions/{repetitionName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Path("actionName") String actionName, @Path("repetitionName") String repetitionName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * List the workflow run action scoped repetitions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the List<WorkflowRunActionRepetitionDefinitionInner> object if successful. + */ + public List list(String resourceGroupName, String workflowName, String runName, String actionName) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName).toBlocking().single().body(); + } + + /** + * List the workflow run action scoped repetitions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(String resourceGroupName, String workflowName, String runName, String actionName, final ServiceCallback> serviceCallback) { + return ServiceFuture.fromResponse(listWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName), serviceCallback); + } + + /** + * List the workflow run action scoped repetitions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<WorkflowRunActionRepetitionDefinitionInner> object + */ + public Observable> listAsync(String resourceGroupName, String workflowName, String runName, String actionName) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName).map(new Func1>, List>() { + @Override + public List call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * List the workflow run action scoped repetitions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<WorkflowRunActionRepetitionDefinitionInner> object + */ + public Observable>> listWithServiceResponseAsync(String resourceGroupName, String workflowName, String runName, String actionName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (actionName == null) { + throw new IllegalArgumentException("Parameter actionName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, runName, actionName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + List items = null; + if (result.body() != null) { + items = result.body().items(); + } + ServiceResponse> clientResponse = new ServiceResponse>(items, result.response()); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Get a workflow run action scoped repetition. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowRunActionRepetitionDefinitionInner object if successful. + */ + public WorkflowRunActionRepetitionDefinitionInner get(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName).toBlocking().single().body(); + } + + /** + * Get a workflow run action scoped repetition. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName), serviceCallback); + } + + /** + * Get a workflow run action scoped repetition. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowRunActionRepetitionDefinitionInner object + */ + public Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName, repetitionName).map(new Func1, WorkflowRunActionRepetitionDefinitionInner>() { + @Override + public WorkflowRunActionRepetitionDefinitionInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get a workflow run action scoped repetition. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param repetitionName The workflow repetition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowRunActionRepetitionDefinitionInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String workflowName, String runName, String actionName, String repetitionName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (actionName == null) { + throw new IllegalArgumentException("Parameter actionName is required and cannot be null."); + } + if (repetitionName == null) { + throw new IllegalArgumentException("Parameter repetitionName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, workflowName, runName, actionName, repetitionName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionsImpl.java new file mode 100644 index 000000000000..3c1fc9bcd47a --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionsImpl.java @@ -0,0 +1,89 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActions; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.ExpressionRoot; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunAction; + +class WorkflowRunActionsImpl extends WrapperImpl implements WorkflowRunActions { + private final LogicManager manager; + + WorkflowRunActionsImpl(LogicManager manager) { + super(manager.inner().workflowRunActions()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + private WorkflowRunActionImpl wrapModel(WorkflowRunActionInner inner) { + return new WorkflowRunActionImpl(inner, manager()); + } + + @Override + public Observable listExpressionTracesAsync(String resourceGroupName, String workflowName, String runName, String actionName) { + WorkflowRunActionsInner client = this.inner(); + return client.listExpressionTracesAsync(resourceGroupName, workflowName, runName, actionName) + .flatMap(new Func1, Observable>() { + @Override + public Observable call(List innerList) { + return Observable.from(innerList); + } + }) + .map(new Func1() { + @Override + public ExpressionRoot call(ExpressionRootInner inner) { + return new ExpressionRootImpl(inner, manager()); + } + }); + } + + @Override + public Observable listAsync(final String resourceGroupName, final String workflowName, final String runName) { + WorkflowRunActionsInner client = this.inner(); + return client.listAsync(resourceGroupName, workflowName, runName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public WorkflowRunAction call(WorkflowRunActionInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName) { + WorkflowRunActionsInner client = this.inner(); + return client.getAsync(resourceGroupName, workflowName, runName, actionName) + .flatMap(new Func1>() { + @Override + public Observable call(WorkflowRunActionInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((WorkflowRunAction)wrapModel(inner)); + } + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionsInner.java new file mode 100644 index 000000000000..be1591847f22 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunActionsInner.java @@ -0,0 +1,662 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in WorkflowRunActions. + */ +public class WorkflowRunActionsInner { + /** The Retrofit service to perform REST calls. */ + private WorkflowRunActionsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of WorkflowRunActionsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public WorkflowRunActionsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(WorkflowRunActionsService.class); + this.client = client; + } + + /** + * The interface defining all the services for WorkflowRunActions to be + * used by Retrofit to perform actually REST calls. + */ + interface WorkflowRunActionsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActions list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/actions") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Query("$filter") String filter, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActions get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/actions/{actionName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Path("actionName") String actionName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActions listExpressionTraces" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/actions/{actionName}/listExpressionTraces") + Observable> listExpressionTraces(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Path("actionName") String actionName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunActions listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of workflow run actions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowRunActionInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String workflowName, final String runName) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, workflowName, runName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow run actions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String workflowName, final String runName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, workflowName, runName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow run actions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowRunActionInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String workflowName, final String runName) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, runName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow run actions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowRunActionInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String workflowName, final String runName) { + return listSinglePageAsync(resourceGroupName, workflowName, runName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow run actions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowRunActionInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String workflowName, final String runName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + final String filter = null; + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, runName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of workflow run actions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: Status. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowRunActionInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String workflowName, final String runName, final Integer top, final String filter) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, workflowName, runName, top, filter).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow run actions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: Status. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String workflowName, final String runName, final Integer top, final String filter, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, workflowName, runName, top, filter), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow run actions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: Status. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowRunActionInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String workflowName, final String runName, final Integer top, final String filter) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, runName, top, filter) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow run actions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: Status. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowRunActionInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String workflowName, final String runName, final Integer top, final String filter) { + return listSinglePageAsync(resourceGroupName, workflowName, runName, top, filter) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow run actions. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param workflowName The workflow name. + ServiceResponse> * @param runName The workflow run name. + ServiceResponse> * @param top The number of items to be included in the result. + ServiceResponse> * @param filter The filter to apply on the operation. Options for filters include: Status. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowRunActionInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String workflowName, final String runName, final Integer top, final String filter) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, runName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a workflow run action. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowRunActionInner object if successful. + */ + public WorkflowRunActionInner get(String resourceGroupName, String workflowName, String runName, String actionName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName).toBlocking().single().body(); + } + + /** + * Gets a workflow run action. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String workflowName, String runName, String actionName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName), serviceCallback); + } + + /** + * Gets a workflow run action. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowRunActionInner object + */ + public Observable getAsync(String resourceGroupName, String workflowName, String runName, String actionName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName).map(new Func1, WorkflowRunActionInner>() { + @Override + public WorkflowRunActionInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets a workflow run action. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowRunActionInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String workflowName, String runName, String actionName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (actionName == null) { + throw new IllegalArgumentException("Parameter actionName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, workflowName, runName, actionName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Lists a workflow run expression trace. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the List<ExpressionRootInner> object if successful. + */ + public List listExpressionTraces(String resourceGroupName, String workflowName, String runName, String actionName) { + return listExpressionTracesWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName).toBlocking().single().body(); + } + + /** + * Lists a workflow run expression trace. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listExpressionTracesAsync(String resourceGroupName, String workflowName, String runName, String actionName, final ServiceCallback> serviceCallback) { + return ServiceFuture.fromResponse(listExpressionTracesWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName), serviceCallback); + } + + /** + * Lists a workflow run expression trace. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<ExpressionRootInner> object + */ + public Observable> listExpressionTracesAsync(String resourceGroupName, String workflowName, String runName, String actionName) { + return listExpressionTracesWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName).map(new Func1>, List>() { + @Override + public List call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Lists a workflow run expression trace. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param actionName The workflow action name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the List<ExpressionRootInner> object + */ + public Observable>> listExpressionTracesWithServiceResponseAsync(String resourceGroupName, String workflowName, String runName, String actionName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (actionName == null) { + throw new IllegalArgumentException("Parameter actionName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.listExpressionTraces(this.client.subscriptionId(), resourceGroupName, workflowName, runName, actionName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listExpressionTracesDelegate(response); + List items = null; + if (result.body() != null) { + items = result.body().items(); + } + ServiceResponse> clientResponse = new ServiceResponse>(items, result.response()); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listExpressionTracesDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of workflow run actions. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowRunActionInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow run actions. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow run actions. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowRunActionInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow run actions. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowRunActionInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow run actions. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowRunActionInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunInner.java new file mode 100644 index 000000000000..e74fed61b709 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunInner.java @@ -0,0 +1,250 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowStatus; +import com.microsoft.azure.management.logic.v2019_05_01.Correlation; +import com.microsoft.azure.management.logic.v2019_05_01.ResourceReference; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunTrigger; +import java.util.Map; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowOutputParameter; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.azure.SubResource; + +/** + * The workflow run. + */ +@JsonFlatten +public class WorkflowRunInner extends SubResource { + /** + * Gets the wait end time. + */ + @JsonProperty(value = "properties.waitEndTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime waitEndTime; + + /** + * Gets the start time. + */ + @JsonProperty(value = "properties.startTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime startTime; + + /** + * Gets the end time. + */ + @JsonProperty(value = "properties.endTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime endTime; + + /** + * Gets the status. Possible values include: 'NotSpecified', 'Paused', + * 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', + * 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + */ + @JsonProperty(value = "properties.status", access = JsonProperty.Access.WRITE_ONLY) + private WorkflowStatus status; + + /** + * Gets the code. + */ + @JsonProperty(value = "properties.code", access = JsonProperty.Access.WRITE_ONLY) + private String code; + + /** + * Gets the error. + */ + @JsonProperty(value = "properties.error", access = JsonProperty.Access.WRITE_ONLY) + private Object error; + + /** + * Gets the correlation id. + */ + @JsonProperty(value = "properties.correlationId", access = JsonProperty.Access.WRITE_ONLY) + private String correlationId; + + /** + * The run correlation. + */ + @JsonProperty(value = "properties.correlation") + private Correlation correlation; + + /** + * Gets the reference to workflow version. + */ + @JsonProperty(value = "properties.workflow", access = JsonProperty.Access.WRITE_ONLY) + private ResourceReference workflow; + + /** + * Gets the fired trigger. + */ + @JsonProperty(value = "properties.trigger", access = JsonProperty.Access.WRITE_ONLY) + private WorkflowRunTrigger trigger; + + /** + * Gets the outputs. + */ + @JsonProperty(value = "properties.outputs", access = JsonProperty.Access.WRITE_ONLY) + private Map outputs; + + /** + * Gets the response of the flow run. + */ + @JsonProperty(value = "properties.response", access = JsonProperty.Access.WRITE_ONLY) + private WorkflowRunTrigger response; + + /** + * Gets the workflow run name. + */ + @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY) + private String name; + + /** + * Gets the workflow run type. + */ + @JsonProperty(value = "type", access = JsonProperty.Access.WRITE_ONLY) + private String type; + + /** + * Get gets the wait end time. + * + * @return the waitEndTime value + */ + public DateTime waitEndTime() { + return this.waitEndTime; + } + + /** + * Get gets the start time. + * + * @return the startTime value + */ + public DateTime startTime() { + return this.startTime; + } + + /** + * Get gets the end time. + * + * @return the endTime value + */ + public DateTime endTime() { + return this.endTime; + } + + /** + * Get gets the status. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @return the status value + */ + public WorkflowStatus status() { + return this.status; + } + + /** + * Get gets the code. + * + * @return the code value + */ + public String code() { + return this.code; + } + + /** + * Get gets the error. + * + * @return the error value + */ + public Object error() { + return this.error; + } + + /** + * Get gets the correlation id. + * + * @return the correlationId value + */ + public String correlationId() { + return this.correlationId; + } + + /** + * Get the run correlation. + * + * @return the correlation value + */ + public Correlation correlation() { + return this.correlation; + } + + /** + * Set the run correlation. + * + * @param correlation the correlation value to set + * @return the WorkflowRunInner object itself. + */ + public WorkflowRunInner withCorrelation(Correlation correlation) { + this.correlation = correlation; + return this; + } + + /** + * Get gets the reference to workflow version. + * + * @return the workflow value + */ + public ResourceReference workflow() { + return this.workflow; + } + + /** + * Get gets the fired trigger. + * + * @return the trigger value + */ + public WorkflowRunTrigger trigger() { + return this.trigger; + } + + /** + * Get gets the outputs. + * + * @return the outputs value + */ + public Map outputs() { + return this.outputs; + } + + /** + * Get gets the response of the flow run. + * + * @return the response value + */ + public WorkflowRunTrigger response() { + return this.response; + } + + /** + * Get gets the workflow run name. + * + * @return the name value + */ + public String name() { + return this.name; + } + + /** + * Get gets the workflow run type. + * + * @return the type value + */ + public String type() { + return this.type; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunOperationsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunOperationsImpl.java new file mode 100644 index 000000000000..d9b1bbf4f383 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunOperationsImpl.java @@ -0,0 +1,50 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunOperations; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.management.logic.v2019_05_01.RunWorkflowWorkflowRun; + +class WorkflowRunOperationsImpl extends WrapperImpl implements WorkflowRunOperations { + private final LogicManager manager; + + WorkflowRunOperationsImpl(LogicManager manager) { + super(manager.inner().workflowRunOperations()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + private RunWorkflowWorkflowRunImpl wrapModel(WorkflowRunInner inner) { + return new RunWorkflowWorkflowRunImpl(inner, manager()); + } + + @Override + public Observable getAsync(String resourceGroupName, String workflowName, String runName, String operationId) { + WorkflowRunOperationsInner client = this.inner(); + return client.getAsync(resourceGroupName, workflowName, runName, operationId) + .flatMap(new Func1>() { + @Override + public Observable call(WorkflowRunInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((RunWorkflowWorkflowRun)wrapModel(inner)); + } + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunOperationsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunOperationsInner.java new file mode 100644 index 000000000000..39cc5d93ac75 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunOperationsInner.java @@ -0,0 +1,160 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.Query; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in WorkflowRunOperations. + */ +public class WorkflowRunOperationsInner { + /** The Retrofit service to perform REST calls. */ + private WorkflowRunOperationsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of WorkflowRunOperationsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public WorkflowRunOperationsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(WorkflowRunOperationsService.class); + this.client = client; + } + + /** + * The interface defining all the services for WorkflowRunOperations to be + * used by Retrofit to perform actually REST calls. + */ + interface WorkflowRunOperationsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunOperations get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/operations/{operationId}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Path("operationId") String operationId, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets an operation for a run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param operationId The workflow operation id. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowRunInner object if successful. + */ + public WorkflowRunInner get(String resourceGroupName, String workflowName, String runName, String operationId) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName, operationId).toBlocking().single().body(); + } + + /** + * Gets an operation for a run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param operationId The workflow operation id. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String workflowName, String runName, String operationId, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, workflowName, runName, operationId), serviceCallback); + } + + /** + * Gets an operation for a run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param operationId The workflow operation id. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowRunInner object + */ + public Observable getAsync(String resourceGroupName, String workflowName, String runName, String operationId) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName, operationId).map(new Func1, WorkflowRunInner>() { + @Override + public WorkflowRunInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets an operation for a run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param operationId The workflow operation id. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowRunInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String workflowName, String runName, String operationId) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (operationId == null) { + throw new IllegalArgumentException("Parameter operationId is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, workflowName, runName, operationId, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunsImpl.java new file mode 100644 index 000000000000..50c24511e866 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunsImpl.java @@ -0,0 +1,76 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRuns; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import rx.Completable; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowWorkflowRun; + +class WorkflowRunsImpl extends WrapperImpl implements WorkflowRuns { + private final LogicManager manager; + + WorkflowRunsImpl(LogicManager manager) { + super(manager.inner().workflowRuns()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + private WorkflowWorkflowRunImpl wrapModel(WorkflowRunInner inner) { + return new WorkflowWorkflowRunImpl(inner, manager()); + } + + @Override + public Completable cancelAsync(String resourceGroupName, String workflowName, String runName) { + WorkflowRunsInner client = this.inner(); + return client.cancelAsync(resourceGroupName, workflowName, runName).toCompletable(); + } + + @Override + public Observable listAsync(final String resourceGroupName, final String workflowName) { + WorkflowRunsInner client = this.inner(); + return client.listAsync(resourceGroupName, workflowName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public WorkflowWorkflowRun call(WorkflowRunInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String workflowName, String runName) { + WorkflowRunsInner client = this.inner(); + return client.getAsync(resourceGroupName, workflowName, runName) + .flatMap(new Func1>() { + @Override + public Observable call(WorkflowRunInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((WorkflowWorkflowRun)wrapModel(inner)); + } + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunsInner.java new file mode 100644 index 000000000000..2fb3af4a273c --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowRunsInner.java @@ -0,0 +1,626 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in WorkflowRuns. + */ +public class WorkflowRunsInner { + /** The Retrofit service to perform REST calls. */ + private WorkflowRunsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of WorkflowRunsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public WorkflowRunsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(WorkflowRunsService.class); + this.client = client; + } + + /** + * The interface defining all the services for WorkflowRuns to be + * used by Retrofit to perform actually REST calls. + */ + interface WorkflowRunsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRuns list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Query("$filter") String filter, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRuns get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRuns cancel" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/runs/{runName}/cancel") + Observable> cancel(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("runName") String runName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowRuns listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of workflow runs. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowRunInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String workflowName) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, workflowName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow runs. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String workflowName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, workflowName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow runs. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowRunInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String workflowName) { + return listWithServiceResponseAsync(resourceGroupName, workflowName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow runs. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowRunInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String workflowName) { + return listSinglePageAsync(resourceGroupName, workflowName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow runs. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowRunInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String workflowName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + final String filter = null; + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of workflow runs. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: Status, StartTime, and ClientTrackingId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowRunInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String workflowName, final Integer top, final String filter) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, workflowName, top, filter).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow runs. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: Status, StartTime, and ClientTrackingId. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String workflowName, final Integer top, final String filter, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, workflowName, top, filter), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow runs. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: Status, StartTime, and ClientTrackingId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowRunInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String workflowName, final Integer top, final String filter) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, top, filter) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow runs. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: Status, StartTime, and ClientTrackingId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowRunInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String workflowName, final Integer top, final String filter) { + return listSinglePageAsync(resourceGroupName, workflowName, top, filter) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow runs. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param workflowName The workflow name. + ServiceResponse> * @param top The number of items to be included in the result. + ServiceResponse> * @param filter The filter to apply on the operation. Options for filters include: Status, StartTime, and ClientTrackingId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowRunInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String workflowName, final Integer top, final String filter) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a workflow run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowRunInner object if successful. + */ + public WorkflowRunInner get(String resourceGroupName, String workflowName, String runName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName).toBlocking().single().body(); + } + + /** + * Gets a workflow run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String workflowName, String runName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, workflowName, runName), serviceCallback); + } + + /** + * Gets a workflow run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowRunInner object + */ + public Observable getAsync(String resourceGroupName, String workflowName, String runName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, runName).map(new Func1, WorkflowRunInner>() { + @Override + public WorkflowRunInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets a workflow run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowRunInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String workflowName, String runName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, workflowName, runName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Cancels a workflow run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void cancel(String resourceGroupName, String workflowName, String runName) { + cancelWithServiceResponseAsync(resourceGroupName, workflowName, runName).toBlocking().single().body(); + } + + /** + * Cancels a workflow run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture cancelAsync(String resourceGroupName, String workflowName, String runName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(cancelWithServiceResponseAsync(resourceGroupName, workflowName, runName), serviceCallback); + } + + /** + * Cancels a workflow run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable cancelAsync(String resourceGroupName, String workflowName, String runName) { + return cancelWithServiceResponseAsync(resourceGroupName, workflowName, runName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Cancels a workflow run. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param runName The workflow run name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> cancelWithServiceResponseAsync(String resourceGroupName, String workflowName, String runName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (runName == null) { + throw new IllegalArgumentException("Parameter runName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.cancel(this.client.subscriptionId(), resourceGroupName, workflowName, runName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = cancelDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse cancelDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of workflow runs. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowRunInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow runs. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow runs. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowRunInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow runs. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowRunInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow runs. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowRunInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerCallbackUrlImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerCallbackUrlImpl.java new file mode 100644 index 000000000000..4fbc1319a2a5 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerCallbackUrlImpl.java @@ -0,0 +1,58 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerListCallbackUrlQueries; +import java.util.List; + +class WorkflowTriggerCallbackUrlImpl extends WrapperImpl implements WorkflowTriggerCallbackUrl { + private final LogicManager manager; + WorkflowTriggerCallbackUrlImpl(WorkflowTriggerCallbackUrlInner inner, LogicManager manager) { + super(inner); + this.manager = manager; + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public String basePath() { + return this.inner().basePath(); + } + + @Override + public String method() { + return this.inner().method(); + } + + @Override + public WorkflowTriggerListCallbackUrlQueries queries() { + return this.inner().queries(); + } + + @Override + public String relativePath() { + return this.inner().relativePath(); + } + + @Override + public List relativePathParameters() { + return this.inner().relativePathParameters(); + } + + @Override + public String value() { + return this.inner().value(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerCallbackUrlInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerCallbackUrlInner.java new file mode 100644 index 000000000000..d23e8b5c15a2 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerCallbackUrlInner.java @@ -0,0 +1,131 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import java.util.List; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerListCallbackUrlQueries; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The workflow trigger callback URL. + */ +public class WorkflowTriggerCallbackUrlInner { + /** + * Gets the workflow trigger callback URL. + */ + @JsonProperty(value = "value", access = JsonProperty.Access.WRITE_ONLY) + private String value; + + /** + * Gets the workflow trigger callback URL HTTP method. + */ + @JsonProperty(value = "method", access = JsonProperty.Access.WRITE_ONLY) + private String method; + + /** + * Gets the workflow trigger callback URL base path. + */ + @JsonProperty(value = "basePath", access = JsonProperty.Access.WRITE_ONLY) + private String basePath; + + /** + * Gets the workflow trigger callback URL relative path. + */ + @JsonProperty(value = "relativePath", access = JsonProperty.Access.WRITE_ONLY) + private String relativePath; + + /** + * Gets the workflow trigger callback URL relative path parameters. + */ + @JsonProperty(value = "relativePathParameters") + private List relativePathParameters; + + /** + * Gets the workflow trigger callback URL query parameters. + */ + @JsonProperty(value = "queries") + private WorkflowTriggerListCallbackUrlQueries queries; + + /** + * Get gets the workflow trigger callback URL. + * + * @return the value value + */ + public String value() { + return this.value; + } + + /** + * Get gets the workflow trigger callback URL HTTP method. + * + * @return the method value + */ + public String method() { + return this.method; + } + + /** + * Get gets the workflow trigger callback URL base path. + * + * @return the basePath value + */ + public String basePath() { + return this.basePath; + } + + /** + * Get gets the workflow trigger callback URL relative path. + * + * @return the relativePath value + */ + public String relativePath() { + return this.relativePath; + } + + /** + * Get gets the workflow trigger callback URL relative path parameters. + * + * @return the relativePathParameters value + */ + public List relativePathParameters() { + return this.relativePathParameters; + } + + /** + * Set gets the workflow trigger callback URL relative path parameters. + * + * @param relativePathParameters the relativePathParameters value to set + * @return the WorkflowTriggerCallbackUrlInner object itself. + */ + public WorkflowTriggerCallbackUrlInner withRelativePathParameters(List relativePathParameters) { + this.relativePathParameters = relativePathParameters; + return this; + } + + /** + * Get gets the workflow trigger callback URL query parameters. + * + * @return the queries value + */ + public WorkflowTriggerListCallbackUrlQueries queries() { + return this.queries; + } + + /** + * Set gets the workflow trigger callback URL query parameters. + * + * @param queries the queries value to set + * @return the WorkflowTriggerCallbackUrlInner object itself. + */ + public WorkflowTriggerCallbackUrlInner withQueries(WorkflowTriggerListCallbackUrlQueries queries) { + this.queries = queries; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerHistoriesImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerHistoriesImpl.java new file mode 100644 index 000000000000..0bdb88ac942f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerHistoriesImpl.java @@ -0,0 +1,76 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerHistories; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import rx.Completable; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerHistory; + +class WorkflowTriggerHistoriesImpl extends WrapperImpl implements WorkflowTriggerHistories { + private final LogicManager manager; + + WorkflowTriggerHistoriesImpl(LogicManager manager) { + super(manager.inner().workflowTriggerHistories()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + private WorkflowTriggerHistoryImpl wrapModel(WorkflowTriggerHistoryInner inner) { + return new WorkflowTriggerHistoryImpl(inner, manager()); + } + + @Override + public Completable resubmitAsync(String resourceGroupName, String workflowName, String triggerName, String historyName) { + WorkflowTriggerHistoriesInner client = this.inner(); + return client.resubmitAsync(resourceGroupName, workflowName, triggerName, historyName).toCompletable(); + } + + @Override + public Observable listAsync(final String resourceGroupName, final String workflowName, final String triggerName) { + WorkflowTriggerHistoriesInner client = this.inner(); + return client.listAsync(resourceGroupName, workflowName, triggerName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public WorkflowTriggerHistory call(WorkflowTriggerHistoryInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String workflowName, String triggerName, String historyName) { + WorkflowTriggerHistoriesInner client = this.inner(); + return client.getAsync(resourceGroupName, workflowName, triggerName, historyName) + .flatMap(new Func1>() { + @Override + public Observable call(WorkflowTriggerHistoryInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((WorkflowTriggerHistory)wrapModel(inner)); + } + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerHistoriesInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerHistoriesInner.java new file mode 100644 index 000000000000..e306afaf53ff --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerHistoriesInner.java @@ -0,0 +1,656 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in WorkflowTriggerHistories. + */ +public class WorkflowTriggerHistoriesInner { + /** The Retrofit service to perform REST calls. */ + private WorkflowTriggerHistoriesService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of WorkflowTriggerHistoriesInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public WorkflowTriggerHistoriesInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(WorkflowTriggerHistoriesService.class); + this.client = client; + } + + /** + * The interface defining all the services for WorkflowTriggerHistories to be + * used by Retrofit to perform actually REST calls. + */ + interface WorkflowTriggerHistoriesService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerHistories list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/triggers/{triggerName}/histories") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("triggerName") String triggerName, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Query("$filter") String filter, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerHistories get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/triggers/{triggerName}/histories/{historyName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("triggerName") String triggerName, @Path("historyName") String historyName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerHistories resubmit" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/triggers/{triggerName}/histories/{historyName}/resubmit") + Observable> resubmit(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("triggerName") String triggerName, @Path("historyName") String historyName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerHistories listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of workflow trigger histories. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowTriggerHistoryInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String workflowName, final String triggerName) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, workflowName, triggerName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow trigger histories. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String workflowName, final String triggerName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, workflowName, triggerName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow trigger histories. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowTriggerHistoryInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String workflowName, final String triggerName) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, triggerName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow trigger histories. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowTriggerHistoryInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String workflowName, final String triggerName) { + return listSinglePageAsync(resourceGroupName, workflowName, triggerName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow trigger histories. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowTriggerHistoryInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String workflowName, final String triggerName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (triggerName == null) { + throw new IllegalArgumentException("Parameter triggerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + final String filter = null; + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, triggerName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of workflow trigger histories. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: Status, StartTime, and ClientTrackingId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowTriggerHistoryInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String workflowName, final String triggerName, final Integer top, final String filter) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, workflowName, triggerName, top, filter).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow trigger histories. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: Status, StartTime, and ClientTrackingId. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String workflowName, final String triggerName, final Integer top, final String filter, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, workflowName, triggerName, top, filter), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow trigger histories. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: Status, StartTime, and ClientTrackingId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowTriggerHistoryInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String workflowName, final String triggerName, final Integer top, final String filter) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, triggerName, top, filter) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow trigger histories. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: Status, StartTime, and ClientTrackingId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowTriggerHistoryInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String workflowName, final String triggerName, final Integer top, final String filter) { + return listSinglePageAsync(resourceGroupName, workflowName, triggerName, top, filter) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow trigger histories. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param workflowName The workflow name. + ServiceResponse> * @param triggerName The workflow trigger name. + ServiceResponse> * @param top The number of items to be included in the result. + ServiceResponse> * @param filter The filter to apply on the operation. Options for filters include: Status, StartTime, and ClientTrackingId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowTriggerHistoryInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String workflowName, final String triggerName, final Integer top, final String filter) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (triggerName == null) { + throw new IllegalArgumentException("Parameter triggerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, triggerName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a workflow trigger history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param historyName The workflow trigger history name. Corresponds to the run name for triggers that resulted in a run. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowTriggerHistoryInner object if successful. + */ + public WorkflowTriggerHistoryInner get(String resourceGroupName, String workflowName, String triggerName, String historyName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, triggerName, historyName).toBlocking().single().body(); + } + + /** + * Gets a workflow trigger history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param historyName The workflow trigger history name. Corresponds to the run name for triggers that resulted in a run. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String workflowName, String triggerName, String historyName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, workflowName, triggerName, historyName), serviceCallback); + } + + /** + * Gets a workflow trigger history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param historyName The workflow trigger history name. Corresponds to the run name for triggers that resulted in a run. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerHistoryInner object + */ + public Observable getAsync(String resourceGroupName, String workflowName, String triggerName, String historyName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, triggerName, historyName).map(new Func1, WorkflowTriggerHistoryInner>() { + @Override + public WorkflowTriggerHistoryInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets a workflow trigger history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param historyName The workflow trigger history name. Corresponds to the run name for triggers that resulted in a run. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerHistoryInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String workflowName, String triggerName, String historyName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (triggerName == null) { + throw new IllegalArgumentException("Parameter triggerName is required and cannot be null."); + } + if (historyName == null) { + throw new IllegalArgumentException("Parameter historyName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, workflowName, triggerName, historyName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Resubmits a workflow run based on the trigger history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param historyName The workflow trigger history name. Corresponds to the run name for triggers that resulted in a run. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void resubmit(String resourceGroupName, String workflowName, String triggerName, String historyName) { + resubmitWithServiceResponseAsync(resourceGroupName, workflowName, triggerName, historyName).toBlocking().single().body(); + } + + /** + * Resubmits a workflow run based on the trigger history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param historyName The workflow trigger history name. Corresponds to the run name for triggers that resulted in a run. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture resubmitAsync(String resourceGroupName, String workflowName, String triggerName, String historyName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(resubmitWithServiceResponseAsync(resourceGroupName, workflowName, triggerName, historyName), serviceCallback); + } + + /** + * Resubmits a workflow run based on the trigger history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param historyName The workflow trigger history name. Corresponds to the run name for triggers that resulted in a run. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable resubmitAsync(String resourceGroupName, String workflowName, String triggerName, String historyName) { + return resubmitWithServiceResponseAsync(resourceGroupName, workflowName, triggerName, historyName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Resubmits a workflow run based on the trigger history. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param historyName The workflow trigger history name. Corresponds to the run name for triggers that resulted in a run. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> resubmitWithServiceResponseAsync(String resourceGroupName, String workflowName, String triggerName, String historyName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (triggerName == null) { + throw new IllegalArgumentException("Parameter triggerName is required and cannot be null."); + } + if (historyName == null) { + throw new IllegalArgumentException("Parameter historyName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.resubmit(this.client.subscriptionId(), resourceGroupName, workflowName, triggerName, historyName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = resubmitDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse resubmitDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(202, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of workflow trigger histories. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowTriggerHistoryInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow trigger histories. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow trigger histories. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowTriggerHistoryInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow trigger histories. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowTriggerHistoryInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow trigger histories. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowTriggerHistoryInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerHistoryImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerHistoryImpl.java new file mode 100644 index 000000000000..dfcc523e34e8 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerHistoryImpl.java @@ -0,0 +1,125 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerHistory; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.Correlation; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.ContentLink; +import com.microsoft.azure.management.logic.v2019_05_01.ResourceReference; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowStatus; + +class WorkflowTriggerHistoryImpl extends IndexableRefreshableWrapperImpl implements WorkflowTriggerHistory { + private final LogicManager manager; + private String resourceGroupName; + private String workflowName; + private String triggerName; + private String historyName; + + WorkflowTriggerHistoryImpl(WorkflowTriggerHistoryInner inner, LogicManager manager) { + super(null, inner); + this.manager = manager; + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.workflowName = IdParsingUtils.getValueFromIdByName(inner.id(), "workflows"); + this.triggerName = IdParsingUtils.getValueFromIdByName(inner.id(), "triggers"); + this.historyName = IdParsingUtils.getValueFromIdByName(inner.id(), "histories"); + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + protected Observable getInnerAsync() { + WorkflowTriggerHistoriesInner client = this.manager().inner().workflowTriggerHistories(); + return client.getAsync(this.resourceGroupName, this.workflowName, this.triggerName, this.historyName); + } + + + + @Override + public String code() { + return this.inner().code(); + } + + @Override + public Correlation correlation() { + return this.inner().correlation(); + } + + @Override + public DateTime endTime() { + return this.inner().endTime(); + } + + @Override + public Object error() { + return this.inner().error(); + } + + @Override + public Boolean fired() { + return this.inner().fired(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public ContentLink inputsLink() { + return this.inner().inputsLink(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public ContentLink outputsLink() { + return this.inner().outputsLink(); + } + + @Override + public ResourceReference run() { + return this.inner().run(); + } + + @Override + public DateTime scheduledTime() { + return this.inner().scheduledTime(); + } + + @Override + public DateTime startTime() { + return this.inner().startTime(); + } + + @Override + public WorkflowStatus status() { + return this.inner().status(); + } + + @Override + public String trackingId() { + return this.inner().trackingId(); + } + + @Override + public String type() { + return this.inner().type(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerHistoryInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerHistoryInner.java new file mode 100644 index 000000000000..f3eef9f73437 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerHistoryInner.java @@ -0,0 +1,248 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowStatus; +import com.microsoft.azure.management.logic.v2019_05_01.Correlation; +import com.microsoft.azure.management.logic.v2019_05_01.ContentLink; +import com.microsoft.azure.management.logic.v2019_05_01.ResourceReference; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.azure.SubResource; + +/** + * The workflow trigger history. + */ +@JsonFlatten +public class WorkflowTriggerHistoryInner extends SubResource { + /** + * Gets the start time. + */ + @JsonProperty(value = "properties.startTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime startTime; + + /** + * Gets the end time. + */ + @JsonProperty(value = "properties.endTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime endTime; + + /** + * The scheduled time. + */ + @JsonProperty(value = "properties.scheduledTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime scheduledTime; + + /** + * Gets the status. Possible values include: 'NotSpecified', 'Paused', + * 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', + * 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + */ + @JsonProperty(value = "properties.status", access = JsonProperty.Access.WRITE_ONLY) + private WorkflowStatus status; + + /** + * Gets the code. + */ + @JsonProperty(value = "properties.code", access = JsonProperty.Access.WRITE_ONLY) + private String code; + + /** + * Gets the error. + */ + @JsonProperty(value = "properties.error", access = JsonProperty.Access.WRITE_ONLY) + private Object error; + + /** + * Gets the tracking id. + */ + @JsonProperty(value = "properties.trackingId", access = JsonProperty.Access.WRITE_ONLY) + private String trackingId; + + /** + * The run correlation. + */ + @JsonProperty(value = "properties.correlation") + private Correlation correlation; + + /** + * Gets the link to input parameters. + */ + @JsonProperty(value = "properties.inputsLink", access = JsonProperty.Access.WRITE_ONLY) + private ContentLink inputsLink; + + /** + * Gets the link to output parameters. + */ + @JsonProperty(value = "properties.outputsLink", access = JsonProperty.Access.WRITE_ONLY) + private ContentLink outputsLink; + + /** + * The value indicating whether trigger was fired. + */ + @JsonProperty(value = "properties.fired", access = JsonProperty.Access.WRITE_ONLY) + private Boolean fired; + + /** + * Gets the reference to workflow run. + */ + @JsonProperty(value = "properties.run", access = JsonProperty.Access.WRITE_ONLY) + private ResourceReference run; + + /** + * Gets the workflow trigger history name. + */ + @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY) + private String name; + + /** + * Gets the workflow trigger history type. + */ + @JsonProperty(value = "type", access = JsonProperty.Access.WRITE_ONLY) + private String type; + + /** + * Get gets the start time. + * + * @return the startTime value + */ + public DateTime startTime() { + return this.startTime; + } + + /** + * Get gets the end time. + * + * @return the endTime value + */ + public DateTime endTime() { + return this.endTime; + } + + /** + * Get the scheduled time. + * + * @return the scheduledTime value + */ + public DateTime scheduledTime() { + return this.scheduledTime; + } + + /** + * Get gets the status. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @return the status value + */ + public WorkflowStatus status() { + return this.status; + } + + /** + * Get gets the code. + * + * @return the code value + */ + public String code() { + return this.code; + } + + /** + * Get gets the error. + * + * @return the error value + */ + public Object error() { + return this.error; + } + + /** + * Get gets the tracking id. + * + * @return the trackingId value + */ + public String trackingId() { + return this.trackingId; + } + + /** + * Get the run correlation. + * + * @return the correlation value + */ + public Correlation correlation() { + return this.correlation; + } + + /** + * Set the run correlation. + * + * @param correlation the correlation value to set + * @return the WorkflowTriggerHistoryInner object itself. + */ + public WorkflowTriggerHistoryInner withCorrelation(Correlation correlation) { + this.correlation = correlation; + return this; + } + + /** + * Get gets the link to input parameters. + * + * @return the inputsLink value + */ + public ContentLink inputsLink() { + return this.inputsLink; + } + + /** + * Get gets the link to output parameters. + * + * @return the outputsLink value + */ + public ContentLink outputsLink() { + return this.outputsLink; + } + + /** + * Get the value indicating whether trigger was fired. + * + * @return the fired value + */ + public Boolean fired() { + return this.fired; + } + + /** + * Get gets the reference to workflow run. + * + * @return the run value + */ + public ResourceReference run() { + return this.run; + } + + /** + * Get gets the workflow trigger history name. + * + * @return the name value + */ + public String name() { + return this.name; + } + + /** + * Get gets the workflow trigger history type. + * + * @return the type value + */ + public String type() { + return this.type; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerImpl.java new file mode 100644 index 000000000000..18bc73149b7e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerImpl.java @@ -0,0 +1,109 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTrigger; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerProvisioningState; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerRecurrence; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowState; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowStatus; +import com.microsoft.azure.management.logic.v2019_05_01.ResourceReference; + +class WorkflowTriggerImpl extends IndexableRefreshableWrapperImpl implements WorkflowTrigger { + private final LogicManager manager; + private String resourceGroupName; + private String workflowName; + private String triggerName; + + WorkflowTriggerImpl(WorkflowTriggerInner inner, LogicManager manager) { + super(null, inner); + this.manager = manager; + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.workflowName = IdParsingUtils.getValueFromIdByName(inner.id(), "workflows"); + this.triggerName = IdParsingUtils.getValueFromIdByName(inner.id(), "triggers"); + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + protected Observable getInnerAsync() { + WorkflowTriggersInner client = this.manager().inner().workflowTriggers(); + return client.getAsync(this.resourceGroupName, this.workflowName, this.triggerName); + } + + + + @Override + public DateTime changedTime() { + return this.inner().changedTime(); + } + + @Override + public DateTime createdTime() { + return this.inner().createdTime(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public DateTime lastExecutionTime() { + return this.inner().lastExecutionTime(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public DateTime nextExecutionTime() { + return this.inner().nextExecutionTime(); + } + + @Override + public WorkflowTriggerProvisioningState provisioningState() { + return this.inner().provisioningState(); + } + + @Override + public WorkflowTriggerRecurrence recurrence() { + return this.inner().recurrence(); + } + + @Override + public WorkflowState state() { + return this.inner().state(); + } + + @Override + public WorkflowStatus status() { + return this.inner().status(); + } + + @Override + public String type() { + return this.inner().type(); + } + + @Override + public ResourceReference workflow() { + return this.inner().workflow(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerInner.java new file mode 100644 index 000000000000..72812a4ac46e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggerInner.java @@ -0,0 +1,198 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerProvisioningState; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowState; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowStatus; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerRecurrence; +import com.microsoft.azure.management.logic.v2019_05_01.ResourceReference; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.azure.SubResource; + +/** + * The workflow trigger. + */ +@JsonFlatten +public class WorkflowTriggerInner extends SubResource { + /** + * Gets the provisioning state. Possible values include: 'NotSpecified', + * 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', + * 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', + * 'Registering', 'Registered', 'Unregistering', 'Unregistered', + * 'Completed'. + */ + @JsonProperty(value = "properties.provisioningState", access = JsonProperty.Access.WRITE_ONLY) + private WorkflowTriggerProvisioningState provisioningState; + + /** + * Gets the created time. + */ + @JsonProperty(value = "properties.createdTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime createdTime; + + /** + * Gets the changed time. + */ + @JsonProperty(value = "properties.changedTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime changedTime; + + /** + * Gets the state. Possible values include: 'NotSpecified', 'Completed', + * 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + */ + @JsonProperty(value = "properties.state", access = JsonProperty.Access.WRITE_ONLY) + private WorkflowState state; + + /** + * Gets the status. Possible values include: 'NotSpecified', 'Paused', + * 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', + * 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + */ + @JsonProperty(value = "properties.status", access = JsonProperty.Access.WRITE_ONLY) + private WorkflowStatus status; + + /** + * Gets the last execution time. + */ + @JsonProperty(value = "properties.lastExecutionTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime lastExecutionTime; + + /** + * Gets the next execution time. + */ + @JsonProperty(value = "properties.nextExecutionTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime nextExecutionTime; + + /** + * Gets the workflow trigger recurrence. + */ + @JsonProperty(value = "properties.recurrence", access = JsonProperty.Access.WRITE_ONLY) + private WorkflowTriggerRecurrence recurrence; + + /** + * Gets the reference to workflow. + */ + @JsonProperty(value = "properties.workflow", access = JsonProperty.Access.WRITE_ONLY) + private ResourceReference workflow; + + /** + * Gets the workflow trigger name. + */ + @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY) + private String name; + + /** + * Gets the workflow trigger type. + */ + @JsonProperty(value = "type", access = JsonProperty.Access.WRITE_ONLY) + private String type; + + /** + * Get gets the provisioning state. Possible values include: 'NotSpecified', 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', 'Registering', 'Registered', 'Unregistering', 'Unregistered', 'Completed'. + * + * @return the provisioningState value + */ + public WorkflowTriggerProvisioningState provisioningState() { + return this.provisioningState; + } + + /** + * Get gets the created time. + * + * @return the createdTime value + */ + public DateTime createdTime() { + return this.createdTime; + } + + /** + * Get gets the changed time. + * + * @return the changedTime value + */ + public DateTime changedTime() { + return this.changedTime; + } + + /** + * Get gets the state. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + * + * @return the state value + */ + public WorkflowState state() { + return this.state; + } + + /** + * Get gets the status. Possible values include: 'NotSpecified', 'Paused', 'Running', 'Waiting', 'Succeeded', 'Skipped', 'Suspended', 'Cancelled', 'Failed', 'Faulted', 'TimedOut', 'Aborted', 'Ignored'. + * + * @return the status value + */ + public WorkflowStatus status() { + return this.status; + } + + /** + * Get gets the last execution time. + * + * @return the lastExecutionTime value + */ + public DateTime lastExecutionTime() { + return this.lastExecutionTime; + } + + /** + * Get gets the next execution time. + * + * @return the nextExecutionTime value + */ + public DateTime nextExecutionTime() { + return this.nextExecutionTime; + } + + /** + * Get gets the workflow trigger recurrence. + * + * @return the recurrence value + */ + public WorkflowTriggerRecurrence recurrence() { + return this.recurrence; + } + + /** + * Get gets the reference to workflow. + * + * @return the workflow value + */ + public ResourceReference workflow() { + return this.workflow; + } + + /** + * Get gets the workflow trigger name. + * + * @return the name value + */ + public String name() { + return this.name; + } + + /** + * Get gets the workflow trigger type. + * + * @return the type value + */ + public String type() { + return this.type; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggersImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggersImpl.java new file mode 100644 index 000000000000..43feb865e1a9 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggersImpl.java @@ -0,0 +1,123 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * abc + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggers; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTrigger; +import com.microsoft.azure.Page; +import rx.Completable; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerReference; +import com.microsoft.azure.management.logic.v2019_05_01.JsonSchema; + +class WorkflowTriggersImpl extends WrapperImpl implements WorkflowTriggers { + private final LogicManager manager; + + WorkflowTriggersImpl(LogicManager manager) { + super(manager.inner().workflowTriggers()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + private WorkflowTriggerImpl wrapWorkflowTriggerModel(WorkflowTriggerInner inner) { + return new WorkflowTriggerImpl(inner, manager()); + } + + private Observable getWorkflowTriggerInnerUsingWorkflowTriggersInnerAsync(String id) { + String resourceGroupName = IdParsingUtils.getValueFromIdByName(id, "resourceGroups"); + String workflowName = IdParsingUtils.getValueFromIdByName(id, "workflows"); + String triggerName = IdParsingUtils.getValueFromIdByName(id, "triggers"); + WorkflowTriggersInner client = this.inner(); + return client.getAsync(resourceGroupName, workflowName, triggerName); + } + + @Override + public Observable getAsync(String resourceGroupName, String workflowName, String triggerName) { + WorkflowTriggersInner client = this.inner(); + return client.getAsync(resourceGroupName, workflowName, triggerName) + .flatMap(new Func1>() { + @Override + public Observable call(WorkflowTriggerInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((WorkflowTrigger)wrapWorkflowTriggerModel(inner)); + } + } + }); + } + + @Override + public Observable listAsync(final String resourceGroupName, final String workflowName) { + WorkflowTriggersInner client = this.inner(); + return client.listAsync(resourceGroupName, workflowName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public WorkflowTrigger call(WorkflowTriggerInner inner) { + return wrapWorkflowTriggerModel(inner); + } + }); + } + + @Override + public Completable resetAsync(String resourceGroupName, String workflowName, String triggerName) { + WorkflowTriggersInner client = this.inner(); + return client.resetAsync(resourceGroupName, workflowName, triggerName).toCompletable(); + } + + @Override + public Completable runAsync(String resourceGroupName, String workflowName, String triggerName) { + WorkflowTriggersInner client = this.inner(); + return client.runAsync(resourceGroupName, workflowName, triggerName).toCompletable(); + } + + @Override + public Completable setStateAsync(String resourceGroupName, String workflowName, String triggerName, WorkflowTriggerReference source) { + WorkflowTriggersInner client = this.inner(); + return client.setStateAsync(resourceGroupName, workflowName, triggerName, source).toCompletable(); + } + + @Override + public Observable listCallbackUrlAsync(String resourceGroupName, String workflowName, String triggerName) { + WorkflowTriggersInner client = this.inner(); + return client.listCallbackUrlAsync(resourceGroupName, workflowName, triggerName) + .map(new Func1() { + @Override + public WorkflowTriggerCallbackUrl call(WorkflowTriggerCallbackUrlInner inner) { + return new WorkflowTriggerCallbackUrlImpl(inner, manager()); + } + }); + } + + @Override + public Observable getSchemaJsonAsync(String resourceGroupName, String workflowName, String triggerName) { + WorkflowTriggersInner client = this.inner(); + return client.getSchemaJsonAsync(resourceGroupName, workflowName, triggerName) + .map(new Func1() { + @Override + public JsonSchema call(JsonSchemaInner inner) { + return new JsonSchemaImpl(inner, manager()); + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggersInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggersInner.java new file mode 100644 index 000000000000..56759050214f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowTriggersInner.java @@ -0,0 +1,1027 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.management.logic.v2019_05_01.SetTriggerStateActionDefinition; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerReference; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import com.microsoft.rest.Validator; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.Body; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in WorkflowTriggers. + */ +public class WorkflowTriggersInner { + /** The Retrofit service to perform REST calls. */ + private WorkflowTriggersService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of WorkflowTriggersInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public WorkflowTriggersInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(WorkflowTriggersService.class); + this.client = client; + } + + /** + * The interface defining all the services for WorkflowTriggers to be + * used by Retrofit to perform actually REST calls. + */ + interface WorkflowTriggersService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggers list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/triggers") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Query("$filter") String filter, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggers get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/triggers/{triggerName}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("triggerName") String triggerName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggers reset" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/triggers/{triggerName}/reset") + Observable> reset(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("triggerName") String triggerName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggers run" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/triggers/{triggerName}/run") + Observable> run(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("triggerName") String triggerName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggers getSchemaJson" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/triggers/{triggerName}/schemas/json") + Observable> getSchemaJson(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("triggerName") String triggerName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggers setState" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/triggers/{triggerName}/setState") + Observable> setState(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("triggerName") String triggerName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Body SetTriggerStateActionDefinition setState, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggers listCallbackUrl" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/triggers/{triggerName}/listCallbackUrl") + Observable> listCallbackUrl(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("triggerName") String triggerName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggers listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of workflow triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowTriggerInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String workflowName) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, workflowName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String workflowName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, workflowName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowTriggerInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String workflowName) { + return listWithServiceResponseAsync(resourceGroupName, workflowName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowTriggerInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String workflowName) { + return listSinglePageAsync(resourceGroupName, workflowName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowTriggerInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String workflowName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + final String filter = null; + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of workflow triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowTriggerInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String workflowName, final Integer top, final String filter) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, workflowName, top, filter).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String workflowName, final Integer top, final String filter, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, workflowName, top, filter), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowTriggerInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String workflowName, final Integer top, final String filter) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, top, filter) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowTriggerInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String workflowName, final Integer top, final String filter) { + return listSinglePageAsync(resourceGroupName, workflowName, top, filter) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow triggers. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param workflowName The workflow name. + ServiceResponse> * @param top The number of items to be included in the result. + ServiceResponse> * @param filter The filter to apply on the operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowTriggerInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String workflowName, final Integer top, final String filter) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowTriggerInner object if successful. + */ + public WorkflowTriggerInner get(String resourceGroupName, String workflowName, String triggerName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, triggerName).toBlocking().single().body(); + } + + /** + * Gets a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String workflowName, String triggerName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, workflowName, triggerName), serviceCallback); + } + + /** + * Gets a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerInner object + */ + public Observable getAsync(String resourceGroupName, String workflowName, String triggerName) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, triggerName).map(new Func1, WorkflowTriggerInner>() { + @Override + public WorkflowTriggerInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String workflowName, String triggerName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (triggerName == null) { + throw new IllegalArgumentException("Parameter triggerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, workflowName, triggerName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Resets a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void reset(String resourceGroupName, String workflowName, String triggerName) { + resetWithServiceResponseAsync(resourceGroupName, workflowName, triggerName).toBlocking().single().body(); + } + + /** + * Resets a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture resetAsync(String resourceGroupName, String workflowName, String triggerName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(resetWithServiceResponseAsync(resourceGroupName, workflowName, triggerName), serviceCallback); + } + + /** + * Resets a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable resetAsync(String resourceGroupName, String workflowName, String triggerName) { + return resetWithServiceResponseAsync(resourceGroupName, workflowName, triggerName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Resets a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> resetWithServiceResponseAsync(String resourceGroupName, String workflowName, String triggerName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (triggerName == null) { + throw new IllegalArgumentException("Parameter triggerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.reset(this.client.subscriptionId(), resourceGroupName, workflowName, triggerName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = resetDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse resetDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Runs a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void run(String resourceGroupName, String workflowName, String triggerName) { + runWithServiceResponseAsync(resourceGroupName, workflowName, triggerName).toBlocking().single().body(); + } + + /** + * Runs a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture runAsync(String resourceGroupName, String workflowName, String triggerName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(runWithServiceResponseAsync(resourceGroupName, workflowName, triggerName), serviceCallback); + } + + /** + * Runs a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable runAsync(String resourceGroupName, String workflowName, String triggerName) { + return runWithServiceResponseAsync(resourceGroupName, workflowName, triggerName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Runs a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> runWithServiceResponseAsync(String resourceGroupName, String workflowName, String triggerName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (triggerName == null) { + throw new IllegalArgumentException("Parameter triggerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.run(this.client.subscriptionId(), resourceGroupName, workflowName, triggerName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = runDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse runDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(202, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Get the trigger schema as JSON. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the JsonSchemaInner object if successful. + */ + public JsonSchemaInner getSchemaJson(String resourceGroupName, String workflowName, String triggerName) { + return getSchemaJsonWithServiceResponseAsync(resourceGroupName, workflowName, triggerName).toBlocking().single().body(); + } + + /** + * Get the trigger schema as JSON. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getSchemaJsonAsync(String resourceGroupName, String workflowName, String triggerName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getSchemaJsonWithServiceResponseAsync(resourceGroupName, workflowName, triggerName), serviceCallback); + } + + /** + * Get the trigger schema as JSON. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the JsonSchemaInner object + */ + public Observable getSchemaJsonAsync(String resourceGroupName, String workflowName, String triggerName) { + return getSchemaJsonWithServiceResponseAsync(resourceGroupName, workflowName, triggerName).map(new Func1, JsonSchemaInner>() { + @Override + public JsonSchemaInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get the trigger schema as JSON. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the JsonSchemaInner object + */ + public Observable> getSchemaJsonWithServiceResponseAsync(String resourceGroupName, String workflowName, String triggerName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (triggerName == null) { + throw new IllegalArgumentException("Parameter triggerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.getSchemaJson(this.client.subscriptionId(), resourceGroupName, workflowName, triggerName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getSchemaJsonDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getSchemaJsonDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Sets the state of a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param source The source. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void setState(String resourceGroupName, String workflowName, String triggerName, WorkflowTriggerReference source) { + setStateWithServiceResponseAsync(resourceGroupName, workflowName, triggerName, source).toBlocking().single().body(); + } + + /** + * Sets the state of a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param source The source. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture setStateAsync(String resourceGroupName, String workflowName, String triggerName, WorkflowTriggerReference source, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(setStateWithServiceResponseAsync(resourceGroupName, workflowName, triggerName, source), serviceCallback); + } + + /** + * Sets the state of a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param source The source. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable setStateAsync(String resourceGroupName, String workflowName, String triggerName, WorkflowTriggerReference source) { + return setStateWithServiceResponseAsync(resourceGroupName, workflowName, triggerName, source).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Sets the state of a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param source The source. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> setStateWithServiceResponseAsync(String resourceGroupName, String workflowName, String triggerName, WorkflowTriggerReference source) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (triggerName == null) { + throw new IllegalArgumentException("Parameter triggerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (source == null) { + throw new IllegalArgumentException("Parameter source is required and cannot be null."); + } + Validator.validate(source); + SetTriggerStateActionDefinition setState = new SetTriggerStateActionDefinition(); + setState.withSource(source); + return service.setState(this.client.subscriptionId(), resourceGroupName, workflowName, triggerName, this.client.apiVersion(), this.client.acceptLanguage(), setState, this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = setStateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse setStateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Get the callback URL for a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowTriggerCallbackUrlInner object if successful. + */ + public WorkflowTriggerCallbackUrlInner listCallbackUrl(String resourceGroupName, String workflowName, String triggerName) { + return listCallbackUrlWithServiceResponseAsync(resourceGroupName, workflowName, triggerName).toBlocking().single().body(); + } + + /** + * Get the callback URL for a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture listCallbackUrlAsync(String resourceGroupName, String workflowName, String triggerName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listCallbackUrlWithServiceResponseAsync(resourceGroupName, workflowName, triggerName), serviceCallback); + } + + /** + * Get the callback URL for a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable listCallbackUrlAsync(String resourceGroupName, String workflowName, String triggerName) { + return listCallbackUrlWithServiceResponseAsync(resourceGroupName, workflowName, triggerName).map(new Func1, WorkflowTriggerCallbackUrlInner>() { + @Override + public WorkflowTriggerCallbackUrlInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get the callback URL for a workflow trigger. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable> listCallbackUrlWithServiceResponseAsync(String resourceGroupName, String workflowName, String triggerName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (triggerName == null) { + throw new IllegalArgumentException("Parameter triggerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.listCallbackUrl(this.client.subscriptionId(), resourceGroupName, workflowName, triggerName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = listCallbackUrlDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse listCallbackUrlDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of workflow triggers. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowTriggerInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow triggers. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow triggers. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowTriggerInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow triggers. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowTriggerInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow triggers. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowTriggerInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionImpl.java new file mode 100644 index 000000000000..e2b667e40a22 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionImpl.java @@ -0,0 +1,137 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowVersion; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.FlowAccessControlConfiguration; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.FlowEndpointsConfiguration; +import com.microsoft.azure.management.logic.v2019_05_01.ResourceReference; +import java.util.Map; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowParameter; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowProvisioningState; +import com.microsoft.azure.management.logic.v2019_05_01.Sku; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowState; + +class WorkflowVersionImpl extends IndexableRefreshableWrapperImpl implements WorkflowVersion { + private final LogicManager manager; + private String resourceGroupName; + private String workflowName; + private String versionId; + + WorkflowVersionImpl(WorkflowVersionInner inner, LogicManager manager) { + super(null, inner); + this.manager = manager; + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.workflowName = IdParsingUtils.getValueFromIdByName(inner.id(), "workflows"); + this.versionId = IdParsingUtils.getValueFromIdByName(inner.id(), "versions"); + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + protected Observable getInnerAsync() { + WorkflowVersionsInner client = this.manager().inner().workflowVersions(); + return client.getAsync(this.resourceGroupName, this.workflowName, this.versionId); + } + + + + @Override + public FlowAccessControlConfiguration accessControl() { + return this.inner().accessControl(); + } + + @Override + public String accessEndpoint() { + return this.inner().accessEndpoint(); + } + + @Override + public DateTime changedTime() { + return this.inner().changedTime(); + } + + @Override + public DateTime createdTime() { + return this.inner().createdTime(); + } + + @Override + public Object definition() { + return this.inner().definition(); + } + + @Override + public FlowEndpointsConfiguration endpointsConfiguration() { + return this.inner().endpointsConfiguration(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public ResourceReference integrationAccount() { + return this.inner().integrationAccount(); + } + + @Override + public String location() { + return this.inner().location(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public Map parameters() { + return this.inner().parameters(); + } + + @Override + public WorkflowProvisioningState provisioningState() { + return this.inner().provisioningState(); + } + + @Override + public Sku sku() { + return this.inner().sku(); + } + + @Override + public WorkflowState state() { + return this.inner().state(); + } + + @Override + public Map tags() { + return this.inner().getTags(); + } + + @Override + public String type() { + return this.inner().type(); + } + + @Override + public String version() { + return this.inner().version(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionInner.java new file mode 100644 index 000000000000..708fd8abd86e --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionInner.java @@ -0,0 +1,282 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowProvisioningState; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowState; +import com.microsoft.azure.management.logic.v2019_05_01.FlowEndpointsConfiguration; +import com.microsoft.azure.management.logic.v2019_05_01.FlowAccessControlConfiguration; +import com.microsoft.azure.management.logic.v2019_05_01.Sku; +import com.microsoft.azure.management.logic.v2019_05_01.ResourceReference; +import java.util.Map; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowParameter; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.serializer.JsonFlatten; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The workflow version. + */ +@JsonFlatten +@SkipParentValidation +public class WorkflowVersionInner extends Resource { + /** + * The provisioning state. Possible values include: 'NotSpecified', + * 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', + * 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', + * 'Registering', 'Registered', 'Unregistering', 'Unregistered', + * 'Completed', 'Renewing', 'Pending', 'Waiting', 'InProgress'. + */ + @JsonProperty(value = "properties.provisioningState", access = JsonProperty.Access.WRITE_ONLY) + private WorkflowProvisioningState provisioningState; + + /** + * Gets the created time. + */ + @JsonProperty(value = "properties.createdTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime createdTime; + + /** + * Gets the changed time. + */ + @JsonProperty(value = "properties.changedTime", access = JsonProperty.Access.WRITE_ONLY) + private DateTime changedTime; + + /** + * The state. Possible values include: 'NotSpecified', 'Completed', + * 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + */ + @JsonProperty(value = "properties.state") + private WorkflowState state; + + /** + * Gets the version. + */ + @JsonProperty(value = "properties.version", access = JsonProperty.Access.WRITE_ONLY) + private String version; + + /** + * Gets the access endpoint. + */ + @JsonProperty(value = "properties.accessEndpoint", access = JsonProperty.Access.WRITE_ONLY) + private String accessEndpoint; + + /** + * The endpoints configuration. + */ + @JsonProperty(value = "properties.endpointsConfiguration") + private FlowEndpointsConfiguration endpointsConfiguration; + + /** + * The access control configuration. + */ + @JsonProperty(value = "properties.accessControl") + private FlowAccessControlConfiguration accessControl; + + /** + * The sku. + */ + @JsonProperty(value = "properties.sku", access = JsonProperty.Access.WRITE_ONLY) + private Sku sku; + + /** + * The integration account. + */ + @JsonProperty(value = "properties.integrationAccount") + private ResourceReference integrationAccount; + + /** + * The definition. + */ + @JsonProperty(value = "properties.definition") + private Object definition; + + /** + * The parameters. + */ + @JsonProperty(value = "properties.parameters") + private Map parameters; + + /** + * Get the provisioning state. Possible values include: 'NotSpecified', 'Accepted', 'Running', 'Ready', 'Creating', 'Created', 'Deleting', 'Deleted', 'Canceled', 'Failed', 'Succeeded', 'Moving', 'Updating', 'Registering', 'Registered', 'Unregistering', 'Unregistered', 'Completed', 'Renewing', 'Pending', 'Waiting', 'InProgress'. + * + * @return the provisioningState value + */ + public WorkflowProvisioningState provisioningState() { + return this.provisioningState; + } + + /** + * Get gets the created time. + * + * @return the createdTime value + */ + public DateTime createdTime() { + return this.createdTime; + } + + /** + * Get gets the changed time. + * + * @return the changedTime value + */ + public DateTime changedTime() { + return this.changedTime; + } + + /** + * Get the state. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + * + * @return the state value + */ + public WorkflowState state() { + return this.state; + } + + /** + * Set the state. Possible values include: 'NotSpecified', 'Completed', 'Enabled', 'Disabled', 'Deleted', 'Suspended'. + * + * @param state the state value to set + * @return the WorkflowVersionInner object itself. + */ + public WorkflowVersionInner withState(WorkflowState state) { + this.state = state; + return this; + } + + /** + * Get gets the version. + * + * @return the version value + */ + public String version() { + return this.version; + } + + /** + * Get gets the access endpoint. + * + * @return the accessEndpoint value + */ + public String accessEndpoint() { + return this.accessEndpoint; + } + + /** + * Get the endpoints configuration. + * + * @return the endpointsConfiguration value + */ + public FlowEndpointsConfiguration endpointsConfiguration() { + return this.endpointsConfiguration; + } + + /** + * Set the endpoints configuration. + * + * @param endpointsConfiguration the endpointsConfiguration value to set + * @return the WorkflowVersionInner object itself. + */ + public WorkflowVersionInner withEndpointsConfiguration(FlowEndpointsConfiguration endpointsConfiguration) { + this.endpointsConfiguration = endpointsConfiguration; + return this; + } + + /** + * Get the access control configuration. + * + * @return the accessControl value + */ + public FlowAccessControlConfiguration accessControl() { + return this.accessControl; + } + + /** + * Set the access control configuration. + * + * @param accessControl the accessControl value to set + * @return the WorkflowVersionInner object itself. + */ + public WorkflowVersionInner withAccessControl(FlowAccessControlConfiguration accessControl) { + this.accessControl = accessControl; + return this; + } + + /** + * Get the sku. + * + * @return the sku value + */ + public Sku sku() { + return this.sku; + } + + /** + * Get the integration account. + * + * @return the integrationAccount value + */ + public ResourceReference integrationAccount() { + return this.integrationAccount; + } + + /** + * Set the integration account. + * + * @param integrationAccount the integrationAccount value to set + * @return the WorkflowVersionInner object itself. + */ + public WorkflowVersionInner withIntegrationAccount(ResourceReference integrationAccount) { + this.integrationAccount = integrationAccount; + return this; + } + + /** + * Get the definition. + * + * @return the definition value + */ + public Object definition() { + return this.definition; + } + + /** + * Set the definition. + * + * @param definition the definition value to set + * @return the WorkflowVersionInner object itself. + */ + public WorkflowVersionInner withDefinition(Object definition) { + this.definition = definition; + return this; + } + + /** + * Get the parameters. + * + * @return the parameters value + */ + public Map parameters() { + return this.parameters; + } + + /** + * Set the parameters. + * + * @param parameters the parameters value to set + * @return the WorkflowVersionInner object itself. + */ + public WorkflowVersionInner withParameters(Map parameters) { + this.parameters = parameters; + return this; + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionTriggersImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionTriggersImpl.java new file mode 100644 index 000000000000..f11ed2226360 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionTriggersImpl.java @@ -0,0 +1,42 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * abc + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowVersionTriggers; +import rx.functions.Func1; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerCallbackUrl; + +class WorkflowVersionTriggersImpl extends WrapperImpl implements WorkflowVersionTriggers { + private final LogicManager manager; + + WorkflowVersionTriggersImpl(LogicManager manager) { + super(manager.inner().workflowVersionTriggers()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + @Override + public Observable listCallbackUrlAsync(String resourceGroupName, String workflowName, String versionId, String triggerName) { + WorkflowVersionTriggersInner client = this.inner(); + return client.listCallbackUrlAsync(resourceGroupName, workflowName, versionId, triggerName) + .map(new Func1() { + @Override + public WorkflowTriggerCallbackUrl call(WorkflowTriggerCallbackUrlInner inner) { + return new WorkflowTriggerCallbackUrlImpl(inner, manager()); + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionTriggersInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionTriggersInner.java new file mode 100644 index 000000000000..ab2d45ef7d31 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionTriggersInner.java @@ -0,0 +1,262 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.management.logic.v2019_05_01.GetCallbackUrlParameters; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import com.microsoft.rest.Validator; +import java.io.IOException; +import okhttp3.ResponseBody; +import retrofit2.http.Body; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.Query; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in WorkflowVersionTriggers. + */ +public class WorkflowVersionTriggersInner { + /** The Retrofit service to perform REST calls. */ + private WorkflowVersionTriggersService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of WorkflowVersionTriggersInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public WorkflowVersionTriggersInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(WorkflowVersionTriggersService.class); + this.client = client; + } + + /** + * The interface defining all the services for WorkflowVersionTriggers to be + * used by Retrofit to perform actually REST calls. + */ + interface WorkflowVersionTriggersService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowVersionTriggers listCallbackUrl" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/versions/{versionId}/triggers/{triggerName}/listCallbackUrl") + Observable> listCallbackUrl(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("versionId") String versionId, @Path("triggerName") String triggerName, @Body GetCallbackUrlParameters parameters, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Get the callback url for a trigger of a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowTriggerCallbackUrlInner object if successful. + */ + public WorkflowTriggerCallbackUrlInner listCallbackUrl(String resourceGroupName, String workflowName, String versionId, String triggerName) { + return listCallbackUrlWithServiceResponseAsync(resourceGroupName, workflowName, versionId, triggerName).toBlocking().single().body(); + } + + /** + * Get the callback url for a trigger of a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @param triggerName The workflow trigger name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture listCallbackUrlAsync(String resourceGroupName, String workflowName, String versionId, String triggerName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listCallbackUrlWithServiceResponseAsync(resourceGroupName, workflowName, versionId, triggerName), serviceCallback); + } + + /** + * Get the callback url for a trigger of a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable listCallbackUrlAsync(String resourceGroupName, String workflowName, String versionId, String triggerName) { + return listCallbackUrlWithServiceResponseAsync(resourceGroupName, workflowName, versionId, triggerName).map(new Func1, WorkflowTriggerCallbackUrlInner>() { + @Override + public WorkflowTriggerCallbackUrlInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get the callback url for a trigger of a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @param triggerName The workflow trigger name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable> listCallbackUrlWithServiceResponseAsync(String resourceGroupName, String workflowName, String versionId, String triggerName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (versionId == null) { + throw new IllegalArgumentException("Parameter versionId is required and cannot be null."); + } + if (triggerName == null) { + throw new IllegalArgumentException("Parameter triggerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final GetCallbackUrlParameters parameters = null; + return service.listCallbackUrl(this.client.subscriptionId(), resourceGroupName, workflowName, versionId, triggerName, parameters, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = listCallbackUrlDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Get the callback url for a trigger of a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @param triggerName The workflow trigger name. + * @param parameters The callback URL parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowTriggerCallbackUrlInner object if successful. + */ + public WorkflowTriggerCallbackUrlInner listCallbackUrl(String resourceGroupName, String workflowName, String versionId, String triggerName, GetCallbackUrlParameters parameters) { + return listCallbackUrlWithServiceResponseAsync(resourceGroupName, workflowName, versionId, triggerName, parameters).toBlocking().single().body(); + } + + /** + * Get the callback url for a trigger of a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @param triggerName The workflow trigger name. + * @param parameters The callback URL parameters. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture listCallbackUrlAsync(String resourceGroupName, String workflowName, String versionId, String triggerName, GetCallbackUrlParameters parameters, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listCallbackUrlWithServiceResponseAsync(resourceGroupName, workflowName, versionId, triggerName, parameters), serviceCallback); + } + + /** + * Get the callback url for a trigger of a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @param triggerName The workflow trigger name. + * @param parameters The callback URL parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable listCallbackUrlAsync(String resourceGroupName, String workflowName, String versionId, String triggerName, GetCallbackUrlParameters parameters) { + return listCallbackUrlWithServiceResponseAsync(resourceGroupName, workflowName, versionId, triggerName, parameters).map(new Func1, WorkflowTriggerCallbackUrlInner>() { + @Override + public WorkflowTriggerCallbackUrlInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get the callback url for a trigger of a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @param triggerName The workflow trigger name. + * @param parameters The callback URL parameters. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable> listCallbackUrlWithServiceResponseAsync(String resourceGroupName, String workflowName, String versionId, String triggerName, GetCallbackUrlParameters parameters) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (versionId == null) { + throw new IllegalArgumentException("Parameter versionId is required and cannot be null."); + } + if (triggerName == null) { + throw new IllegalArgumentException("Parameter triggerName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + Validator.validate(parameters); + return service.listCallbackUrl(this.client.subscriptionId(), resourceGroupName, workflowName, versionId, triggerName, parameters, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = listCallbackUrlDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse listCallbackUrlDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionsImpl.java new file mode 100644 index 000000000000..e1e4432a129f --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionsImpl.java @@ -0,0 +1,69 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowVersions; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowVersion; + +class WorkflowVersionsImpl extends WrapperImpl implements WorkflowVersions { + private final LogicManager manager; + + WorkflowVersionsImpl(LogicManager manager) { + super(manager.inner().workflowVersions()); + this.manager = manager; + } + + public LogicManager manager() { + return this.manager; + } + + private WorkflowVersionImpl wrapModel(WorkflowVersionInner inner) { + return new WorkflowVersionImpl(inner, manager()); + } + + @Override + public Observable listAsync(final String resourceGroupName, final String workflowName) { + WorkflowVersionsInner client = this.inner(); + return client.listAsync(resourceGroupName, workflowName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public WorkflowVersion call(WorkflowVersionInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public Observable getAsync(String resourceGroupName, String workflowName, String versionId) { + WorkflowVersionsInner client = this.inner(); + return client.getAsync(resourceGroupName, workflowName, versionId) + .flatMap(new Func1>() { + @Override + public Observable call(WorkflowVersionInner inner) { + if (inner == null) { + return Observable.empty(); + } else { + return Observable.just((WorkflowVersion)wrapModel(inner)); + } + } + }); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionsInner.java new file mode 100644 index 000000000000..ebdf0665a591 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowVersionsInner.java @@ -0,0 +1,523 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.Path; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in WorkflowVersions. + */ +public class WorkflowVersionsInner { + /** The Retrofit service to perform REST calls. */ + private WorkflowVersionsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of WorkflowVersionsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public WorkflowVersionsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(WorkflowVersionsService.class); + this.client = client; + } + + /** + * The interface defining all the services for WorkflowVersions to be + * used by Retrofit to perform actually REST calls. + */ + interface WorkflowVersionsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowVersions list" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/versions") + Observable> list(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowVersions get" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/versions/{versionId}") + Observable> get(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Path("versionId") String versionId, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.WorkflowVersions listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of workflow versions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowVersionInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String workflowName) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, workflowName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow versions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String workflowName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, workflowName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow versions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowVersionInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String workflowName) { + return listWithServiceResponseAsync(resourceGroupName, workflowName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow versions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowVersionInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String workflowName) { + return listSinglePageAsync(resourceGroupName, workflowName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow versions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowVersionInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String workflowName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), top, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of workflow versions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowVersionInner> object if successful. + */ + public PagedList list(final String resourceGroupName, final String workflowName, final Integer top) { + ServiceResponse> response = listSinglePageAsync(resourceGroupName, workflowName, top).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow versions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param top The number of items to be included in the result. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final String resourceGroupName, final String workflowName, final Integer top, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(resourceGroupName, workflowName, top), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow versions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowVersionInner> object + */ + public Observable> listAsync(final String resourceGroupName, final String workflowName, final Integer top) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, top) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow versions. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowVersionInner> object + */ + public Observable>> listWithServiceResponseAsync(final String resourceGroupName, final String workflowName, final Integer top) { + return listSinglePageAsync(resourceGroupName, workflowName, top) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow versions. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param workflowName The workflow name. + ServiceResponse> * @param top The number of items to be included in the result. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowVersionInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final String resourceGroupName, final String workflowName, final Integer top) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), top, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowVersionInner object if successful. + */ + public WorkflowVersionInner get(String resourceGroupName, String workflowName, String versionId) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, versionId).toBlocking().single().body(); + } + + /** + * Gets a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getAsync(String resourceGroupName, String workflowName, String versionId, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getWithServiceResponseAsync(resourceGroupName, workflowName, versionId), serviceCallback); + } + + /** + * Gets a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowVersionInner object + */ + public Observable getAsync(String resourceGroupName, String workflowName, String versionId) { + return getWithServiceResponseAsync(resourceGroupName, workflowName, versionId).map(new Func1, WorkflowVersionInner>() { + @Override + public WorkflowVersionInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets a workflow version. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param versionId The workflow versionId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowVersionInner object + */ + public Observable> getWithServiceResponseAsync(String resourceGroupName, String workflowName, String versionId) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (versionId == null) { + throw new IllegalArgumentException("Parameter versionId is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.get(this.client.subscriptionId(), resourceGroupName, workflowName, versionId, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of workflow versions. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowVersionInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflow versions. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflow versions. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowVersionInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflow versions. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowVersionInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflow versions. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowVersionInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowWorkflowRunImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowWorkflowRunImpl.java new file mode 100644 index 000000000000..02017a583a7d --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowWorkflowRunImpl.java @@ -0,0 +1,125 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowWorkflowRun; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2019_05_01.Correlation; +import org.joda.time.DateTime; +import java.util.Map; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowOutputParameter; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowRunTrigger; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowStatus; +import com.microsoft.azure.management.logic.v2019_05_01.ResourceReference; + +class WorkflowWorkflowRunImpl extends IndexableRefreshableWrapperImpl implements WorkflowWorkflowRun { + private final LogicManager manager; + private String resourceGroupName; + private String workflowName; + private String runName; + + WorkflowWorkflowRunImpl(WorkflowRunInner inner, LogicManager manager) { + super(null, inner); + this.manager = manager; + // set resource ancestor and positional variables + this.resourceGroupName = IdParsingUtils.getValueFromIdByName(inner.id(), "resourceGroups"); + this.workflowName = IdParsingUtils.getValueFromIdByName(inner.id(), "workflows"); + this.runName = IdParsingUtils.getValueFromIdByName(inner.id(), "runs"); + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + protected Observable getInnerAsync() { + WorkflowRunsInner client = this.manager().inner().workflowRuns(); + return client.getAsync(this.resourceGroupName, this.workflowName, this.runName); + } + + + + @Override + public String code() { + return this.inner().code(); + } + + @Override + public Correlation correlation() { + return this.inner().correlation(); + } + + @Override + public String correlationId() { + return this.inner().correlationId(); + } + + @Override + public DateTime endTime() { + return this.inner().endTime(); + } + + @Override + public Object error() { + return this.inner().error(); + } + + @Override + public String id() { + return this.inner().id(); + } + + @Override + public String name() { + return this.inner().name(); + } + + @Override + public Map outputs() { + return this.inner().outputs(); + } + + @Override + public WorkflowRunTrigger response() { + return this.inner().response(); + } + + @Override + public DateTime startTime() { + return this.inner().startTime(); + } + + @Override + public WorkflowStatus status() { + return this.inner().status(); + } + + @Override + public WorkflowRunTrigger trigger() { + return this.inner().trigger(); + } + + @Override + public String type() { + return this.inner().type(); + } + + @Override + public DateTime waitEndTime() { + return this.inner().waitEndTime(); + } + + @Override + public ResourceReference workflow() { + return this.inner().workflow(); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowsImpl.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowsImpl.java new file mode 100644 index 000000000000..b538947d96f4 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowsImpl.java @@ -0,0 +1,200 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * def + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.resources.collection.implementation.GroupableResourcesCoreImpl; +import com.microsoft.azure.management.logic.v2019_05_01.Workflows; +import com.microsoft.azure.management.logic.v2019_05_01.Workflow; +import rx.Observable; +import rx.Completable; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; +import com.microsoft.azure.arm.resources.ResourceUtilsCore; +import com.microsoft.azure.arm.utils.RXMapper; +import rx.functions.Func1; +import com.microsoft.azure.PagedList; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2019_05_01.GetCallbackUrlParameters; + +class WorkflowsImpl extends GroupableResourcesCoreImpl implements Workflows { + protected WorkflowsImpl(LogicManager manager) { + super(manager.inner().workflows(), manager); + } + + @Override + protected Observable getInnerAsync(String resourceGroupName, String name) { + WorkflowsInner client = this.inner(); + return client.getByResourceGroupAsync(resourceGroupName, name); + } + + @Override + protected Completable deleteInnerAsync(String resourceGroupName, String name) { + WorkflowsInner client = this.inner(); + return client.deleteAsync(resourceGroupName, name).toCompletable(); + } + + @Override + public Observable deleteByIdsAsync(Collection ids) { + if (ids == null || ids.isEmpty()) { + return Observable.empty(); + } + Collection> observables = new ArrayList<>(); + for (String id : ids) { + final String resourceGroupName = ResourceUtilsCore.groupFromResourceId(id); + final String name = ResourceUtilsCore.nameFromResourceId(id); + Observable o = RXMapper.map(this.inner().deleteAsync(resourceGroupName, name), id); + observables.add(o); + } + return Observable.mergeDelayError(observables); + } + + @Override + public Observable deleteByIdsAsync(String...ids) { + return this.deleteByIdsAsync(new ArrayList(Arrays.asList(ids))); + } + + @Override + public void deleteByIds(Collection ids) { + if (ids != null && !ids.isEmpty()) { + this.deleteByIdsAsync(ids).toBlocking().last(); + } + } + + @Override + public void deleteByIds(String...ids) { + this.deleteByIds(new ArrayList(Arrays.asList(ids))); + } + + @Override + public PagedList listByResourceGroup(String resourceGroupName) { + WorkflowsInner client = this.inner(); + return this.wrapList(client.listByResourceGroup(resourceGroupName)); + } + + @Override + public Observable listByResourceGroupAsync(String resourceGroupName) { + WorkflowsInner client = this.inner(); + return client.listByResourceGroupAsync(resourceGroupName) + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public Workflow call(WorkflowInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public PagedList list() { + WorkflowsInner client = this.inner(); + return this.wrapList(client.list()); + } + + @Override + public Observable listAsync() { + WorkflowsInner client = this.inner(); + return client.listAsync() + .flatMapIterable(new Func1, Iterable>() { + @Override + public Iterable call(Page page) { + return page.items(); + } + }) + .map(new Func1() { + @Override + public Workflow call(WorkflowInner inner) { + return wrapModel(inner); + } + }); + } + + @Override + public WorkflowImpl define(String name) { + return wrapModel(name); + } + + @Override + public Completable disableAsync(String resourceGroupName, String workflowName) { + WorkflowsInner client = this.inner(); + return client.disableAsync(resourceGroupName, workflowName).toCompletable(); + } + + @Override + public Completable enableAsync(String resourceGroupName, String workflowName) { + WorkflowsInner client = this.inner(); + return client.enableAsync(resourceGroupName, workflowName).toCompletable(); + } + + @Override + public Observable generateUpgradedDefinitionAsync(String resourceGroupName, String workflowName) { + WorkflowsInner client = this.inner(); + return client.generateUpgradedDefinitionAsync(resourceGroupName, workflowName) + ;} + + @Override + public Observable listCallbackUrlAsync(String resourceGroupName, String workflowName, GetCallbackUrlParameters listCallbackUrl) { + WorkflowsInner client = this.inner(); + return client.listCallbackUrlAsync(resourceGroupName, workflowName, listCallbackUrl) + .map(new Func1() { + @Override + public WorkflowTriggerCallbackUrl call(WorkflowTriggerCallbackUrlInner inner) { + return new WorkflowTriggerCallbackUrlImpl(inner, manager()); + } + }); + } + + @Override + public Observable listSwaggerAsync(String resourceGroupName, String workflowName) { + WorkflowsInner client = this.inner(); + return client.listSwaggerAsync(resourceGroupName, workflowName) + ;} + + @Override + public Completable moveAsync(String resourceGroupName, String workflowName) { + WorkflowsInner client = this.inner(); + return client.moveAsync(resourceGroupName, workflowName).toCompletable(); + } + + @Override + public Completable regenerateAccessKeyAsync(String resourceGroupName, String workflowName) { + WorkflowsInner client = this.inner(); + return client.regenerateAccessKeyAsync(resourceGroupName, workflowName).toCompletable(); + } + + @Override + public Completable validateByResourceGroupAsync(String resourceGroupName, String workflowName, WorkflowInner validate) { + WorkflowsInner client = this.inner(); + return client.validateByResourceGroupAsync(resourceGroupName, workflowName, validate).toCompletable(); + } + + @Override + public Completable validateByLocationAsync(String resourceGroupName, String location, String workflowName, WorkflowInner validate) { + WorkflowsInner client = this.inner(); + return client.validateByLocationAsync(resourceGroupName, location, workflowName, validate).toCompletable(); + } + + @Override + protected WorkflowImpl wrapModel(WorkflowInner inner) { + return new WorkflowImpl(inner.name(), inner, manager()); + } + + @Override + protected WorkflowImpl wrapModel(String name) { + return new WorkflowImpl(name, new WorkflowInner(), this.manager()); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowsInner.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowsInner.java new file mode 100644 index 000000000000..ca144f2bedb1 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/WorkflowsInner.java @@ -0,0 +1,2383 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2019_05_01.implementation; + +import com.microsoft.azure.arm.collection.InnerSupportsGet; +import com.microsoft.azure.arm.collection.InnerSupportsDelete; +import com.microsoft.azure.arm.collection.InnerSupportsListing; +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2019_05_01.ErrorResponseException; +import com.microsoft.azure.management.logic.v2019_05_01.GenerateUpgradedDefinitionParameters; +import com.microsoft.azure.management.logic.v2019_05_01.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2019_05_01.KeyType; +import com.microsoft.azure.management.logic.v2019_05_01.RegenerateActionParameter; +import com.microsoft.azure.management.logic.v2019_05_01.WorkflowReference; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.ServiceCallback; +import com.microsoft.rest.ServiceFuture; +import com.microsoft.rest.ServiceResponse; +import com.microsoft.rest.Validator; +import java.io.IOException; +import java.util.List; +import okhttp3.ResponseBody; +import retrofit2.http.Body; +import retrofit2.http.GET; +import retrofit2.http.Header; +import retrofit2.http.Headers; +import retrofit2.http.HTTP; +import retrofit2.http.PATCH; +import retrofit2.http.Path; +import retrofit2.http.POST; +import retrofit2.http.PUT; +import retrofit2.http.Query; +import retrofit2.http.Url; +import retrofit2.Response; +import rx.functions.Func1; +import rx.Observable; + +/** + * An instance of this class provides access to all the operations defined + * in Workflows. + */ +public class WorkflowsInner implements InnerSupportsGet, InnerSupportsDelete, InnerSupportsListing { + /** The Retrofit service to perform REST calls. */ + private WorkflowsService service; + /** The service client containing this operation class. */ + private LogicManagementClientImpl client; + + /** + * Initializes an instance of WorkflowsInner. + * + * @param retrofit the Retrofit instance built from a Retrofit Builder. + * @param client the instance of the service client containing this operation class. + */ + public WorkflowsInner(Retrofit retrofit, LogicManagementClientImpl client) { + this.service = retrofit.create(WorkflowsService.class); + this.client = client; + } + + /** + * The interface defining all the services for Workflows to be + * used by Retrofit to perform actually REST calls. + */ + interface WorkflowsService { + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows list" }) + @GET("subscriptions/{subscriptionId}/providers/Microsoft.Logic/workflows") + Observable> list(@Path("subscriptionId") String subscriptionId, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Query("$filter") String filter, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows listByResourceGroup" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows") + Observable> listByResourceGroup(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Query("api-version") String apiVersion, @Query("$top") Integer top, @Query("$filter") String filter, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows getByResourceGroup" }) + @GET("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}") + Observable> getByResourceGroup(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows createOrUpdate" }) + @PUT("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}") + Observable> createOrUpdate(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Body WorkflowInner workflow, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows update" }) + @PATCH("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}") + Observable> update(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows delete" }) + @HTTP(path = "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}", method = "DELETE", hasBody = true) + Observable> delete(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows disable" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/disable") + Observable> disable(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows enable" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/enable") + Observable> enable(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows generateUpgradedDefinition" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/generateUpgradedDefinition") + Observable> generateUpgradedDefinition(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Body GenerateUpgradedDefinitionParameters parameters, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows listCallbackUrl" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/listCallbackUrl") + Observable> listCallbackUrl(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Body GetCallbackUrlParameters listCallbackUrl, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows listSwagger" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/listSwagger") + Observable> listSwagger(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows move" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/move") + Observable> move(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Body WorkflowReference move, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows beginMove" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/move") + Observable> beginMove(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Body WorkflowReference move, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows regenerateAccessKey" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/regenerateAccessKey") + Observable> regenerateAccessKey(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Body RegenerateActionParameter keyType, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows validateByResourceGroup" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/workflows/{workflowName}/validate") + Observable> validateByResourceGroup(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("workflowName") String workflowName, @Body WorkflowInner validate, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows validateByLocation" }) + @POST("subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Logic/locations/{location}/workflows/{workflowName}/validate") + Observable> validateByLocation(@Path("subscriptionId") String subscriptionId, @Path("resourceGroupName") String resourceGroupName, @Path("location") String location, @Path("workflowName") String workflowName, @Body WorkflowInner validate, @Query("api-version") String apiVersion, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows listNext" }) + @GET + Observable> listNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + @Headers({ "Content-Type: application/json; charset=utf-8", "x-ms-logging-context: com.microsoft.azure.management.logic.v2019_05_01.Workflows listByResourceGroupNext" }) + @GET + Observable> listByResourceGroupNext(@Url String nextUrl, @Header("accept-language") String acceptLanguage, @Header("User-Agent") String userAgent); + + } + + /** + * Gets a list of workflows by subscription. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowInner> object if successful. + */ + public PagedList list() { + ServiceResponse> response = listSinglePageAsync().toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflows by subscription. + * + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflows by subscription. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowInner> object + */ + public Observable> listAsync() { + return listWithServiceResponseAsync() + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflows by subscription. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowInner> object + */ + public Observable>> listWithServiceResponseAsync() { + return listSinglePageAsync() + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflows by subscription. + * + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync() { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + final String filter = null; + return service.list(this.client.subscriptionId(), this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of workflows by subscription. + * + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: State, Trigger, and ReferencedResourceId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowInner> object if successful. + */ + public PagedList list(final Integer top, final String filter) { + ServiceResponse> response = listSinglePageAsync(top, filter).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflows by subscription. + * + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: State, Trigger, and ReferencedResourceId. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listAsync(final Integer top, final String filter, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listSinglePageAsync(top, filter), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflows by subscription. + * + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: State, Trigger, and ReferencedResourceId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowInner> object + */ + public Observable> listAsync(final Integer top, final String filter) { + return listWithServiceResponseAsync(top, filter) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflows by subscription. + * + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: State, Trigger, and ReferencedResourceId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowInner> object + */ + public Observable>> listWithServiceResponseAsync(final Integer top, final String filter) { + return listSinglePageAsync(top, filter) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflows by subscription. + * + ServiceResponse> * @param top The number of items to be included in the result. + ServiceResponse> * @param filter The filter to apply on the operation. Options for filters include: State, Trigger, and ReferencedResourceId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listSinglePageAsync(final Integer top, final String filter) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.list(this.client.subscriptionId(), this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of workflows by resource group. + * + * @param resourceGroupName The resource group name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowInner> object if successful. + */ + public PagedList listByResourceGroup(final String resourceGroupName) { + ServiceResponse> response = listByResourceGroupSinglePageAsync(resourceGroupName).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflows by resource group. + * + * @param resourceGroupName The resource group name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listByResourceGroupAsync(final String resourceGroupName, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listByResourceGroupSinglePageAsync(resourceGroupName), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflows by resource group. + * + * @param resourceGroupName The resource group name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowInner> object + */ + public Observable> listByResourceGroupAsync(final String resourceGroupName) { + return listByResourceGroupWithServiceResponseAsync(resourceGroupName) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflows by resource group. + * + * @param resourceGroupName The resource group name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowInner> object + */ + public Observable>> listByResourceGroupWithServiceResponseAsync(final String resourceGroupName) { + return listByResourceGroupSinglePageAsync(resourceGroupName) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listByResourceGroupNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflows by resource group. + * + * @param resourceGroupName The resource group name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listByResourceGroupSinglePageAsync(final String resourceGroupName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final Integer top = null; + final String filter = null; + return service.listByResourceGroup(this.client.subscriptionId(), resourceGroupName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listByResourceGroupDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Gets a list of workflows by resource group. + * + * @param resourceGroupName The resource group name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: State, Trigger, and ReferencedResourceId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowInner> object if successful. + */ + public PagedList listByResourceGroup(final String resourceGroupName, final Integer top, final String filter) { + ServiceResponse> response = listByResourceGroupSinglePageAsync(resourceGroupName, top, filter).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflows by resource group. + * + * @param resourceGroupName The resource group name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: State, Trigger, and ReferencedResourceId. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listByResourceGroupAsync(final String resourceGroupName, final Integer top, final String filter, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listByResourceGroupSinglePageAsync(resourceGroupName, top, filter), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflows by resource group. + * + * @param resourceGroupName The resource group name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: State, Trigger, and ReferencedResourceId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowInner> object + */ + public Observable> listByResourceGroupAsync(final String resourceGroupName, final Integer top, final String filter) { + return listByResourceGroupWithServiceResponseAsync(resourceGroupName, top, filter) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflows by resource group. + * + * @param resourceGroupName The resource group name. + * @param top The number of items to be included in the result. + * @param filter The filter to apply on the operation. Options for filters include: State, Trigger, and ReferencedResourceId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowInner> object + */ + public Observable>> listByResourceGroupWithServiceResponseAsync(final String resourceGroupName, final Integer top, final String filter) { + return listByResourceGroupSinglePageAsync(resourceGroupName, top, filter) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listByResourceGroupNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflows by resource group. + * + ServiceResponse> * @param resourceGroupName The resource group name. + ServiceResponse> * @param top The number of items to be included in the result. + ServiceResponse> * @param filter The filter to apply on the operation. Options for filters include: State, Trigger, and ReferencedResourceId. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listByResourceGroupSinglePageAsync(final String resourceGroupName, final Integer top, final String filter) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.listByResourceGroup(this.client.subscriptionId(), resourceGroupName, this.client.apiVersion(), top, filter, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listByResourceGroupDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listByResourceGroupDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowInner object if successful. + */ + public WorkflowInner getByResourceGroup(String resourceGroupName, String workflowName) { + return getByResourceGroupWithServiceResponseAsync(resourceGroupName, workflowName).toBlocking().single().body(); + } + + /** + * Gets a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture getByResourceGroupAsync(String resourceGroupName, String workflowName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(getByResourceGroupWithServiceResponseAsync(resourceGroupName, workflowName), serviceCallback); + } + + /** + * Gets a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowInner object + */ + public Observable getByResourceGroupAsync(String resourceGroupName, String workflowName) { + return getByResourceGroupWithServiceResponseAsync(resourceGroupName, workflowName).map(new Func1, WorkflowInner>() { + @Override + public WorkflowInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowInner object + */ + public Observable> getByResourceGroupWithServiceResponseAsync(String resourceGroupName, String workflowName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.getByResourceGroup(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = getByResourceGroupDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse getByResourceGroupDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Creates or updates a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param workflow The workflow. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowInner object if successful. + */ + public WorkflowInner createOrUpdate(String resourceGroupName, String workflowName, WorkflowInner workflow) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, workflowName, workflow).toBlocking().single().body(); + } + + /** + * Creates or updates a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param workflow The workflow. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture createOrUpdateAsync(String resourceGroupName, String workflowName, WorkflowInner workflow, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(createOrUpdateWithServiceResponseAsync(resourceGroupName, workflowName, workflow), serviceCallback); + } + + /** + * Creates or updates a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param workflow The workflow. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowInner object + */ + public Observable createOrUpdateAsync(String resourceGroupName, String workflowName, WorkflowInner workflow) { + return createOrUpdateWithServiceResponseAsync(resourceGroupName, workflowName, workflow).map(new Func1, WorkflowInner>() { + @Override + public WorkflowInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Creates or updates a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param workflow The workflow. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowInner object + */ + public Observable> createOrUpdateWithServiceResponseAsync(String resourceGroupName, String workflowName, WorkflowInner workflow) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + if (workflow == null) { + throw new IllegalArgumentException("Parameter workflow is required and cannot be null."); + } + Validator.validate(workflow); + return service.createOrUpdate(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), workflow, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = createOrUpdateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse createOrUpdateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Updates a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowInner object if successful. + */ + public WorkflowInner update(String resourceGroupName, String workflowName) { + return updateWithServiceResponseAsync(resourceGroupName, workflowName).toBlocking().single().body(); + } + + /** + * Updates a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture updateAsync(String resourceGroupName, String workflowName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(updateWithServiceResponseAsync(resourceGroupName, workflowName), serviceCallback); + } + + /** + * Updates a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowInner object + */ + public Observable updateAsync(String resourceGroupName, String workflowName) { + return updateWithServiceResponseAsync(resourceGroupName, workflowName).map(new Func1, WorkflowInner>() { + @Override + public WorkflowInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Updates a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowInner object + */ + public Observable> updateWithServiceResponseAsync(String resourceGroupName, String workflowName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.update(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = updateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse updateDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Deletes a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void delete(String resourceGroupName, String workflowName) { + deleteWithServiceResponseAsync(resourceGroupName, workflowName).toBlocking().single().body(); + } + + /** + * Deletes a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture deleteAsync(String resourceGroupName, String workflowName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(deleteWithServiceResponseAsync(resourceGroupName, workflowName), serviceCallback); + } + + /** + * Deletes a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable deleteAsync(String resourceGroupName, String workflowName) { + return deleteWithServiceResponseAsync(resourceGroupName, workflowName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Deletes a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> deleteWithServiceResponseAsync(String resourceGroupName, String workflowName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.delete(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = deleteDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse deleteDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Disables a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void disable(String resourceGroupName, String workflowName) { + disableWithServiceResponseAsync(resourceGroupName, workflowName).toBlocking().single().body(); + } + + /** + * Disables a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture disableAsync(String resourceGroupName, String workflowName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(disableWithServiceResponseAsync(resourceGroupName, workflowName), serviceCallback); + } + + /** + * Disables a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable disableAsync(String resourceGroupName, String workflowName) { + return disableWithServiceResponseAsync(resourceGroupName, workflowName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Disables a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> disableWithServiceResponseAsync(String resourceGroupName, String workflowName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.disable(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = disableDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse disableDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Enables a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void enable(String resourceGroupName, String workflowName) { + enableWithServiceResponseAsync(resourceGroupName, workflowName).toBlocking().single().body(); + } + + /** + * Enables a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture enableAsync(String resourceGroupName, String workflowName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(enableWithServiceResponseAsync(resourceGroupName, workflowName), serviceCallback); + } + + /** + * Enables a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable enableAsync(String resourceGroupName, String workflowName) { + return enableWithServiceResponseAsync(resourceGroupName, workflowName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Enables a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> enableWithServiceResponseAsync(String resourceGroupName, String workflowName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.enable(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = enableDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse enableDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Generates the upgraded definition for a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the Object object if successful. + */ + public Object generateUpgradedDefinition(String resourceGroupName, String workflowName) { + return generateUpgradedDefinitionWithServiceResponseAsync(resourceGroupName, workflowName).toBlocking().single().body(); + } + + /** + * Generates the upgraded definition for a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture generateUpgradedDefinitionAsync(String resourceGroupName, String workflowName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(generateUpgradedDefinitionWithServiceResponseAsync(resourceGroupName, workflowName), serviceCallback); + } + + /** + * Generates the upgraded definition for a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the Object object + */ + public Observable generateUpgradedDefinitionAsync(String resourceGroupName, String workflowName) { + return generateUpgradedDefinitionWithServiceResponseAsync(resourceGroupName, workflowName).map(new Func1, Object>() { + @Override + public Object call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Generates the upgraded definition for a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the Object object + */ + public Observable> generateUpgradedDefinitionWithServiceResponseAsync(String resourceGroupName, String workflowName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final String targetSchemaVersion = null; + GenerateUpgradedDefinitionParameters parameters = new GenerateUpgradedDefinitionParameters(); + parameters.withTargetSchemaVersion(null); + return service.generateUpgradedDefinition(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), parameters, this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = generateUpgradedDefinitionDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Generates the upgraded definition for a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param targetSchemaVersion The target schema version. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the Object object if successful. + */ + public Object generateUpgradedDefinition(String resourceGroupName, String workflowName, String targetSchemaVersion) { + return generateUpgradedDefinitionWithServiceResponseAsync(resourceGroupName, workflowName, targetSchemaVersion).toBlocking().single().body(); + } + + /** + * Generates the upgraded definition for a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param targetSchemaVersion The target schema version. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture generateUpgradedDefinitionAsync(String resourceGroupName, String workflowName, String targetSchemaVersion, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(generateUpgradedDefinitionWithServiceResponseAsync(resourceGroupName, workflowName, targetSchemaVersion), serviceCallback); + } + + /** + * Generates the upgraded definition for a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param targetSchemaVersion The target schema version. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the Object object + */ + public Observable generateUpgradedDefinitionAsync(String resourceGroupName, String workflowName, String targetSchemaVersion) { + return generateUpgradedDefinitionWithServiceResponseAsync(resourceGroupName, workflowName, targetSchemaVersion).map(new Func1, Object>() { + @Override + public Object call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Generates the upgraded definition for a workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param targetSchemaVersion The target schema version. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the Object object + */ + public Observable> generateUpgradedDefinitionWithServiceResponseAsync(String resourceGroupName, String workflowName, String targetSchemaVersion) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + GenerateUpgradedDefinitionParameters parameters = new GenerateUpgradedDefinitionParameters(); + parameters.withTargetSchemaVersion(targetSchemaVersion); + return service.generateUpgradedDefinition(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), parameters, this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = generateUpgradedDefinitionDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse generateUpgradedDefinitionDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Get the workflow callback Url. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param listCallbackUrl Which callback url to list. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowTriggerCallbackUrlInner object if successful. + */ + public WorkflowTriggerCallbackUrlInner listCallbackUrl(String resourceGroupName, String workflowName, GetCallbackUrlParameters listCallbackUrl) { + return listCallbackUrlWithServiceResponseAsync(resourceGroupName, workflowName, listCallbackUrl).toBlocking().single().body(); + } + + /** + * Get the workflow callback Url. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param listCallbackUrl Which callback url to list. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture listCallbackUrlAsync(String resourceGroupName, String workflowName, GetCallbackUrlParameters listCallbackUrl, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listCallbackUrlWithServiceResponseAsync(resourceGroupName, workflowName, listCallbackUrl), serviceCallback); + } + + /** + * Get the workflow callback Url. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param listCallbackUrl Which callback url to list. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable listCallbackUrlAsync(String resourceGroupName, String workflowName, GetCallbackUrlParameters listCallbackUrl) { + return listCallbackUrlWithServiceResponseAsync(resourceGroupName, workflowName, listCallbackUrl).map(new Func1, WorkflowTriggerCallbackUrlInner>() { + @Override + public WorkflowTriggerCallbackUrlInner call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Get the workflow callback Url. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param listCallbackUrl Which callback url to list. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowTriggerCallbackUrlInner object + */ + public Observable> listCallbackUrlWithServiceResponseAsync(String resourceGroupName, String workflowName, GetCallbackUrlParameters listCallbackUrl) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (listCallbackUrl == null) { + throw new IllegalArgumentException("Parameter listCallbackUrl is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + Validator.validate(listCallbackUrl); + return service.listCallbackUrl(this.client.subscriptionId(), resourceGroupName, workflowName, listCallbackUrl, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = listCallbackUrlDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse listCallbackUrlDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets an OpenAPI definition for the workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the Object object if successful. + */ + public Object listSwagger(String resourceGroupName, String workflowName) { + return listSwaggerWithServiceResponseAsync(resourceGroupName, workflowName).toBlocking().single().body(); + } + + /** + * Gets an OpenAPI definition for the workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture listSwaggerAsync(String resourceGroupName, String workflowName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(listSwaggerWithServiceResponseAsync(resourceGroupName, workflowName), serviceCallback); + } + + /** + * Gets an OpenAPI definition for the workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the Object object + */ + public Observable listSwaggerAsync(String resourceGroupName, String workflowName) { + return listSwaggerWithServiceResponseAsync(resourceGroupName, workflowName).map(new Func1, Object>() { + @Override + public Object call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Gets an OpenAPI definition for the workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the Object object + */ + public Observable> listSwaggerWithServiceResponseAsync(String resourceGroupName, String workflowName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + return service.listSwagger(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = listSwaggerDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse listSwaggerDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void move(String resourceGroupName, String workflowName) { + moveWithServiceResponseAsync(resourceGroupName, workflowName).toBlocking().last().body(); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture moveAsync(String resourceGroupName, String workflowName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(moveWithServiceResponseAsync(resourceGroupName, workflowName), serviceCallback); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + public Observable moveAsync(String resourceGroupName, String workflowName) { + return moveWithServiceResponseAsync(resourceGroupName, workflowName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + public Observable> moveWithServiceResponseAsync(String resourceGroupName, String workflowName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final String id = null; + WorkflowReference move = new WorkflowReference(); + move.withId(null); + Observable> observable = service.move(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), move, this.client.userAgent()); + return client.getAzureClient().getPostOrDeleteResultAsync(observable, new TypeToken() { }.getType()); + } + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param id The resource id. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void move(String resourceGroupName, String workflowName, String id) { + moveWithServiceResponseAsync(resourceGroupName, workflowName, id).toBlocking().last().body(); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param id The resource id. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture moveAsync(String resourceGroupName, String workflowName, String id, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(moveWithServiceResponseAsync(resourceGroupName, workflowName, id), serviceCallback); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param id The resource id. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + public Observable moveAsync(String resourceGroupName, String workflowName, String id) { + return moveWithServiceResponseAsync(resourceGroupName, workflowName, id).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param id The resource id. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + public Observable> moveWithServiceResponseAsync(String resourceGroupName, String workflowName, String id) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + WorkflowReference move = new WorkflowReference(); + move.withId(id); + Observable> observable = service.move(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), move, this.client.userAgent()); + return client.getAzureClient().getPostOrDeleteResultAsync(observable, new TypeToken() { }.getType()); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void beginMove(String resourceGroupName, String workflowName) { + beginMoveWithServiceResponseAsync(resourceGroupName, workflowName).toBlocking().single().body(); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture beginMoveAsync(String resourceGroupName, String workflowName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(beginMoveWithServiceResponseAsync(resourceGroupName, workflowName), serviceCallback); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable beginMoveAsync(String resourceGroupName, String workflowName) { + return beginMoveWithServiceResponseAsync(resourceGroupName, workflowName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> beginMoveWithServiceResponseAsync(String resourceGroupName, String workflowName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final String id = null; + WorkflowReference move = new WorkflowReference(); + move.withId(null); + return service.beginMove(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), move, this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = beginMoveDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param id The resource id. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void beginMove(String resourceGroupName, String workflowName, String id) { + beginMoveWithServiceResponseAsync(resourceGroupName, workflowName, id).toBlocking().single().body(); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param id The resource id. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture beginMoveAsync(String resourceGroupName, String workflowName, String id, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(beginMoveWithServiceResponseAsync(resourceGroupName, workflowName, id), serviceCallback); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param id The resource id. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable beginMoveAsync(String resourceGroupName, String workflowName, String id) { + return beginMoveWithServiceResponseAsync(resourceGroupName, workflowName, id).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param id The resource id. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> beginMoveWithServiceResponseAsync(String resourceGroupName, String workflowName, String id) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + WorkflowReference move = new WorkflowReference(); + move.withId(id); + return service.beginMove(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), move, this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = beginMoveDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse beginMoveDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(202, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Regenerates the callback URL access key for request triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void regenerateAccessKey(String resourceGroupName, String workflowName) { + regenerateAccessKeyWithServiceResponseAsync(resourceGroupName, workflowName).toBlocking().single().body(); + } + + /** + * Regenerates the callback URL access key for request triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture regenerateAccessKeyAsync(String resourceGroupName, String workflowName, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(regenerateAccessKeyWithServiceResponseAsync(resourceGroupName, workflowName), serviceCallback); + } + + /** + * Regenerates the callback URL access key for request triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable regenerateAccessKeyAsync(String resourceGroupName, String workflowName) { + return regenerateAccessKeyWithServiceResponseAsync(resourceGroupName, workflowName).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Regenerates the callback URL access key for request triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> regenerateAccessKeyWithServiceResponseAsync(String resourceGroupName, String workflowName) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + final KeyType keyType = null; + RegenerateActionParameter keyType1 = new RegenerateActionParameter(); + keyType1.withKeyType(null); + return service.regenerateAccessKey(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), keyType1, this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = regenerateAccessKeyDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + /** + * Regenerates the callback URL access key for request triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param keyType The key type. Possible values include: 'NotSpecified', 'Primary', 'Secondary' + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void regenerateAccessKey(String resourceGroupName, String workflowName, KeyType keyType) { + regenerateAccessKeyWithServiceResponseAsync(resourceGroupName, workflowName, keyType).toBlocking().single().body(); + } + + /** + * Regenerates the callback URL access key for request triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param keyType The key type. Possible values include: 'NotSpecified', 'Primary', 'Secondary' + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture regenerateAccessKeyAsync(String resourceGroupName, String workflowName, KeyType keyType, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(regenerateAccessKeyWithServiceResponseAsync(resourceGroupName, workflowName, keyType), serviceCallback); + } + + /** + * Regenerates the callback URL access key for request triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param keyType The key type. Possible values include: 'NotSpecified', 'Primary', 'Secondary' + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable regenerateAccessKeyAsync(String resourceGroupName, String workflowName, KeyType keyType) { + return regenerateAccessKeyWithServiceResponseAsync(resourceGroupName, workflowName, keyType).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Regenerates the callback URL access key for request triggers. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param keyType The key type. Possible values include: 'NotSpecified', 'Primary', 'Secondary' + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> regenerateAccessKeyWithServiceResponseAsync(String resourceGroupName, String workflowName, KeyType keyType) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + RegenerateActionParameter keyType1 = new RegenerateActionParameter(); + keyType1.withKeyType(keyType); + return service.regenerateAccessKey(this.client.subscriptionId(), resourceGroupName, workflowName, this.client.apiVersion(), this.client.acceptLanguage(), keyType1, this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = regenerateAccessKeyDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse regenerateAccessKeyDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Validates the workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param validate The workflow. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void validateByResourceGroup(String resourceGroupName, String workflowName, WorkflowInner validate) { + validateByResourceGroupWithServiceResponseAsync(resourceGroupName, workflowName, validate).toBlocking().single().body(); + } + + /** + * Validates the workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param validate The workflow. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture validateByResourceGroupAsync(String resourceGroupName, String workflowName, WorkflowInner validate, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(validateByResourceGroupWithServiceResponseAsync(resourceGroupName, workflowName, validate), serviceCallback); + } + + /** + * Validates the workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param validate The workflow. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable validateByResourceGroupAsync(String resourceGroupName, String workflowName, WorkflowInner validate) { + return validateByResourceGroupWithServiceResponseAsync(resourceGroupName, workflowName, validate).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Validates the workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param validate The workflow. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> validateByResourceGroupWithServiceResponseAsync(String resourceGroupName, String workflowName, WorkflowInner validate) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (validate == null) { + throw new IllegalArgumentException("Parameter validate is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + Validator.validate(validate); + return service.validateByResourceGroup(this.client.subscriptionId(), resourceGroupName, workflowName, validate, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = validateByResourceGroupDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse validateByResourceGroupDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Validates the workflow definition. + * + * @param resourceGroupName The resource group name. + * @param location The workflow location. + * @param workflowName The workflow name. + * @param validate The workflow. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + */ + public void validateByLocation(String resourceGroupName, String location, String workflowName, WorkflowInner validate) { + validateByLocationWithServiceResponseAsync(resourceGroupName, location, workflowName, validate).toBlocking().single().body(); + } + + /** + * Validates the workflow definition. + * + * @param resourceGroupName The resource group name. + * @param location The workflow location. + * @param workflowName The workflow name. + * @param validate The workflow. + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture validateByLocationAsync(String resourceGroupName, String location, String workflowName, WorkflowInner validate, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(validateByLocationWithServiceResponseAsync(resourceGroupName, location, workflowName, validate), serviceCallback); + } + + /** + * Validates the workflow definition. + * + * @param resourceGroupName The resource group name. + * @param location The workflow location. + * @param workflowName The workflow name. + * @param validate The workflow. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable validateByLocationAsync(String resourceGroupName, String location, String workflowName, WorkflowInner validate) { + return validateByLocationWithServiceResponseAsync(resourceGroupName, location, workflowName, validate).map(new Func1, Void>() { + @Override + public Void call(ServiceResponse response) { + return response.body(); + } + }); + } + + /** + * Validates the workflow definition. + * + * @param resourceGroupName The resource group name. + * @param location The workflow location. + * @param workflowName The workflow name. + * @param validate The workflow. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> validateByLocationWithServiceResponseAsync(String resourceGroupName, String location, String workflowName, WorkflowInner validate) { + if (this.client.subscriptionId() == null) { + throw new IllegalArgumentException("Parameter this.client.subscriptionId() is required and cannot be null."); + } + if (resourceGroupName == null) { + throw new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."); + } + if (location == null) { + throw new IllegalArgumentException("Parameter location is required and cannot be null."); + } + if (workflowName == null) { + throw new IllegalArgumentException("Parameter workflowName is required and cannot be null."); + } + if (validate == null) { + throw new IllegalArgumentException("Parameter validate is required and cannot be null."); + } + if (this.client.apiVersion() == null) { + throw new IllegalArgumentException("Parameter this.client.apiVersion() is required and cannot be null."); + } + Validator.validate(validate); + return service.validateByLocation(this.client.subscriptionId(), resourceGroupName, location, workflowName, validate, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = validateByLocationDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse validateByLocationDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of workflows by subscription. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowInner> object if successful. + */ + public PagedList listNext(final String nextPageLink) { + ServiceResponse> response = listNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflows by subscription. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflows by subscription. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowInner> object + */ + public Observable> listNextAsync(final String nextPageLink) { + return listNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflows by subscription. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowInner> object + */ + public Observable>> listNextWithServiceResponseAsync(final String nextPageLink) { + return listNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflows by subscription. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + + /** + * Gets a list of workflows by resource group. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws ErrorResponseException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the PagedList<WorkflowInner> object if successful. + */ + public PagedList listByResourceGroupNext(final String nextPageLink) { + ServiceResponse> response = listByResourceGroupNextSinglePageAsync(nextPageLink).toBlocking().single(); + return new PagedList(response.body()) { + @Override + public Page nextPage(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink).toBlocking().single().body(); + } + }; + } + + /** + * Gets a list of workflows by resource group. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param serviceFuture the ServiceFuture object tracking the Retrofit calls + * @param serviceCallback the async ServiceCallback to handle successful and failed responses. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceFuture} object + */ + public ServiceFuture> listByResourceGroupNextAsync(final String nextPageLink, final ServiceFuture> serviceFuture, final ListOperationCallback serviceCallback) { + return AzureServiceFuture.fromPageResponse( + listByResourceGroupNextSinglePageAsync(nextPageLink), + new Func1>>>() { + @Override + public Observable>> call(String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink); + } + }, + serviceCallback); + } + + /** + * Gets a list of workflows by resource group. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowInner> object + */ + public Observable> listByResourceGroupNextAsync(final String nextPageLink) { + return listByResourceGroupNextWithServiceResponseAsync(nextPageLink) + .map(new Func1>, Page>() { + @Override + public Page call(ServiceResponse> response) { + return response.body(); + } + }); + } + + /** + * Gets a list of workflows by resource group. + * + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the PagedList<WorkflowInner> object + */ + public Observable>> listByResourceGroupNextWithServiceResponseAsync(final String nextPageLink) { + return listByResourceGroupNextSinglePageAsync(nextPageLink) + .concatMap(new Func1>, Observable>>>() { + @Override + public Observable>> call(ServiceResponse> page) { + String nextPageLink = page.body().nextPageLink(); + if (nextPageLink == null) { + return Observable.just(page); + } + return Observable.just(page).concatWith(listByResourceGroupNextWithServiceResponseAsync(nextPageLink)); + } + }); + } + + /** + * Gets a list of workflows by resource group. + * + ServiceResponse> * @param nextPageLink The NextLink from the previous successful call to List operation. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the PagedList<WorkflowInner> object wrapped in {@link ServiceResponse} if successful. + */ + public Observable>> listByResourceGroupNextSinglePageAsync(final String nextPageLink) { + if (nextPageLink == null) { + throw new IllegalArgumentException("Parameter nextPageLink is required and cannot be null."); + } + String nextUrl = String.format("%s", nextPageLink); + return service.listByResourceGroupNext(nextUrl, this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>>() { + @Override + public Observable>> call(Response response) { + try { + ServiceResponse> result = listByResourceGroupNextDelegate(response); + return Observable.just(new ServiceResponse>(result.body(), result.response())); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse> listByResourceGroupNextDelegate(Response response) throws ErrorResponseException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., ErrorResponseException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(ErrorResponseException.class) + .build(response); + } + +} diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/package-info.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/package-info.java new file mode 100644 index 000000000000..132bd4428245 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/implementation/package-info.java @@ -0,0 +1,11 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. See License.txt in the project root for +// license information. +// +// Code generated by Microsoft (R) AutoRest Code Generator. + +/** + * This package contains the implementation classes for LogicManagementClient. + * REST API for Azure Logic Apps. + */ +package com.microsoft.azure.management.logic.v2019_05_01.implementation; diff --git a/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/package-info.java b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/package-info.java new file mode 100644 index 000000000000..d4c40b1c6807 --- /dev/null +++ b/sdk/logic/mgmt-v2019_05_01/src/main/java/com/microsoft/azure/management/logic/v2019_05_01/package-info.java @@ -0,0 +1,11 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. See License.txt in the project root for +// license information. +// +// Code generated by Microsoft (R) AutoRest Code Generator. + +/** + * This package contains the classes for LogicManagementClient. + * REST API for Azure Logic Apps. + */ +package com.microsoft.azure.management.logic.v2019_05_01;