diff --git a/logic/resource-manager/v2018_07_01_preview/pom.xml b/logic/resource-manager/v2018_07_01_preview/pom.xml new file mode 100644 index 000000000000..ca5c4c6a4ecc --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/pom.xml @@ -0,0 +1,133 @@ + + + 4.0.0 + com.microsoft.azure.logic.v2018_07_01_preview + + com.microsoft.azure + azure-arm-parent + 0.0.2-beta + ../../../pom.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-libraries-for-java + + + The MIT License (MIT) + http://opensource.org/licenses/MIT + repo + + + + scm:git:https://github.com/Azure/azure-libraries-for-java + scm:git:git@github.com:Azure/azure-libraries-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 + + + + + + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2AcknowledgementConnectionSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2AcknowledgementConnectionSettings.java new file mode 100644 index 000000000000..eb4b8ce56cbb --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The AS2 agreement acknowledgement connection settings. + */ +public class AS2AcknowledgementConnectionSettings { + /** + * 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 AS2AcknowledgementConnectionSettings object itself. + */ + public AS2AcknowledgementConnectionSettings 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 AS2AcknowledgementConnectionSettings object itself. + */ + public AS2AcknowledgementConnectionSettings 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 AS2AcknowledgementConnectionSettings object itself. + */ + public AS2AcknowledgementConnectionSettings 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 AS2AcknowledgementConnectionSettings object itself. + */ + public AS2AcknowledgementConnectionSettings withUnfoldHttpHeaders(boolean unfoldHttpHeaders) { + this.unfoldHttpHeaders = unfoldHttpHeaders; + return this; + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2AgreementContent.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2AgreementContent.java new file mode 100644 index 000000000000..4f824b8ca6a9 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2EnvelopeSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2EnvelopeSettings.java new file mode 100644 index 000000000000..78a96ffcd30c --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2ErrorSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2ErrorSettings.java new file mode 100644 index 000000000000..61855a6f66cf --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2MdnSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2MdnSettings.java new file mode 100644 index 000000000000..e684b4e97a86 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2MessageConnectionSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2MessageConnectionSettings.java new file mode 100644 index 000000000000..e6b835586699 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2OneWayAgreement.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2OneWayAgreement.java new file mode 100644 index 000000000000..3bfced1df5c2 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2ProtocolSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2ProtocolSettings.java new file mode 100644 index 000000000000..c4cdeb8bfaf5 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2SecuritySettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2SecuritySettings.java new file mode 100644 index 000000000000..4fd111f37358 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2ValidationSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AS2ValidationSettings.java new file mode 100644 index 000000000000..63f521ad6a9e --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AccessKeyRegenerateActionDefinition.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AccessKeyRegenerateActionDefinition.java new file mode 100644 index 000000000000..c832f6078533 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AccessKeyRegenerateActionDefinition.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.v2018_07_01_preview; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The AccessKeyRegenerateActionDefinition model. + */ +public class AccessKeyRegenerateActionDefinition { + /** + * Possible values include: 'NotSpecified', 'Primary', 'Secondary'. + */ + @JsonProperty(value = "keyType", required = true) + private AccessKeyType keyType; + + /** + * Get possible values include: 'NotSpecified', 'Primary', 'Secondary'. + * + * @return the keyType value + */ + public AccessKeyType keyType() { + return this.keyType; + } + + /** + * Set possible values include: 'NotSpecified', 'Primary', 'Secondary'. + * + * @param keyType the keyType value to set + * @return the AccessKeyRegenerateActionDefinition object itself. + */ + public AccessKeyRegenerateActionDefinition withKeyType(AccessKeyType keyType) { + this.keyType = keyType; + return this; + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AccessKeyType.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AccessKeyType.java new file mode 100644 index 000000000000..d1e9ae86c6a6 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AccessKeyType.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.v2018_07_01_preview; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for AccessKeyType. + */ +public final class AccessKeyType extends ExpandableStringEnum { + /** Static value NotSpecified for AccessKeyType. */ + public static final AccessKeyType NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Primary for AccessKeyType. */ + public static final AccessKeyType PRIMARY = fromString("Primary"); + + /** Static value Secondary for AccessKeyType. */ + public static final AccessKeyType SECONDARY = fromString("Secondary"); + + /** + * Creates or finds a AccessKeyType from its string representation. + * @param name a name to look for + * @return the corresponding AccessKeyType + */ + @JsonCreator + public static AccessKeyType fromString(String name) { + return fromString(name, AccessKeyType.class); + } + + /** + * @return known AccessKeyType values + */ + public static Collection values() { + return values(AccessKeyType.class); + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ActionRunWorkflowWorkflowRunActionRepetitionDefinition.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ActionRunWorkflowWorkflowRunActionRepetitionDefinition.java new file mode 100644 index 000000000000..346197fa7d28 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel.java new file mode 100644 index 000000000000..1a060e711eb5 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AgreementContent.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AgreementContent.java new file mode 100644 index 000000000000..4db916fd6134 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AgreementType.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AgreementType.java new file mode 100644 index 000000000000..d94f5c5d64b4 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AgreementType.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.v2018_07_01_preview; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for AgreementType. + */ +public final class AgreementType extends ExpandableStringEnum { + /** Static value NotSpecified for AgreementType. */ + public static final AgreementType NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value AS2 for AgreementType. */ + public static final AgreementType AS2 = fromString("AS2"); + + /** Static value X12 for AgreementType. */ + public static final AgreementType X12 = fromString("X12"); + + /** Static value Edifact for AgreementType. */ + public static final AgreementType EDIFACT = fromString("Edifact"); + + /** + * Creates or finds a AgreementType from its string representation. + * @param name a name to look for + * @return the corresponding AgreementType + */ + @JsonCreator + public static AgreementType fromString(String name) { + return fromString(name, AgreementType.class); + } + + /** + * @return known AgreementType values + */ + public static Collection values() { + return values(AgreementType.class); + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ArtifactContentPropertiesDefinition.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ArtifactContentPropertiesDefinition.java new file mode 100644 index 000000000000..a76c5999861d --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ArtifactProperties.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ArtifactProperties.java new file mode 100644 index 000000000000..a7bcb1fce08d --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AssemblyDefinition.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AssemblyDefinition.java new file mode 100644 index 000000000000..673bf3fe9380 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AssemblyDefinition.java @@ -0,0 +1,151 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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. + */ + WithProperties withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the assemblydefinition definition allowing to specify Properties. + */ + interface WithProperties { + /** + * Specifies properties. + */ + WithCreate withProperties(AssemblyProperties properties); + } + + /** + * The stage of the assemblydefinition definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the assemblydefinition definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + 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. + */ + Update withLocation(String location); + } + + /** + * The stage of the assemblydefinition update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + Update withTags(Map tags); + } + + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AssemblyProperties.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AssemblyProperties.java new file mode 100644 index 000000000000..ebce43bfdafc --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AzureResourceErrorInfo.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/AzureResourceErrorInfo.java new file mode 100644 index 000000000000..be101efc9b01 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/B2BPartnerContent.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/B2BPartnerContent.java new file mode 100644 index 000000000000..575b7c30fded --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/BatchConfiguration.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/BatchConfiguration.java new file mode 100644 index 000000000000..56be4053b6d1 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/BatchConfiguration.java @@ -0,0 +1,151 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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. + */ + WithProperties withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the batchconfiguration definition allowing to specify Properties. + */ + interface WithProperties { + /** + * Specifies properties. + */ + WithCreate withProperties(BatchConfigurationProperties properties); + } + + /** + * The stage of the batchconfiguration definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the batchconfiguration definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + 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. + */ + Update withLocation(String location); + } + + /** + * The stage of the batchconfiguration update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + Update withTags(Map tags); + } + + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/BatchConfigurationProperties.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/BatchConfigurationProperties.java new file mode 100644 index 000000000000..4107bbd65a72 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/BatchReleaseCriteria.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/BatchReleaseCriteria.java new file mode 100644 index 000000000000..bc7a459284a4 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/BusinessIdentity.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/BusinessIdentity.java new file mode 100644 index 000000000000..a786eae2f433 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/CallbackUrl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/CallbackUrl.java new file mode 100644 index 000000000000..586fc4ca3a9a --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.CallbackUrlInner; + +/** + * Type representing CallbackUrl. + */ +public interface CallbackUrl extends HasInner, HasManager { + /** + * @return the value value. + */ + String value(); + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ContentHash.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ContentHash.java new file mode 100644 index 000000000000..cffd166c3674 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ContentLink.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ContentLink.java new file mode 100644 index 000000000000..ad2aad19e668 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Correlation.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Correlation.java new file mode 100644 index 000000000000..fec3c21627c8 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/DayOfWeek.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/DayOfWeek.java new file mode 100644 index 000000000000..168ac497ecfa --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/DayOfWeek.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.v2018_07_01_preview; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for DayOfWeek. + */ +public final class DayOfWeek extends ExpandableStringEnum { + /** Static value Sunday for DayOfWeek. */ + public static final DayOfWeek SUNDAY = fromString("Sunday"); + + /** Static value Monday for DayOfWeek. */ + public static final DayOfWeek MONDAY = fromString("Monday"); + + /** Static value Tuesday for DayOfWeek. */ + public static final DayOfWeek TUESDAY = fromString("Tuesday"); + + /** Static value Wednesday for DayOfWeek. */ + public static final DayOfWeek WEDNESDAY = fromString("Wednesday"); + + /** Static value Thursday for DayOfWeek. */ + public static final DayOfWeek THURSDAY = fromString("Thursday"); + + /** Static value Friday for DayOfWeek. */ + public static final DayOfWeek FRIDAY = fromString("Friday"); + + /** Static value Saturday for DayOfWeek. */ + public static final DayOfWeek SATURDAY = fromString("Saturday"); + + /** + * Creates or finds a DayOfWeek from its string representation. + * @param name a name to look for + * @return the corresponding DayOfWeek + */ + @JsonCreator + public static DayOfWeek fromString(String name) { + return fromString(name, DayOfWeek.class); + } + + /** + * @return known DayOfWeek values + */ + public static Collection values() { + return values(DayOfWeek.class); + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/DaysOfWeek.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/DaysOfWeek.java new file mode 100644 index 000000000000..9ac2adb6aaeb --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/DaysOfWeek.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.v2018_07_01_preview; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for DaysOfWeek. + */ +public final class DaysOfWeek extends ExpandableStringEnum { + /** Static value Sunday for DaysOfWeek. */ + public static final DaysOfWeek SUNDAY = fromString("Sunday"); + + /** Static value Monday for DaysOfWeek. */ + public static final DaysOfWeek MONDAY = fromString("Monday"); + + /** Static value Tuesday for DaysOfWeek. */ + public static final DaysOfWeek TUESDAY = fromString("Tuesday"); + + /** Static value Wednesday for DaysOfWeek. */ + public static final DaysOfWeek WEDNESDAY = fromString("Wednesday"); + + /** Static value Thursday for DaysOfWeek. */ + public static final DaysOfWeek THURSDAY = fromString("Thursday"); + + /** Static value Friday for DaysOfWeek. */ + public static final DaysOfWeek FRIDAY = fromString("Friday"); + + /** Static value Saturday for DaysOfWeek. */ + public static final DaysOfWeek SATURDAY = fromString("Saturday"); + + /** + * Creates or finds a DaysOfWeek from its string representation. + * @param name a name to look for + * @return the corresponding DaysOfWeek + */ + @JsonCreator + public static DaysOfWeek fromString(String name) { + return fromString(name, DaysOfWeek.class); + } + + /** + * @return known DaysOfWeek values + */ + public static Collection values() { + return values(DaysOfWeek.class); + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactAcknowledgementSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactAcknowledgementSettings.java new file mode 100644 index 000000000000..0114348fd3a3 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactAgreementContent.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactAgreementContent.java new file mode 100644 index 000000000000..13efa1e3f3f8 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactCharacterSet.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactCharacterSet.java new file mode 100644 index 000000000000..f087e343c8b1 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactDecimalIndicator.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactDecimalIndicator.java new file mode 100644 index 000000000000..efa2aaa4f8e9 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactDecimalIndicator.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.v2018_07_01_preview; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for EdifactDecimalIndicator. + */ +public final class EdifactDecimalIndicator extends ExpandableStringEnum { + /** Static value NotSpecified for EdifactDecimalIndicator. */ + public static final EdifactDecimalIndicator NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value Comma for EdifactDecimalIndicator. */ + public static final EdifactDecimalIndicator COMMA = fromString("Comma"); + + /** Static value Decimal for EdifactDecimalIndicator. */ + public static final EdifactDecimalIndicator DECIMAL = fromString("Decimal"); + + /** + * Creates or finds a EdifactDecimalIndicator from its string representation. + * @param name a name to look for + * @return the corresponding EdifactDecimalIndicator + */ + @JsonCreator + public static EdifactDecimalIndicator fromString(String name) { + return fromString(name, EdifactDecimalIndicator.class); + } + + /** + * @return known EdifactDecimalIndicator values + */ + public static Collection values() { + return values(EdifactDecimalIndicator.class); + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactDelimiterOverride.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactDelimiterOverride.java new file mode 100644 index 000000000000..3e4bfd8ca40b --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactEnvelopeOverride.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactEnvelopeOverride.java new file mode 100644 index 000000000000..2ef665ad97b1 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactEnvelopeSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactEnvelopeSettings.java new file mode 100644 index 000000000000..3a010c633692 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactFramingSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactFramingSettings.java new file mode 100644 index 000000000000..242a0882ed2a --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactMessageFilter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactMessageFilter.java new file mode 100644 index 000000000000..9b97f022de45 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactMessageIdentifier.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactMessageIdentifier.java new file mode 100644 index 000000000000..600f676d74a8 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactOneWayAgreement.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactOneWayAgreement.java new file mode 100644 index 000000000000..879448fd75b6 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactProcessingSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactProcessingSettings.java new file mode 100644 index 000000000000..69dc1c9616a8 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactProtocolSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactProtocolSettings.java new file mode 100644 index 000000000000..69e995e6c1a3 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactSchemaReference.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactSchemaReference.java new file mode 100644 index 000000000000..d1d851097a18 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactValidationOverride.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactValidationOverride.java new file mode 100644 index 000000000000..a19a188dacd2 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactValidationSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EdifactValidationSettings.java new file mode 100644 index 000000000000..217e54419236 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EncryptionAlgorithm.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EncryptionAlgorithm.java new file mode 100644 index 000000000000..f325ead1129c --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ErrorInfo.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ErrorInfo.java new file mode 100644 index 000000000000..e85c5dcaf1d0 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ErrorProperties.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ErrorProperties.java new file mode 100644 index 000000000000..d8dd0c14be43 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ErrorResponse.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ErrorResponse.java new file mode 100644 index 000000000000..00aa72e985d5 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ErrorResponseException.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ErrorResponseException.java new file mode 100644 index 000000000000..10e5e4564330 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EventLevel.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EventLevel.java new file mode 100644 index 000000000000..05c3d19526a4 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/EventLevel.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.v2018_07_01_preview; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for EventLevel. + */ +public final class EventLevel extends ExpandableStringEnum { + /** Static value LogAlways for EventLevel. */ + public static final EventLevel LOG_ALWAYS = fromString("LogAlways"); + + /** Static value Critical for EventLevel. */ + public static final EventLevel CRITICAL = fromString("Critical"); + + /** Static value Error for EventLevel. */ + public static final EventLevel ERROR = fromString("Error"); + + /** Static value Warning for EventLevel. */ + public static final EventLevel WARNING = fromString("Warning"); + + /** Static value Informational for EventLevel. */ + public static final EventLevel INFORMATIONAL = fromString("Informational"); + + /** Static value Verbose for EventLevel. */ + public static final EventLevel VERBOSE = fromString("Verbose"); + + /** + * Creates or finds a EventLevel from its string representation. + * @param name a name to look for + * @return the corresponding EventLevel + */ + @JsonCreator + public static EventLevel fromString(String name) { + return fromString(name, EventLevel.class); + } + + /** + * @return known EventLevel values + */ + public static Collection values() { + return values(EventLevel.class); + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Expression.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Expression.java new file mode 100644 index 000000000000..d71e5b8ba5b5 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The Expression model. + */ +public class Expression { + /** + * The text property. + */ + @JsonProperty(value = "text") + private String text; + + /** + * The value property. + */ + @JsonProperty(value = "value") + private Object value; + + /** + * The subexpressions property. + */ + @JsonProperty(value = "subexpressions") + private List subexpressions; + + /** + * The error property. + */ + @JsonProperty(value = "error") + private AzureResourceErrorInfo error; + + /** + * Get the text value. + * + * @return the text value + */ + public String text() { + return this.text; + } + + /** + * Set the text value. + * + * @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 subexpressions value. + * + * @return the subexpressions value + */ + public List subexpressions() { + return this.subexpressions; + } + + /** + * Set the subexpressions value. + * + * @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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ExpressionRoot.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ExpressionRoot.java new file mode 100644 index 000000000000..03678ea7f590 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/GenerateUpgradedDefinitionParameters.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/GenerateUpgradedDefinitionParameters.java new file mode 100644 index 000000000000..0b6a23c3cf4e --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/GetCallbackUrlParameters.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/GetCallbackUrlParameters.java new file mode 100644 index 000000000000..3e8c7f86d0b0 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/HashingAlgorithm.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/HashingAlgorithm.java new file mode 100644 index 000000000000..0f9d0835fd01 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccount.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccount.java new file mode 100644 index 000000000000..caa853a699bf --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccount.java @@ -0,0 +1,118 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview; + +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.v2018_07_01_preview.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.IntegrationAccountInner; + +/** + * Type representing IntegrationAccount. + */ +public interface IntegrationAccount extends HasInner, Resource, GroupableResourceCore, HasResourceGroup, Refreshable, Updatable, HasManager { + /** + * @return the properties value. + */ + Object properties(); + + /** + * @return the sku value. + */ + IntegrationAccountSku sku(); + + /** + * 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 update allowing to specify Properties. + */ + interface WithProperties { + /** + * Specifies properties. + */ + WithCreate withProperties(Object properties); + } + + /** + * The stage of the integrationaccount update allowing to specify Sku. + */ + interface WithSku { + /** + * Specifies sku. + */ + WithCreate withSku(IntegrationAccountSku 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 IntegrationAccount update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable, Resource.UpdateWithTags, UpdateStages.WithProperties, UpdateStages.WithSku { + } + + /** + * Grouping of IntegrationAccount update stages. + */ + interface UpdateStages { + /** + * The stage of the integrationaccount {0} allowing to specify Properties. + */ + interface WithProperties { + /** + * Specifies properties. + */ + Update withProperties(Object properties); + } + + /** + * The stage of the integrationaccount {0} allowing to specify Sku. + */ + interface WithSku { + /** + * Specifies sku. + */ + Update withSku(IntegrationAccountSku sku); + } + + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountAgreement.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountAgreement.java new file mode 100644 index 000000000000..07eabd40ee84 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountAgreement.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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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. + */ + WithAgreementType withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify AgreementType. + */ + interface WithAgreementType { + /** + * Specifies agreementType. + */ + WithContent withAgreementType(AgreementType agreementType); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify Content. + */ + interface WithContent { + /** + * Specifies content. + */ + WithGuestIdentity withContent(AgreementContent content); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify GuestIdentity. + */ + interface WithGuestIdentity { + /** + * Specifies guestIdentity. + */ + WithGuestPartner withGuestIdentity(BusinessIdentity guestIdentity); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify GuestPartner. + */ + interface WithGuestPartner { + /** + * Specifies guestPartner. + */ + WithHostIdentity withGuestPartner(String guestPartner); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify HostIdentity. + */ + interface WithHostIdentity { + /** + * Specifies hostIdentity. + */ + WithHostPartner withHostIdentity(BusinessIdentity hostIdentity); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify HostPartner. + */ + interface WithHostPartner { + /** + * Specifies hostPartner. + */ + WithCreate withHostPartner(String hostPartner); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + */ + WithCreate withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountagreement definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + 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. + */ + Update withLocation(String location); + } + + /** + * The stage of the integrationaccountagreement update allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + */ + Update withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountagreement update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + Update withTags(Map tags); + } + + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountAgreementFilter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountAgreementFilter.java new file mode 100644 index 000000000000..5e5c91d49138 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountAgreements.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountAgreements.java new file mode 100644 index 000000000000..0a6778a152c6 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountAssemblies.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountAssemblies.java new file mode 100644 index 000000000000..7b2a84fdac23 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountBatchConfigurations.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountBatchConfigurations.java new file mode 100644 index 000000000000..e4679bf75e19 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountCertificate.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountCertificate.java new file mode 100644 index 000000000000..879b5fc16076 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountCertificate.java @@ -0,0 +1,222 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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. + */ + WithCreate withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the integrationaccountcertificate definition allowing to specify Key. + */ + interface WithKey { + /** + * Specifies key. + */ + WithCreate withKey(KeyVaultKeyReference key); + } + + /** + * The stage of the integrationaccountcertificate definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the integrationaccountcertificate definition allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + */ + WithCreate withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountcertificate definition allowing to specify PublicCertificate. + */ + interface WithPublicCertificate { + /** + * Specifies publicCertificate. + */ + WithCreate withPublicCertificate(String publicCertificate); + } + + /** + * The stage of the integrationaccountcertificate definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + 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. + */ + Update withKey(KeyVaultKeyReference key); + } + + /** + * The stage of the integrationaccountcertificate update allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + */ + Update withLocation(String location); + } + + /** + * The stage of the integrationaccountcertificate update allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + */ + Update withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountcertificate update allowing to specify PublicCertificate. + */ + interface WithPublicCertificate { + /** + * Specifies publicCertificate. + */ + Update withPublicCertificate(String publicCertificate); + } + + /** + * The stage of the integrationaccountcertificate update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + Update withTags(Map tags); + } + + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountCertificates.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountCertificates.java new file mode 100644 index 000000000000..00931c8c5097 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountMap.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountMap.java new file mode 100644 index 000000000000..3e87b11ade56 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountMap.java @@ -0,0 +1,267 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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. + */ + WithMapType withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify MapType. + */ + interface WithMapType { + /** + * Specifies mapType. + */ + WithCreate withMapType(MapType mapType); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify Content. + */ + interface WithContent { + /** + * Specifies content. + */ + WithCreate withContent(String content); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify ContentType. + */ + interface WithContentType { + /** + * Specifies contentType. + */ + WithCreate withContentType(String contentType); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + */ + WithCreate withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify ParametersSchema. + */ + interface WithParametersSchema { + /** + * Specifies parametersSchema. + */ + WithCreate withParametersSchema(IntegrationAccountMapPropertiesParametersSchema parametersSchema); + } + + /** + * The stage of the integrationaccountmap definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + 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. + */ + Update withContent(String content); + } + + /** + * The stage of the integrationaccountmap update allowing to specify ContentType. + */ + interface WithContentType { + /** + * Specifies contentType. + */ + Update withContentType(String contentType); + } + + /** + * The stage of the integrationaccountmap update allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + */ + Update withLocation(String location); + } + + /** + * The stage of the integrationaccountmap update allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + */ + Update withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountmap update allowing to specify ParametersSchema. + */ + interface WithParametersSchema { + /** + * Specifies parametersSchema. + */ + Update withParametersSchema(IntegrationAccountMapPropertiesParametersSchema parametersSchema); + } + + /** + * The stage of the integrationaccountmap update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + Update withTags(Map tags); + } + + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountMapFilter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountMapFilter.java new file mode 100644 index 000000000000..8ad51cd940f1 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountMapPropertiesParametersSchema.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountMapPropertiesParametersSchema.java new file mode 100644 index 000000000000..a195887f1c73 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountMaps.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountMaps.java new file mode 100644 index 000000000000..766ffc8e8e84 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountPartner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountPartner.java new file mode 100644 index 000000000000..4bbbf0c1d7bc --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountPartner.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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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. + */ + WithContent withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the integrationaccountpartner definition allowing to specify Content. + */ + interface WithContent { + /** + * Specifies content. + */ + WithPartnerType withContent(PartnerContent content); + } + + /** + * The stage of the integrationaccountpartner definition allowing to specify PartnerType. + */ + interface WithPartnerType { + /** + * Specifies partnerType. + */ + WithCreate withPartnerType(PartnerType partnerType); + } + + /** + * The stage of the integrationaccountpartner definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the integrationaccountpartner definition allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + */ + WithCreate withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountpartner definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + 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. + */ + Update withLocation(String location); + } + + /** + * The stage of the integrationaccountpartner update allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + */ + Update withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountpartner update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + Update withTags(Map tags); + } + + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountPartnerFilter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountPartnerFilter.java new file mode 100644 index 000000000000..5cdd399c3fcf --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountPartners.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountPartners.java new file mode 100644 index 000000000000..84c3c9518aeb --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSchema.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSchema.java new file mode 100644 index 000000000000..ebb0d1e40725 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSchema.java @@ -0,0 +1,317 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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. + */ + WithSchemaType withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify SchemaType. + */ + interface WithSchemaType { + /** + * Specifies schemaType. + */ + WithCreate withSchemaType(SchemaType schemaType); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify Content. + */ + interface WithContent { + /** + * Specifies content. + */ + WithCreate withContent(String content); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify ContentType. + */ + interface WithContentType { + /** + * Specifies contentType. + */ + WithCreate withContentType(String contentType); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify DocumentName. + */ + interface WithDocumentName { + /** + * Specifies documentName. + */ + WithCreate withDocumentName(String documentName); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify FileName. + */ + interface WithFileName { + /** + * Specifies fileName. + */ + WithCreate withFileName(String fileName); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + */ + WithCreate withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + WithCreate withTags(Map tags); + } + + /** + * The stage of the integrationaccountschema definition allowing to specify TargetNamespace. + */ + interface WithTargetNamespace { + /** + * Specifies targetNamespace. + */ + 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. + */ + Update withContent(String content); + } + + /** + * The stage of the integrationaccountschema update allowing to specify ContentType. + */ + interface WithContentType { + /** + * Specifies contentType. + */ + Update withContentType(String contentType); + } + + /** + * The stage of the integrationaccountschema update allowing to specify DocumentName. + */ + interface WithDocumentName { + /** + * Specifies documentName. + */ + Update withDocumentName(String documentName); + } + + /** + * The stage of the integrationaccountschema update allowing to specify FileName. + */ + interface WithFileName { + /** + * Specifies fileName. + */ + Update withFileName(String fileName); + } + + /** + * The stage of the integrationaccountschema update allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + */ + Update withLocation(String location); + } + + /** + * The stage of the integrationaccountschema update allowing to specify Metadata. + */ + interface WithMetadata { + /** + * Specifies metadata. + */ + Update withMetadata(Object metadata); + } + + /** + * The stage of the integrationaccountschema update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + Update withTags(Map tags); + } + + /** + * The stage of the integrationaccountschema update allowing to specify TargetNamespace. + */ + interface WithTargetNamespace { + /** + * Specifies targetNamespace. + */ + Update withTargetNamespace(String targetNamespace); + } + + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSchemaFilter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSchemaFilter.java new file mode 100644 index 000000000000..b656fd868c9b --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSchemas.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSchemas.java new file mode 100644 index 000000000000..d9af174bc454 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSession.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSession.java new file mode 100644 index 000000000000..b1af01522f34 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSession.java @@ -0,0 +1,172 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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. + */ + WithCreate withExistingIntegrationAccount(String resourceGroupName, String integrationAccountName); + } + + /** + * The stage of the integrationaccountsession definition allowing to specify Content. + */ + interface WithContent { + /** + * Specifies content. + */ + WithCreate withContent(Object content); + } + + /** + * The stage of the integrationaccountsession definition allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + */ + WithCreate withLocation(String location); + } + + /** + * The stage of the integrationaccountsession definition allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + 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. + */ + Update withContent(Object content); + } + + /** + * The stage of the integrationaccountsession update allowing to specify Location. + */ + interface WithLocation { + /** + * Specifies location. + */ + Update withLocation(String location); + } + + /** + * The stage of the integrationaccountsession update allowing to specify Tags. + */ + interface WithTags { + /** + * Specifies tags. + */ + Update withTags(Map tags); + } + + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSessionFilter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSessionFilter.java new file mode 100644 index 000000000000..f3026a380739 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSessions.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSessions.java new file mode 100644 index 000000000000..acaf7cb8152b --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.collection.SupportsCreating; +import rx.Completable; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSku.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSku.java new file mode 100644 index 000000000000..c92a59458318 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSkuName.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccountSkuName.java new file mode 100644 index 000000000000..3f767fd9414b --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccounts.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/IntegrationAccounts.java new file mode 100644 index 000000000000..8cbfe7ea12d0 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/JsonSchema.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/JsonSchema.java new file mode 100644 index 000000000000..b011403c43d0 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/KeyType.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/KeyType.java new file mode 100644 index 000000000000..4bbcf10a9a50 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/KeyVaultKey.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/KeyVaultKey.java new file mode 100644 index 000000000000..25627c128c87 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/KeyVaultKeyAttributes.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/KeyVaultKeyAttributes.java new file mode 100644 index 000000000000..0c2bff569ddf --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/KeyVaultKeyReference.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/KeyVaultKeyReference.java new file mode 100644 index 000000000000..f30268e67a56 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/KeyVaultKeyReferenceKeyVault.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/KeyVaultKeyReferenceKeyVault.java new file mode 100644 index 000000000000..8ecd3f29fcda --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/KeyVaultReference.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/KeyVaultReference.java new file mode 100644 index 000000000000..e1f0cd1fcd0d --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + + +/** + * The key vault reference. + */ +public class KeyVaultReference extends ResourceReference { +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ListKeyVaultKeysDefinition.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ListKeyVaultKeysDefinition.java new file mode 100644 index 000000000000..001ed8e7e843 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/MapType.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/MapType.java new file mode 100644 index 000000000000..c090b9267a28 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/MessageFilterType.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/MessageFilterType.java new file mode 100644 index 000000000000..9f1d26a0b662 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Operation.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Operation.java new file mode 100644 index 000000000000..88c65286017a --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Operation.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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.OperationInner; + +/** + * Type representing Operation. + */ +public interface Operation extends HasInner, HasManager { + /** + * @return the display value. + */ + OperationDisplay display(); + + /** + * @return the name value. + */ + String name(); + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/OperationDisplay.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/OperationDisplay.java new file mode 100644 index 000000000000..dabaa9e574b3 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/OperationDisplay.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.v2018_07_01_preview; + +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; + + /** + * 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; + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/OperationResult.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/OperationResult.java new file mode 100644 index 000000000000..44576c8d90e3 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/OperationResultProperties.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/OperationResultProperties.java new file mode 100644 index 000000000000..069145fe618b --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Operations.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Operations.java new file mode 100644 index 000000000000..4cfc67262d03 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ParameterType.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ParameterType.java new file mode 100644 index 000000000000..413f99af56d0 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/PartnerContent.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/PartnerContent.java new file mode 100644 index 000000000000..51941af82017 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/PartnerType.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/PartnerType.java new file mode 100644 index 000000000000..6470e89932dc --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RecurrenceFrequency.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RecurrenceFrequency.java new file mode 100644 index 000000000000..77ab2ab2f596 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RecurrenceSchedule.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RecurrenceSchedule.java new file mode 100644 index 000000000000..0734a9e601ef --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RecurrenceScheduleOccurrence.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RecurrenceScheduleOccurrence.java new file mode 100644 index 000000000000..805f489fe11f --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RegenerateActionParameter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RegenerateActionParameter.java new file mode 100644 index 000000000000..b2c6f98040ec --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RepetitionIndex.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RepetitionIndex.java new file mode 100644 index 000000000000..9881e7ae917c --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ResourceReference.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ResourceReference.java new file mode 100644 index 000000000000..00aa8c8da1e5 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/ResourceReference.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.v2018_07_01_preview; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The resource reference. + */ +public class ResourceReference { + /** + * The resource id. + */ + @JsonProperty(value = "id", access = JsonProperty.Access.WRITE_ONLY) + 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; + } + + /** + * 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RetryHistory.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RetryHistory.java new file mode 100644 index 000000000000..2b3927cd446e --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RunActionCorrelation.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RunActionCorrelation.java new file mode 100644 index 000000000000..15726973e741 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RunCorrelation.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RunCorrelation.java new file mode 100644 index 000000000000..eb39130cf677 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RunWorkflowWorkflowRun.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/RunWorkflowWorkflowRun.java new file mode 100644 index 000000000000..4f4c52432b60 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/SchemaType.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/SchemaType.java new file mode 100644 index 000000000000..e179c346eba1 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/SegmentTerminatorSuffix.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/SegmentTerminatorSuffix.java new file mode 100644 index 000000000000..cc4f1983924e --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/SegmentTerminatorSuffix.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.v2018_07_01_preview; + +import java.util.Collection; +import com.fasterxml.jackson.annotation.JsonCreator; +import com.microsoft.rest.ExpandableStringEnum; + +/** + * Defines values for SegmentTerminatorSuffix. + */ +public final class SegmentTerminatorSuffix extends ExpandableStringEnum { + /** Static value NotSpecified for SegmentTerminatorSuffix. */ + public static final SegmentTerminatorSuffix NOT_SPECIFIED = fromString("NotSpecified"); + + /** Static value None for SegmentTerminatorSuffix. */ + public static final SegmentTerminatorSuffix NONE = fromString("None"); + + /** Static value CR for SegmentTerminatorSuffix. */ + public static final SegmentTerminatorSuffix CR = fromString("CR"); + + /** Static value LF for SegmentTerminatorSuffix. */ + public static final SegmentTerminatorSuffix LF = fromString("LF"); + + /** Static value CRLF for SegmentTerminatorSuffix. */ + public static final SegmentTerminatorSuffix CRLF = fromString("CRLF"); + + /** + * Creates or finds a SegmentTerminatorSuffix from its string representation. + * @param name a name to look for + * @return the corresponding SegmentTerminatorSuffix + */ + @JsonCreator + public static SegmentTerminatorSuffix fromString(String name) { + return fromString(name, SegmentTerminatorSuffix.class); + } + + /** + * @return known SegmentTerminatorSuffix values + */ + public static Collection values() { + return values(SegmentTerminatorSuffix.class); + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/SetTriggerStateActionDefinition.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/SetTriggerStateActionDefinition.java new file mode 100644 index 000000000000..bd73d8f3e280 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/SetTriggerStateActionDefinition.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.v2018_07_01_preview; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.WorkflowTriggerInner; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The SetTriggerStateActionDefinition model. + */ +public class SetTriggerStateActionDefinition { + /** + * The source property. + */ + @JsonProperty(value = "source", required = true) + private WorkflowTriggerInner source; + + /** + * Get the source value. + * + * @return the source value + */ + public WorkflowTriggerInner source() { + return this.source; + } + + /** + * Set the source value. + * + * @param source the source value to set + * @return the SetTriggerStateActionDefinition object itself. + */ + public SetTriggerStateActionDefinition withSource(WorkflowTriggerInner source) { + this.source = source; + return this; + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/SigningAlgorithm.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/SigningAlgorithm.java new file mode 100644 index 000000000000..f3c64d026b37 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Sku.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Sku.java new file mode 100644 index 000000000000..a80f6b7f5082 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/SkuName.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/SkuName.java new file mode 100644 index 000000000000..99929f1a6b18 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrackEventsOperationOptions.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrackEventsOperationOptions.java new file mode 100644 index 000000000000..1eb9b4135246 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrackingEvent.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrackingEvent.java new file mode 100644 index 000000000000..5ccfbb1b812b --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrackingEvent.java @@ -0,0 +1,130 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview; + +import org.joda.time.DateTime; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The TrackingEvent model. + */ +public class TrackingEvent { + /** + * Possible values include: 'LogAlways', 'Critical', 'Error', 'Warning', + * 'Informational', 'Verbose'. + */ + @JsonProperty(value = "eventLevel", required = true) + private EventLevel eventLevel; + + /** + * The eventTime property. + */ + @JsonProperty(value = "eventTime", required = true) + private DateTime eventTime; + + /** + * 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 error property. + */ + @JsonProperty(value = "error") + private TrackingEventErrorInfo error; + + /** + * Get possible values include: 'LogAlways', 'Critical', 'Error', 'Warning', 'Informational', 'Verbose'. + * + * @return the eventLevel value + */ + public EventLevel eventLevel() { + return this.eventLevel; + } + + /** + * Set 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 eventTime value. + * + * @return the eventTime value + */ + public DateTime eventTime() { + return this.eventTime; + } + + /** + * Set the eventTime value. + * + * @param eventTime the eventTime value to set + * @return the TrackingEvent object itself. + */ + public TrackingEvent withEventTime(DateTime eventTime) { + this.eventTime = eventTime; + return this; + } + + /** + * Get 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 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 error value. + * + * @return the error value + */ + public TrackingEventErrorInfo error() { + return this.error; + } + + /** + * Set the error value. + * + * @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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrackingEventErrorInfo.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrackingEventErrorInfo.java new file mode 100644 index 000000000000..90af3d288967 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The TrackingEventErrorInfo model. + */ +public class TrackingEventErrorInfo { + /** + * The message property. + */ + @JsonProperty(value = "message") + private String message; + + /** + * The code property. + */ + @JsonProperty(value = "code") + private String code; + + /** + * Get the message value. + * + * @return the message value + */ + public String message() { + return this.message; + } + + /** + * Set the message value. + * + * @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 value. + * + * @return the code value + */ + public String code() { + return this.code; + } + + /** + * Set the code value. + * + * @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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrackingEventsDefinition.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrackingEventsDefinition.java new file mode 100644 index 000000000000..9d156b48f62e --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrackingEventsDefinition.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.v2018_07_01_preview; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * The TrackingEventsDefinition model. + */ +public class TrackingEventsDefinition { + /** + * The sourceType property. + */ + @JsonProperty(value = "sourceType", required = true) + private String sourceType; + + /** + * Possible values include: 'None', 'DisableSourceInfoEnrich'. + */ + @JsonProperty(value = "trackEventsOptions") + private TrackEventsOperationOptions trackEventsOptions; + + /** + * The events property. + */ + @JsonProperty(value = "events", required = true) + private List events; + + /** + * Get the sourceType value. + * + * @return the sourceType value + */ + public String sourceType() { + return this.sourceType; + } + + /** + * Set the sourceType value. + * + * @param sourceType the sourceType value to set + * @return the TrackingEventsDefinition object itself. + */ + public TrackingEventsDefinition withSourceType(String sourceType) { + this.sourceType = sourceType; + return this; + } + + /** + * Get possible values include: 'None', 'DisableSourceInfoEnrich'. + * + * @return the trackEventsOptions value + */ + public TrackEventsOperationOptions trackEventsOptions() { + return this.trackEventsOptions; + } + + /** + * Set 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 value. + * + * @return the events value + */ + public List events() { + return this.events; + } + + /** + * Set the events value. + * + * @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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrackingRecordType.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrackingRecordType.java new file mode 100644 index 000000000000..71d9bcbabfff --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrailingSeparatorPolicy.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/TrailingSeparatorPolicy.java new file mode 100644 index 000000000000..d6e2068d10ae --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/UsageIndicator.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/UsageIndicator.java new file mode 100644 index 000000000000..01db7aaf5102 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Workflow.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Workflow.java new file mode 100644 index 000000000000..e090ede51823 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Workflow.java @@ -0,0 +1,220 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview; + +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.v2018_07_01_preview.implementation.LogicManager; +import org.joda.time.DateTime; +import java.util.Map; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.WorkflowInner; + +/** + * Type representing Workflow. + */ +public interface Workflow extends HasInner, Resource, GroupableResourceCore, HasResourceGroup, Refreshable, Updatable, HasManager { + /** + * @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 integrationAccount value. + */ + ResourceReference integrationAccount(); + + /** + * @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 update allowing to specify Definition. + */ + interface WithDefinition { + /** + * Specifies definition. + */ + WithCreate withDefinition(Object definition); + } + + /** + * The stage of the workflow update allowing to specify IntegrationAccount. + */ + interface WithIntegrationAccount { + /** + * Specifies integrationAccount. + */ + WithCreate withIntegrationAccount(ResourceReference integrationAccount); + } + + /** + * The stage of the workflow update allowing to specify Parameters. + */ + interface WithParameters { + /** + * Specifies parameters. + */ + WithCreate withParameters(Map parameters); + } + + /** + * The stage of the workflow update allowing to specify Sku. + */ + interface WithSku { + /** + * Specifies sku. + */ + WithCreate withSku(Sku sku); + } + + /** + * The stage of the workflow update allowing to specify State. + */ + interface WithState { + /** + * Specifies state. + */ + 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.WithDefinition, DefinitionStages.WithIntegrationAccount, DefinitionStages.WithParameters, DefinitionStages.WithSku, DefinitionStages.WithState { + } + } + /** + * The template for a Workflow update operation, containing all the settings that can be modified. + */ + interface Update extends Appliable, Resource.UpdateWithTags, UpdateStages.WithDefinition, UpdateStages.WithIntegrationAccount, UpdateStages.WithParameters, UpdateStages.WithSku, UpdateStages.WithState { + } + + /** + * Grouping of Workflow update stages. + */ + interface UpdateStages { + /** + * The stage of the workflow {0} allowing to specify Definition. + */ + interface WithDefinition { + /** + * Specifies definition. + */ + Update withDefinition(Object definition); + } + + /** + * The stage of the workflow {0} allowing to specify IntegrationAccount. + */ + interface WithIntegrationAccount { + /** + * Specifies integrationAccount. + */ + Update withIntegrationAccount(ResourceReference integrationAccount); + } + + /** + * The stage of the workflow {0} allowing to specify Parameters. + */ + interface WithParameters { + /** + * Specifies parameters. + */ + Update withParameters(Map parameters); + } + + /** + * The stage of the workflow {0} allowing to specify Sku. + */ + interface WithSku { + /** + * Specifies sku. + */ + Update withSku(Sku sku); + } + + /** + * The stage of the workflow {0} allowing to specify State. + */ + interface WithState { + /** + * Specifies state. + */ + Update withState(WorkflowState state); + } + + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowFilter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowFilter.java new file mode 100644 index 000000000000..6ed87245eaf7 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowOutputParameter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowOutputParameter.java new file mode 100644 index 000000000000..f2b6fe841126 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowParameter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowParameter.java new file mode 100644 index 000000000000..5066a8680572 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowProvisioningState.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowProvisioningState.java new file mode 100644 index 000000000000..6813d5a59d3e --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowProvisioningState.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.v2018_07_01_preview; + +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"); + + /** + * 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunAction.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunAction.java new file mode 100644 index 000000000000..52827a483e08 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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. + */ + Correlation 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunActionFilter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunActionFilter.java new file mode 100644 index 000000000000..2df8fba48e68 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunActionRepetitionDefinitionCollection.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunActionRepetitionDefinitionCollection.java new file mode 100644 index 000000000000..a5394e90dc55 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunActionRepetitionDefinitionCollection.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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.WorkflowRunActionRepetitionDefinitionCollectionInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.WorkflowRunActionRepetitionDefinitionInner; +import java.util.List; + +/** + * Type representing WorkflowRunActionRepetitionDefinitionCollection. + */ +public interface WorkflowRunActionRepetitionDefinitionCollection extends HasInner, HasManager { + /** + * @return the value value. + */ + List value(); + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunActionRepetitions.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunActionRepetitions.java new file mode 100644 index 000000000000..99b0e160614b --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunActionScopeRepetitions.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunActionScopeRepetitions.java new file mode 100644 index 000000000000..257efa37116f --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.WorkflowRunActionScopeRepetitionsInner; +import com.microsoft.azure.arm.model.HasInner; + +/** + * Type representing WorkflowRunActionScopeRepetitions. + */ +public interface WorkflowRunActionScopeRepetitions extends HasInner { + /** + * 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); + + /** + * 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); + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunActions.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunActions.java new file mode 100644 index 000000000000..918adecc09e1 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunFilter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunFilter.java new file mode 100644 index 000000000000..989ede86628c --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunOperations.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunOperations.java new file mode 100644 index 000000000000..67aa8106cb59 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunTrigger.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRunTrigger.java new file mode 100644 index 000000000000..101b0d62bf9d --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRuns.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowRuns.java new file mode 100644 index 000000000000..dcb60a663085 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import rx.Observable; +import rx.Completable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowState.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowState.java new file mode 100644 index 000000000000..11db780cc79a --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowStatus.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowStatus.java new file mode 100644 index 000000000000..d7feb4a5c5ae --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTrigger.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTrigger.java new file mode 100644 index 000000000000..344059d4b5c2 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerCallbackUrl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerCallbackUrl.java new file mode 100644 index 000000000000..ec269d338102 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.arm.resources.models.HasManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.LogicManager; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerFilter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerFilter.java new file mode 100644 index 000000000000..26e08935a4d4 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerHistories.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerHistories.java new file mode 100644 index 000000000000..631b11484815 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import rx.Observable; +import rx.Completable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerHistory.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerHistory.java new file mode 100644 index 000000000000..6b49b2809bf0 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerHistory.java @@ -0,0 +1,93 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerHistoryFilter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerHistoryFilter.java new file mode 100644 index 000000000000..eb3ec3a99034 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerListCallbackUrlQueries.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerListCallbackUrlQueries.java new file mode 100644 index 000000000000..dc824ab49c17 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerProvisioningState.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerProvisioningState.java new file mode 100644 index 000000000000..6b2948c6a5f6 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerRecurrence.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggerRecurrence.java new file mode 100644 index 000000000000..4c939174fb7d --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggers.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggers.java new file mode 100644 index 000000000000..a0836ae5a4d7 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowTriggers.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.v2018_07_01_preview; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTrigger; +import rx.Completable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.implementation.WorkflowTriggerInner; + +/** + * 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 WorkflowTriggerInner value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable setStateAsync(String resourceGroupName, String workflowName, String triggerName, WorkflowTriggerInner 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowVersion.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowVersion.java new file mode 100644 index 000000000000..d096eecbc56f --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowVersion.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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.implementation.LogicManager; +import org.joda.time.DateTime; +import java.util.Map; + +/** + * Type representing WorkflowVersion. + */ +public interface WorkflowVersion extends HasInner, Indexable, Refreshable, HasManager { + /** + * @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 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 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowVersionTriggers.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowVersionTriggers.java new file mode 100644 index 000000000000..8ae53f477eca --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowVersions.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowVersions.java new file mode 100644 index 000000000000..b286f6ff774a --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowWorkflowRun.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/WorkflowWorkflowRun.java new file mode 100644 index 000000000000..3bfe5318f5b8 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +import com.microsoft.azure.arm.model.HasInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Workflows.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Workflows.java new file mode 100644 index 000000000000..a1e8d6b74c5f --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/Workflows.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.v2018_07_01_preview; + +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.v2018_07_01_preview.implementation.WorkflowInner; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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 + */ + Completable 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 + */ + Completable listSwaggerAsync(String resourceGroupName, String workflowName); + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param move The workflow to move. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable moveAsync(String resourceGroupName, String workflowName, WorkflowInner move); + + /** + * 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 workflow The workflow definition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable for the request + */ + Completable validateByLocationAsync(String resourceGroupName, String location, String workflowName, WorkflowInner workflow); + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12AcknowledgementSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12AcknowledgementSettings.java new file mode 100644 index 000000000000..86f2baa234c3 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12AgreementContent.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12AgreementContent.java new file mode 100644 index 000000000000..cdadab41b1d2 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12CharacterSet.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12CharacterSet.java new file mode 100644 index 000000000000..c8aa29a3cdfa --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12DateFormat.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12DateFormat.java new file mode 100644 index 000000000000..e1dba6ff75c1 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12DelimiterOverrides.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12DelimiterOverrides.java new file mode 100644 index 000000000000..fa34d0aff1d5 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12EnvelopeOverride.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12EnvelopeOverride.java new file mode 100644 index 000000000000..63341c06f63e --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12EnvelopeSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12EnvelopeSettings.java new file mode 100644 index 000000000000..ba9d0192619b --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12FramingSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12FramingSettings.java new file mode 100644 index 000000000000..f14b0c82f6bc --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12MessageFilter.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12MessageFilter.java new file mode 100644 index 000000000000..da3176279f34 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12MessageIdentifier.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12MessageIdentifier.java new file mode 100644 index 000000000000..8d434c4cfae7 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12OneWayAgreement.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12OneWayAgreement.java new file mode 100644 index 000000000000..16d231fdd5c0 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12ProcessingSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12ProcessingSettings.java new file mode 100644 index 000000000000..1f97625866f5 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12ProtocolSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12ProtocolSettings.java new file mode 100644 index 000000000000..05951d7ef5c8 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12SchemaReference.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12SchemaReference.java new file mode 100644 index 000000000000..490e303c2347 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12SecuritySettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12SecuritySettings.java new file mode 100644 index 000000000000..9fca338d7e69 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12TimeFormat.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12TimeFormat.java new file mode 100644 index 000000000000..be9ade557347 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12ValidationOverride.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12ValidationOverride.java new file mode 100644 index 000000000000..225ba3c2142b --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12ValidationSettings.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/X12ValidationSettings.java new file mode 100644 index 000000000000..af2a9a2ef721 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview; + +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionImpl.java new file mode 100644 index 000000000000..95ad289cd63f --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionImpl.java @@ -0,0 +1,154 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.ActionRunWorkflowWorkflowRunActionRepetitionDefinition; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.RunActionCorrelation; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ContentLink; +import java.util.List; +import com.microsoft.azure.management.logic.v2018_07_01_preview.RepetitionIndex; +import com.microsoft.azure.management.logic.v2018_07_01_preview.RetryHistory; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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; + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModelImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModelImpl.java new file mode 100644 index 000000000000..a5c1360f3833 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModelImpl.java @@ -0,0 +1,154 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.RunActionCorrelation; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ContentLink; +import java.util.List; +import com.microsoft.azure.management.logic.v2018_07_01_preview.RepetitionIndex; +import com.microsoft.azure.management.logic.v2018_07_01_preview.RetryHistory; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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; + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/AssemblyDefinitionImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/AssemblyDefinitionImpl.java new file mode 100644 index 000000000000..f1a46a1f9420 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.AssemblyDefinition; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import java.util.Map; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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(); + // resource ancestor names + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/AssemblyDefinitionInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/AssemblyDefinitionInner.java new file mode 100644 index 000000000000..4e63bcd7b398 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/BatchConfigurationImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/BatchConfigurationImpl.java new file mode 100644 index 000000000000..598fb6cbb794 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.BatchConfiguration; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import java.util.Map; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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(); + // resource ancestor names + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/BatchConfigurationInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/BatchConfigurationInner.java new file mode 100644 index 000000000000..b1b0947f4bae --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/CallbackUrlImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/CallbackUrlImpl.java new file mode 100644 index 000000000000..fa35bb8c53b4 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/CallbackUrlInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/CallbackUrlInner.java new file mode 100644 index 000000000000..1575c6808bac --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/ExpressionRootImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/ExpressionRootImpl.java new file mode 100644 index 000000000000..46e61f5e6558 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.ExpressionRoot; +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.AzureResourceErrorInfo; +import java.util.List; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/ExpressionRootInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/ExpressionRootInner.java new file mode 100644 index 000000000000..ff84b8fc8e27 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Expression; + +/** + * The ExpressionRootInner model. + */ +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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IdParsingUtils.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IdParsingUtils.java new file mode 100644 index 000000000000..d630ee12795e --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAgreementImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAgreementImpl.java new file mode 100644 index 000000000000..fbc64c1e79df --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.AgreementType; +import com.microsoft.azure.management.logic.v2018_07_01_preview.BusinessIdentity; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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(); + // resource ancestor names + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAgreementInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAgreementInner.java new file mode 100644 index 000000000000..ad3007cb716e --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.AgreementType; +import com.microsoft.azure.management.logic.v2018_07_01_preview.BusinessIdentity; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAgreementsImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAgreementsImpl.java new file mode 100644 index 000000000000..d72ddcd79616 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAgreementsImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountAgreements; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public IntegrationAccountAgreement call(IntegrationAccountAgreementInner inner) { + return 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAgreementsInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAgreementsInner.java new file mode 100644 index 000000000000..9fafa69e12f5 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.CloudException; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAssembliesImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAssembliesImpl.java new file mode 100644 index 000000000000..cee6045a81ca --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAssembliesImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountAssemblies; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import java.util.List; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public AssemblyDefinition call(AssemblyDefinitionInner inner) { + return 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAssembliesInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountAssembliesInner.java new file mode 100644 index 000000000000..dfab183baa22 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.CloudException; +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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountBatchConfigurationsImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountBatchConfigurationsImpl.java new file mode 100644 index 000000000000..1322f591403a --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountBatchConfigurationsImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountBatchConfigurations; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import java.util.List; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public BatchConfiguration call(BatchConfigurationInner inner) { + return 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountBatchConfigurationsInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountBatchConfigurationsInner.java new file mode 100644 index 000000000000..5aa30273afb6 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.CloudException; +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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountCertificateImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountCertificateImpl.java new file mode 100644 index 000000000000..d6210ca5b146 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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(); + // resource ancestor names + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountCertificateInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountCertificateInner.java new file mode 100644 index 000000000000..77afab7aa80a --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountCertificatesImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountCertificatesImpl.java new file mode 100644 index 000000000000..e96bcf8c80f8 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountCertificatesImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountCertificates; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public IntegrationAccountCertificate call(IntegrationAccountCertificateInner inner) { + return 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountCertificatesInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountCertificatesInner.java new file mode 100644 index 000000000000..5674fa84fe87 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.CloudException; +import com.microsoft.azure.ListOperationCallback; +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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountImpl.java new file mode 100644 index 000000000000..314a2f4cabf7 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.resources.models.implementation.GroupableResourceCoreImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccount; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountSku; + +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 Object properties() { + return this.inner().properties(); + } + + @Override + public IntegrationAccountSku sku() { + return this.inner().sku(); + } + + @Override + public IntegrationAccountImpl withProperties(Object properties) { + this.inner().withProperties(properties); + return this; + } + + @Override + public IntegrationAccountImpl withSku(IntegrationAccountSku sku) { + this.inner().withSku(sku); + return this; + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountInner.java new file mode 100644 index 000000000000..cc0363719194 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountInner.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountSku; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.microsoft.rest.SkipParentValidation; +import com.microsoft.azure.Resource; + +/** + * The integration account. + */ +@SkipParentValidation +public class IntegrationAccountInner extends Resource { + /** + * The integration account properties. + */ + @JsonProperty(value = "properties") + private Object properties; + + /** + * The sku. + */ + @JsonProperty(value = "sku") + private IntegrationAccountSku sku; + + /** + * Get the integration account properties. + * + * @return the properties value + */ + public Object properties() { + return this.properties; + } + + /** + * Set the integration account properties. + * + * @param properties the properties value to set + * @return the IntegrationAccountInner object itself. + */ + public IntegrationAccountInner withProperties(Object properties) { + this.properties = properties; + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountMapImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountMapImpl.java new file mode 100644 index 000000000000..6d4135ebde20 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountMap; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import java.util.Map; +import com.microsoft.azure.management.logic.v2018_07_01_preview.MapType; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountMapPropertiesParametersSchema; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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(); + // resource ancestor names + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountMapInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountMapInner.java new file mode 100644 index 000000000000..d1283c1a8c1e --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.MapType; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountMapPropertiesParametersSchema; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountMapsImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountMapsImpl.java new file mode 100644 index 000000000000..08e2eccb04ec --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountMapsImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountMaps; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public IntegrationAccountMap call(IntegrationAccountMapInner inner) { + return 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountMapsInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountMapsInner.java new file mode 100644 index 000000000000..e624ae61f45e --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.CloudException; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountPartnerImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountPartnerImpl.java new file mode 100644 index 000000000000..1c2d76487247 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountPartner; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import java.util.Map; +import com.microsoft.azure.management.logic.v2018_07_01_preview.PartnerType; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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(); + // resource ancestor names + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountPartnerInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountPartnerInner.java new file mode 100644 index 000000000000..dd6b42d48282 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.PartnerType; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountPartnersImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountPartnersImpl.java new file mode 100644 index 000000000000..8b08c2e950c8 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountPartnersImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountPartners; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public IntegrationAccountPartner call(IntegrationAccountPartnerInner inner) { + return 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountPartnersInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountPartnersInner.java new file mode 100644 index 000000000000..9d8cfd155dcb --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.CloudException; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSchemaImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSchemaImpl.java new file mode 100644 index 000000000000..44c2d26ddd2b --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountSchema; +import com.microsoft.azure.arm.model.implementation.CreatableUpdatableImpl; +import rx.Observable; +import java.util.Map; +import com.microsoft.azure.management.logic.v2018_07_01_preview.SchemaType; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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(); + // resource ancestor names + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSchemaInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSchemaInner.java new file mode 100644 index 000000000000..1be10f6f2161 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.SchemaType; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSchemasImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSchemasImpl.java new file mode 100644 index 000000000000..5682bdac041a --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSchemasImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountSchemas; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public IntegrationAccountSchema call(IntegrationAccountSchemaInner inner) { + return 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSchemasInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSchemasInner.java new file mode 100644 index 000000000000..4b9624592f21 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.CloudException; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSessionImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSessionImpl.java new file mode 100644 index 000000000000..205b7823368d --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.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(); + // resource ancestor names + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSessionInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSessionInner.java new file mode 100644 index 000000000000..7ec5c8f1ac17 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSessionsImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSessionsImpl.java new file mode 100644 index 000000000000..83702e1fde6f --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSessionsImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountSessions; +import rx.Completable; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public IntegrationAccountSession call(IntegrationAccountSessionInner inner) { + return 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSessionsInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountSessionsInner.java new file mode 100644 index 000000000000..c124c2fe26a5 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountsImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountsImpl.java new file mode 100644 index 000000000000..cfc7456d8115 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.resources.collection.implementation.GroupableResourcesCoreImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccounts; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.CallbackUrl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.KeyVaultKey; +import com.microsoft.azure.management.logic.v2018_07_01_preview.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ListKeyVaultKeysDefinition; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountsInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/IntegrationAccountsInner.java new file mode 100644 index 000000000000..51f200f754e4 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.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.CloudException; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2018_07_01_preview.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2018_07_01_preview.KeyType; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ListKeyVaultKeysDefinition; +import com.microsoft.azure.management.logic.v2018_07_01_preview.RegenerateActionParameter; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/JsonSchemaImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/JsonSchemaImpl.java new file mode 100644 index 000000000000..36249162c161 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/JsonSchemaInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/JsonSchemaInner.java new file mode 100644 index 000000000000..5decfbff9c60 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/KeyVaultKeyImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/KeyVaultKeyImpl.java new file mode 100644 index 000000000000..8b7d630e73a7 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.KeyVaultKey; +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/KeyVaultKeyInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/KeyVaultKeyInner.java new file mode 100644 index 000000000000..e469f92eaba5 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/LogicManagementClientImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/LogicManagementClientImpl.java new file mode 100644 index 000000000000..0277166998ee --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/LogicManagementClientImpl.java @@ -0,0 +1,462 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.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; + } + + /** Gets or sets the preferred language for the response. */ + private String acceptLanguage; + + /** + * Gets Gets or sets the preferred language for the response. + * + * @return the acceptLanguage value. + */ + public String acceptLanguage() { + return this.acceptLanguage; + } + + /** + * Sets Gets or 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; + } + + /** Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30. */ + private int longRunningOperationRetryTimeout; + + /** + * Gets Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30. + * + * @return the longRunningOperationRetryTimeout value. + */ + public int longRunningOperationRetryTimeout() { + return this.longRunningOperationRetryTimeout; + } + + /** + * Sets Gets or 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; + } + + /** 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 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 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 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 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 = "2018-07-01-preview"; + 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.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.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)", super.userAgent(), "LogicManagementClient", "2018-07-01-preview"); + } +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/LogicManager.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/LogicManager.java new file mode 100644 index 000000000000..2af0b89f16f7 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/LogicManager.java @@ -0,0 +1,327 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.Workflows; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowVersions; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggers; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowVersionTriggers; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerHistories; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRuns; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunActions; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunActionRepetitions; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunActionScopeRepetitions; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunOperations; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccounts; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountAssemblies; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountBatchConfigurations; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountSchemas; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountMaps; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountPartners; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountAgreements; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountCertificates; +import com.microsoft.azure.management.logic.v2018_07_01_preview.IntegrationAccountSessions; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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 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 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 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 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/OperationImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/OperationImpl.java new file mode 100644 index 000000000000..e2c1fffcca23 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/OperationImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.Operation; +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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(); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/OperationInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/OperationInner.java new file mode 100644 index 000000000000..d5014c98a207 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/OperationInner.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.OperationDisplay; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Logic REST API operation. + */ +public class OperationInner { + /** + * Operation name: {provider}/{resource}/{operation}. + */ + @JsonProperty(value = "name") + private String name; + + /** + * The object that represents the operation. + */ + @JsonProperty(value = "display") + private OperationDisplay display; + + /** + * 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; + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/OperationsImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/OperationsImpl.java new file mode 100644 index 000000000000..48d5582a6f79 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Operations; +import rx.functions.Func1; +import rx.Observable; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/OperationsInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/OperationsInner.java new file mode 100644 index 000000000000..5b6559320ca2 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/PageImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/PageImpl.java new file mode 100644 index 000000000000..e80bff031e04 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/PageImpl1.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/PageImpl1.java new file mode 100644 index 000000000000..9d56ed14a279 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/PageImpl2.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/PageImpl2.java new file mode 100644 index 000000000000..730271be0c07 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/RunWorkflowWorkflowRunImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/RunWorkflowWorkflowRunImpl.java new file mode 100644 index 000000000000..3fd48f074721 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/RunWorkflowWorkflowRunImpl.java @@ -0,0 +1,126 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.RunWorkflowWorkflowRun; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Correlation; +import org.joda.time.DateTime; +import java.util.Map; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowOutputParameter; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunTrigger; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowStatus; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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; + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowImpl.java new file mode 100644 index 000000000000..04766c6e225e --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.resources.models.implementation.GroupableResourceCoreImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Workflow; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowProvisioningState; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowState; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Sku; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ResourceReference; +import java.util.Map; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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(), this.inner()) + .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 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 ResourceReference integrationAccount() { + return this.inner().integrationAccount(); + } + + @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 withDefinition(Object definition) { + this.inner().withDefinition(definition); + return this; + } + + @Override + public WorkflowImpl withIntegrationAccount(ResourceReference integrationAccount) { + this.inner().withIntegrationAccount(integrationAccount); + return this; + } + + @Override + public WorkflowImpl withParameters(Map parameters) { + this.inner().withParameters(parameters); + return this; + } + + @Override + public WorkflowImpl withSku(Sku sku) { + this.inner().withSku(sku); + return this; + } + + @Override + public WorkflowImpl withState(WorkflowState state) { + this.inner().withState(state); + return this; + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowInner.java new file mode 100644 index 000000000000..dc1965467257 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowInner.java @@ -0,0 +1,239 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowProvisioningState; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowState; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Sku; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ResourceReference; +import java.util.Map; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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'. + */ + @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 sku. + */ + @JsonProperty(value = "properties.sku") + 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 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 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 sku. + * + * @return the sku value + */ + public Sku sku() { + return this.sku; + } + + /** + * Set the sku. + * + * @param sku the sku value to set + * @return the WorkflowInner object itself. + */ + public WorkflowInner withSku(Sku sku) { + this.sku = sku; + return this; + } + + /** + * 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 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionImpl.java new file mode 100644 index 000000000000..87e07c11b96f --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionImpl.java @@ -0,0 +1,120 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunAction; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Correlation; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ContentLink; +import java.util.List; +import com.microsoft.azure.management.logic.v2018_07_01_preview.RetryHistory; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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; + 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 Correlation 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionInner.java new file mode 100644 index 000000000000..fd9a5736d56f --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowStatus; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Correlation; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ContentLink; +import java.util.List; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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 Correlation 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 Correlation correlation() { + return this.correlation; + } + + /** + * Set the correlation properties. + * + * @param correlation the correlation value to set + * @return the WorkflowRunActionInner object itself. + */ + public WorkflowRunActionInner withCorrelation(Correlation 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionRepetitionDefinitionCollectionImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionRepetitionDefinitionCollectionImpl.java new file mode 100644 index 000000000000..d8d340d278b4 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionRepetitionDefinitionCollectionImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunActionRepetitionDefinitionCollection; +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import java.util.List; + +class WorkflowRunActionRepetitionDefinitionCollectionImpl extends WrapperImpl implements WorkflowRunActionRepetitionDefinitionCollection { + private final LogicManager manager; + WorkflowRunActionRepetitionDefinitionCollectionImpl(WorkflowRunActionRepetitionDefinitionCollectionInner inner, LogicManager manager) { + super(inner); + this.manager = manager; + } + + @Override + public LogicManager manager() { + return this.manager; + } + + @Override + public List value() { + return this.inner().value(); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionRepetitionDefinitionCollectionInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionRepetitionDefinitionCollectionInner.java new file mode 100644 index 000000000000..1b5883dce0ed --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionRepetitionDefinitionCollectionInner.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.v2018_07_01_preview.implementation; + +import java.util.List; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * A collection of workflow run action repetitions. + */ +public class WorkflowRunActionRepetitionDefinitionCollectionInner { + /** + * The value property. + */ + @JsonProperty(value = "value") + private List value; + + /** + * Get the value value. + * + * @return the value value + */ + public List value() { + return this.value; + } + + /** + * Set the value value. + * + * @param value the value value to set + * @return the WorkflowRunActionRepetitionDefinitionCollectionInner object itself. + */ + public WorkflowRunActionRepetitionDefinitionCollectionInner withValue(List value) { + this.value = value; + return this; + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionRepetitionDefinitionInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionRepetitionDefinitionInner.java new file mode 100644 index 000000000000..b8bc7092283d --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.RunActionCorrelation; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowStatus; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ContentLink; +import java.util.List; +import com.microsoft.azure.management.logic.v2018_07_01_preview.RetryHistory; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionRepetitionsImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionRepetitionsImpl.java new file mode 100644 index 000000000000..af9ed4f1c091 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionRepetitionsImpl.java @@ -0,0 +1,84 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunActionRepetitions; +import rx.Observable; +import rx.functions.Func1; +import java.util.List; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ExpressionRoot; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public ActionRunWorkflowWorkflowRunActionRepetitionDefinition call(WorkflowRunActionRepetitionDefinitionInner inner) { + return wrapModel(inner); + } + }); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionRepetitionsInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionRepetitionsInner.java new file mode 100644 index 000000000000..8dcd1846c0ca --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.CloudException; +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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionScopeRepetitionsImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionScopeRepetitionsImpl.java new file mode 100644 index 000000000000..1daab2ed07ec --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionScopeRepetitionsImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunActionScopeRepetitions; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunActionRepetitionDefinitionCollection; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public WorkflowRunActionRepetitionDefinitionCollection call(WorkflowRunActionRepetitionDefinitionCollectionInner inner) { + return new WorkflowRunActionRepetitionDefinitionCollectionImpl(inner, manager()); + } + }); + } + + @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) + .map(new Func1() { + @Override + public ActionRunWorkflowWorkflowRunActionRepetitionDefinitionModel call(WorkflowRunActionRepetitionDefinitionInner inner) { + return wrapModel(inner); + } + }); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionScopeRepetitionsInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionScopeRepetitionsInner.java new file mode 100644 index 000000000000..ad0e30c2adef --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionScopeRepetitionsInner.java @@ -0,0 +1,271 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.CloudException; +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 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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException thrown if the request is rejected by server + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent + * @return the WorkflowRunActionRepetitionDefinitionCollectionInner object if successful. + */ + public WorkflowRunActionRepetitionDefinitionCollectionInner 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 WorkflowRunActionRepetitionDefinitionCollectionInner object + */ + public Observable listAsync(String resourceGroupName, String workflowName, String runName, String actionName) { + return listWithServiceResponseAsync(resourceGroupName, workflowName, runName, actionName).map(new Func1, WorkflowRunActionRepetitionDefinitionCollectionInner>() { + @Override + public WorkflowRunActionRepetitionDefinitionCollectionInner 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 WorkflowRunActionRepetitionDefinitionCollectionInner 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 clientResponse = listDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse listDelegate(Response response) throws CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionsImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionsImpl.java new file mode 100644 index 000000000000..a39852094242 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionsImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunActions; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import java.util.List; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ExpressionRoot; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public WorkflowRunAction call(WorkflowRunActionInner inner) { + return wrapModel(inner); + } + }); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionsInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunActionsInner.java new file mode 100644 index 000000000000..683121a3e74d --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.CloudException; +import com.microsoft.azure.ListOperationCallback; +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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunInner.java new file mode 100644 index 000000000000..fd1d9d94c000 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowStatus; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Correlation; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ResourceReference; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunTrigger; +import java.util.Map; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunOperationsImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunOperationsImpl.java new file mode 100644 index 000000000000..6d26a710cef6 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunOperationsImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunOperations; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public RunWorkflowWorkflowRun call(WorkflowRunInner inner) { + return wrapModel(inner); + } + }); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunOperationsInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunOperationsInner.java new file mode 100644 index 000000000000..f3f66315ee6a --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.CloudException; +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.v2018_07_01_preview.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunsImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunsImpl.java new file mode 100644 index 000000000000..b6a1bf12a6eb --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunsImpl.java @@ -0,0 +1,72 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRuns; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import rx.Completable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public WorkflowWorkflowRun call(WorkflowRunInner inner) { + return wrapModel(inner); + } + }); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunsInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowRunsInner.java new file mode 100644 index 000000000000..155417f9c6b2 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.CloudException; +import com.microsoft.azure.ListOperationCallback; +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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerCallbackUrlImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerCallbackUrlImpl.java new file mode 100644 index 000000000000..4eaee9ddcf2c --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerCallbackUrlInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerCallbackUrlInner.java new file mode 100644 index 000000000000..99765b1d6184 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import java.util.List; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerHistoriesImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerHistoriesImpl.java new file mode 100644 index 000000000000..c2825d0f6a4a --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerHistoriesImpl.java @@ -0,0 +1,72 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerHistories; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import rx.Completable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public WorkflowTriggerHistory call(WorkflowTriggerHistoryInner inner) { + return wrapModel(inner); + } + }); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerHistoriesInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerHistoriesInner.java new file mode 100644 index 000000000000..1e18d01e8e1d --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.CloudException; +import com.microsoft.azure.ListOperationCallback; +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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(202, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerHistoryImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerHistoryImpl.java new file mode 100644 index 000000000000..6ce09409ae91 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerHistoryImpl.java @@ -0,0 +1,119 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerHistory; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Correlation; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ContentLink; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ResourceReference; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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; + 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 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerHistoryInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerHistoryInner.java new file mode 100644 index 000000000000..ad5e4c5cad27 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerHistoryInner.java @@ -0,0 +1,233 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowStatus; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Correlation; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ContentLink; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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; + + /** + * 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; + + /** + * Gets a 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 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 gets a 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerImpl.java new file mode 100644 index 000000000000..9968fcdb9337 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerImpl.java @@ -0,0 +1,108 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTrigger; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerProvisioningState; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerRecurrence; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowState; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowStatus; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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; + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggerInner.java new file mode 100644 index 000000000000..ca599cb6ddbc --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerProvisioningState; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowState; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowStatus; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerRecurrence; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggersImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggersImpl.java new file mode 100644 index 000000000000..4f94409dc9f7 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggersImpl.java @@ -0,0 +1,118 @@ +/** + * Copyright (c) Microsoft Corporation. All rights 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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggers; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTrigger; +import com.microsoft.azure.Page; +import rx.Completable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public WorkflowTrigger call(WorkflowTriggerInner inner) { + return 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, WorkflowTriggerInner 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggersInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggersInner.java new file mode 100644 index 000000000000..1939983397e6 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowTriggersInner.java @@ -0,0 +1,1026 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.CloudException; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2018_07_01_preview.SetTriggerStateActionDefinition; +import com.microsoft.azure.Page; +import com.microsoft.azure.PagedList; +import com.microsoft.rest.RestException; +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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 RestException 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 run(String resourceGroupName, String workflowName, String triggerName) { + return 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 observable to the Object object + */ + public Observable runAsync(String resourceGroupName, String workflowName, String triggerName) { + return runWithServiceResponseAsync(resourceGroupName, workflowName, triggerName).map(new Func1, Object>() { + @Override + public Object 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 observable to the Object object + */ + 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 RestException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .registerError(RestException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 WorkflowTriggerInner value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws CloudException 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, WorkflowTriggerInner 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 WorkflowTriggerInner 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 setStateAsync(String resourceGroupName, String workflowName, String triggerName, WorkflowTriggerInner 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 WorkflowTriggerInner value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable setStateAsync(String resourceGroupName, String workflowName, String triggerName, WorkflowTriggerInner 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 WorkflowTriggerInner value + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> setStateWithServiceResponseAsync(String resourceGroupName, String workflowName, String triggerName, WorkflowTriggerInner 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionImpl.java new file mode 100644 index 000000000000..9761c220cb4f --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionImpl.java @@ -0,0 +1,118 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowVersion; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ResourceReference; +import java.util.Map; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowParameter; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Sku; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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; + 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 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 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 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionInner.java new file mode 100644 index 000000000000..bc2a2f567d0f --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionInner.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.v2018_07_01_preview.implementation; + +import org.joda.time.DateTime; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowState; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Sku; +import com.microsoft.azure.management.logic.v2018_07_01_preview.ResourceReference; +import java.util.Map; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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 { + /** + * 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 sku. + */ + @JsonProperty(value = "properties.sku") + 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 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 sku. + * + * @return the sku value + */ + public Sku sku() { + return this.sku; + } + + /** + * Set the sku. + * + * @param sku the sku value to set + * @return the WorkflowVersionInner object itself. + */ + public WorkflowVersionInner withSku(Sku sku) { + this.sku = sku; + return this; + } + + /** + * 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionTriggersImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionTriggersImpl.java new file mode 100644 index 000000000000..2d7b709490a4 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowVersionTriggers; +import rx.functions.Func1; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionTriggersInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionTriggersInner.java new file mode 100644 index 000000000000..79413b7babcb --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.CloudException; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionsImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionsImpl.java new file mode 100644 index 000000000000..d050204f1280 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionsImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.model.implementation.WrapperImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowVersions; +import rx.Observable; +import rx.functions.Func1; +import com.microsoft.azure.Page; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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) + .map(new Func1() { + @Override + public WorkflowVersion call(WorkflowVersionInner inner) { + return wrapModel(inner); + } + }); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionsInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowVersionsInner.java new file mode 100644 index 000000000000..00631ce8586d --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import retrofit2.Retrofit; +import com.google.common.reflect.TypeToken; +import com.microsoft.azure.AzureServiceFuture; +import com.microsoft.azure.CloudException; +import com.microsoft.azure.ListOperationCallback; +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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowWorkflowRunImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowWorkflowRunImpl.java new file mode 100644 index 000000000000..1308e078440b --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowWorkflowRunImpl.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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowWorkflowRun; +import com.microsoft.azure.arm.model.implementation.IndexableRefreshableWrapperImpl; +import rx.Observable; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Correlation; +import org.joda.time.DateTime; +import java.util.Map; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowOutputParameter; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowRunTrigger; +import com.microsoft.azure.management.logic.v2018_07_01_preview.WorkflowStatus; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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; + 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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowsImpl.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowsImpl.java new file mode 100644 index 000000000000..85a7027a82f7 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; + +import com.microsoft.azure.arm.resources.collection.implementation.GroupableResourcesCoreImpl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.Workflows; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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.v2018_07_01_preview.WorkflowTriggerCallbackUrl; +import com.microsoft.azure.management.logic.v2018_07_01_preview.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 Completable generateUpgradedDefinitionAsync(String resourceGroupName, String workflowName) { + WorkflowsInner client = this.inner(); + return client.generateUpgradedDefinitionAsync(resourceGroupName, workflowName).toCompletable(); + } + + @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 Completable listSwaggerAsync(String resourceGroupName, String workflowName) { + WorkflowsInner client = this.inner(); + return client.listSwaggerAsync(resourceGroupName, workflowName).toCompletable(); + } + + @Override + public Completable moveAsync(String resourceGroupName, String workflowName, WorkflowInner move) { + WorkflowsInner client = this.inner(); + return client.moveAsync(resourceGroupName, workflowName, move).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 workflow) { + WorkflowsInner client = this.inner(); + return client.validateByLocationAsync(resourceGroupName, location, workflowName, workflow).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/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowsInner.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowsInner.java new file mode 100644 index 000000000000..18d2452e4fa4 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/WorkflowsInner.java @@ -0,0 +1,2163 @@ +/** + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for + * license information. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + */ + +package com.microsoft.azure.management.logic.v2018_07_01_preview.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.CloudException; +import com.microsoft.azure.ListOperationCallback; +import com.microsoft.azure.management.logic.v2018_07_01_preview.GenerateUpgradedDefinitionParameters; +import com.microsoft.azure.management.logic.v2018_07_01_preview.GetCallbackUrlParameters; +import com.microsoft.azure.management.logic.v2018_07_01_preview.KeyType; +import com.microsoft.azure.management.logic.v2018_07_01_preview.RegenerateActionParameter; +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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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, @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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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, @Body WorkflowInner move, @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.v2018_07_01_preview.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.v2018_07_01_preview.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.v2018_07_01_preview.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, @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.v2018_07_01_preview.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.v2018_07_01_preview.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(201, new TypeToken() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + + /** + * 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 CloudException 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, WorkflowInner workflow) { + return updateWithServiceResponseAsync(resourceGroupName, workflowName, workflow).toBlocking().single().body(); + } + + /** + * 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 updateAsync(String resourceGroupName, String workflowName, WorkflowInner workflow, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(updateWithServiceResponseAsync(resourceGroupName, workflowName, workflow), serviceCallback); + } + + /** + * 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 updateAsync(String resourceGroupName, String workflowName, WorkflowInner workflow) { + return updateWithServiceResponseAsync(resourceGroupName, workflowName, workflow).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. + * @param workflow The workflow. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the observable to the WorkflowInner object + */ + public Observable> updateWithServiceResponseAsync(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.update(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 = updateDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse updateDelegate(Response response) throws CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(204, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param move The workflow to move. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws CloudException 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, WorkflowInner move) { + moveWithServiceResponseAsync(resourceGroupName, workflowName, move).toBlocking().single().body(); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param move The workflow to move. + * @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, WorkflowInner move, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(moveWithServiceResponseAsync(resourceGroupName, workflowName, move), serviceCallback); + } + + /** + * Moves an existing workflow. + * + * @param resourceGroupName The resource group name. + * @param workflowName The workflow name. + * @param move The workflow to move. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable moveAsync(String resourceGroupName, String workflowName, WorkflowInner move) { + return moveWithServiceResponseAsync(resourceGroupName, workflowName, move).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 move The workflow to move. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @return the {@link ServiceResponse} object if successful. + */ + public Observable> moveWithServiceResponseAsync(String resourceGroupName, String workflowName, WorkflowInner move) { + 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 (move == null) { + throw new IllegalArgumentException("Parameter move 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(move); + return service.move(this.client.subscriptionId(), resourceGroupName, workflowName, move, this.client.apiVersion(), this.client.acceptLanguage(), this.client.userAgent()) + .flatMap(new Func1, Observable>>() { + @Override + public Observable> call(Response response) { + try { + ServiceResponse clientResponse = moveDelegate(response); + return Observable.just(clientResponse); + } catch (Throwable t) { + return Observable.error(t); + } + } + }); + } + + private ServiceResponse moveDelegate(Response response) throws CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .register(202, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + + /** + * Validates the workflow definition. + * + * @param resourceGroupName The resource group name. + * @param location The workflow location. + * @param workflowName The workflow name. + * @param workflow The workflow definition. + * @throws IllegalArgumentException thrown if parameters fail the validation + * @throws CloudException 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 workflow) { + validateByLocationWithServiceResponseAsync(resourceGroupName, location, workflowName, workflow).toBlocking().single().body(); + } + + /** + * Validates the workflow definition. + * + * @param resourceGroupName The resource group name. + * @param location The workflow location. + * @param workflowName The workflow name. + * @param workflow The workflow definition. + * @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 workflow, final ServiceCallback serviceCallback) { + return ServiceFuture.fromResponse(validateByLocationWithServiceResponseAsync(resourceGroupName, location, workflowName, workflow), serviceCallback); + } + + /** + * Validates the workflow definition. + * + * @param resourceGroupName The resource group name. + * @param location The workflow location. + * @param workflowName The workflow name. + * @param workflow The workflow definition. + * @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 workflow) { + return validateByLocationWithServiceResponseAsync(resourceGroupName, location, workflowName, workflow).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 workflow The workflow definition. + * @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 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 (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 (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.validateByLocation(this.client.subscriptionId(), resourceGroupName, location, workflowName, this.client.apiVersion(), workflow, 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory().newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.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 CloudException 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 CloudException, IOException, IllegalArgumentException { + return this.client.restClient().responseBuilderFactory()., CloudException>newInstance(this.client.serializerAdapter()) + .register(200, new TypeToken>() { }.getType()) + .registerError(CloudException.class) + .build(response); + } + +} diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/package-info.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/implementation/package-info.java new file mode 100644 index 000000000000..a04f2c2d6de1 --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview.implementation; diff --git a/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/package-info.java b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/package-info.java new file mode 100644 index 000000000000..7068a38b8a9b --- /dev/null +++ b/logic/resource-manager/v2018_07_01_preview/src/main/java/com/microsoft/azure/management/logic/v2018_07_01_preview/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.v2018_07_01_preview;