Пример #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="CreateOrderSubscriptionRequest" /> class.
 /// </summary>
 /// <param name="Name">The name of the subscription (required).</param>
 /// <param name="PayloadDelivered">Indicates if payload should be delivered.</param>
 /// <param name="Description">Description of the subscription (required).</param>
 /// <param name="Endpoint">Data to define the endpoint to which published messages should be sent for subscription (required).</param>
 /// <param name="AuthenticationCredentials">Authentication credentials needed for endpoint.</param>
 public CreateOrderSubscriptionRequest(string Name = default(string), bool?PayloadDelivered = default(bool?), string Description = default(string), UrlEndpointData Endpoint = default(UrlEndpointData), AuthenticationData AuthenticationCredentials = default(AuthenticationData))
 {
     // to ensure "Name" is required (not null)
     if (Name == null)
     {
         throw new InvalidDataException("Name is a required property for CreateOrderSubscriptionRequest and cannot be null");
     }
     else
     {
         this.Name = Name;
     }
     // to ensure "Description" is required (not null)
     if (Description == null)
     {
         throw new InvalidDataException("Description is a required property for CreateOrderSubscriptionRequest and cannot be null");
     }
     else
     {
         this.Description = Description;
     }
     // to ensure "Endpoint" is required (not null)
     if (Endpoint == null)
     {
         throw new InvalidDataException("Endpoint is a required property for CreateOrderSubscriptionRequest and cannot be null");
     }
     else
     {
         this.Endpoint = Endpoint;
     }
     this.PayloadDelivered          = PayloadDelivered;
     this.AuthenticationCredentials = AuthenticationCredentials;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="UrlSubscriptionViewData" /> class.
 /// </summary>
 /// <param name="Name">The name of the subscription (required).</param>
 /// <param name="Description">A description of the subscription (required).</param>
 /// <param name="TopicId">The topic to subscribe to messages from (required).</param>
 /// <param name="MessageAttributePatterns">The message attribute patterns to use when selecting messages published on a topic. If patterns are specified, the subscription will receive only those messages that are published with attributes that match the subscription&#39;s patterns. Each attribute pattern specified must be matched against the message&#39;s attribute values for the message to be delivered to the subscriber. Each message attribute pattern value must be a valid regular expression pattern.</param>
 /// <param name="PayloadDelivered">Indicates whether message payloads should be propagated to the subscribed endpoint. If false, the endpoint will be invoked without any payload data..</param>
 /// <param name="EnterpriseUnitId">The ID of the enterprise unit that will be used to filter messages.</param>
 /// <param name="Endpoint">The destination endpoint for the subscription (required).</param>
 public UrlSubscriptionViewData(string Name = default(string), string Description = default(string), TopicIdData TopicId = default(TopicIdData), List <KeyValueData> MessageAttributePatterns = default(List <KeyValueData>), bool?PayloadDelivered = default(bool?), string EnterpriseUnitId = default(string), UrlEndpointData Endpoint = default(UrlEndpointData))
 {
     // to ensure "Name" is required (not null)
     if (Name == null)
     {
         throw new InvalidDataException("Name is a required property for UrlSubscriptionViewData and cannot be null");
     }
     else
     {
         this.Name = Name;
     }
     // to ensure "Description" is required (not null)
     if (Description == null)
     {
         throw new InvalidDataException("Description is a required property for UrlSubscriptionViewData and cannot be null");
     }
     else
     {
         this.Description = Description;
     }
     // to ensure "TopicId" is required (not null)
     if (TopicId == null)
     {
         throw new InvalidDataException("TopicId is a required property for UrlSubscriptionViewData and cannot be null");
     }
     else
     {
         this.TopicId = TopicId;
     }
     // to ensure "Endpoint" is required (not null)
     if (Endpoint == null)
     {
         throw new InvalidDataException("Endpoint is a required property for UrlSubscriptionViewData and cannot be null");
     }
     else
     {
         this.Endpoint = Endpoint;
     }
     this.MessageAttributePatterns = MessageAttributePatterns;
     this.PayloadDelivered         = PayloadDelivered;
     this.EnterpriseUnitId         = EnterpriseUnitId;
 }