|
| 1 | +// Template Source: BaseMethodParameterSet.java.tt |
| 2 | +// ------------------------------------------------------------------------------ |
| 3 | +// Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT License. See License in the project root for license information. |
| 4 | +// ------------------------------------------------------------------------------ |
| 5 | + |
| 6 | +package com.microsoft.graph.models; |
| 7 | + |
| 8 | +import com.microsoft.graph.models.Tone; |
| 9 | +import com.microsoft.graph.models.SendDtmfTonesOperation; |
| 10 | +import com.google.gson.annotations.Expose; |
| 11 | +import com.google.gson.annotations.SerializedName; |
| 12 | +import javax.annotation.Nonnull; |
| 13 | +import javax.annotation.Nullable; |
| 14 | +import com.google.gson.JsonObject; |
| 15 | +import java.util.EnumSet; |
| 16 | +import java.util.ArrayList; |
| 17 | + |
| 18 | +// **NOTE** This file was generated by a tool and any changes will be overwritten. |
| 19 | + |
| 20 | +/** |
| 21 | + * The class for the Call Send Dtmf Tones Parameter Set. |
| 22 | + */ |
| 23 | +public class CallSendDtmfTonesParameterSet { |
| 24 | + /** |
| 25 | + * The tones. |
| 26 | + * |
| 27 | + */ |
| 28 | + @SerializedName(value = "tones", alternate = {"Tones"}) |
| 29 | + @Expose |
| 30 | + @Nullable |
| 31 | + public java.util.List<Tone> tones; |
| 32 | + |
| 33 | + /** |
| 34 | + * The delay Between Tones Ms. |
| 35 | + * |
| 36 | + */ |
| 37 | + @SerializedName(value = "delayBetweenTonesMs", alternate = {"DelayBetweenTonesMs"}) |
| 38 | + @Expose |
| 39 | + @Nullable |
| 40 | + public Integer delayBetweenTonesMs; |
| 41 | + |
| 42 | + /** |
| 43 | + * The client Context. |
| 44 | + * |
| 45 | + */ |
| 46 | + @SerializedName(value = "clientContext", alternate = {"ClientContext"}) |
| 47 | + @Expose |
| 48 | + @Nullable |
| 49 | + public String clientContext; |
| 50 | + |
| 51 | + |
| 52 | + /** |
| 53 | + * Instiaciates a new CallSendDtmfTonesParameterSet |
| 54 | + */ |
| 55 | + public CallSendDtmfTonesParameterSet() {} |
| 56 | + /** |
| 57 | + * Instiaciates a new CallSendDtmfTonesParameterSet |
| 58 | + * @param builder builder bearing the parameters to initialize from |
| 59 | + */ |
| 60 | + protected CallSendDtmfTonesParameterSet(@Nonnull final CallSendDtmfTonesParameterSetBuilder builder) { |
| 61 | + this.tones = builder.tones; |
| 62 | + this.delayBetweenTonesMs = builder.delayBetweenTonesMs; |
| 63 | + this.clientContext = builder.clientContext; |
| 64 | + } |
| 65 | + /** |
| 66 | + * Gets a new builder for the body |
| 67 | + * @return a new builder |
| 68 | + */ |
| 69 | + @Nonnull |
| 70 | + public static CallSendDtmfTonesParameterSetBuilder newBuilder() { |
| 71 | + return new CallSendDtmfTonesParameterSetBuilder(); |
| 72 | + } |
| 73 | + /** |
| 74 | + * Fluent builder for the CallSendDtmfTonesParameterSet |
| 75 | + */ |
| 76 | + public static final class CallSendDtmfTonesParameterSetBuilder { |
| 77 | + /** |
| 78 | + * The tones parameter value |
| 79 | + */ |
| 80 | + @Nullable |
| 81 | + protected java.util.List<Tone> tones; |
| 82 | + /** |
| 83 | + * Sets the Tones |
| 84 | + * @param val the value to set it to |
| 85 | + * @return the current builder object |
| 86 | + */ |
| 87 | + @Nonnull |
| 88 | + public CallSendDtmfTonesParameterSetBuilder withTones(@Nullable final java.util.List<Tone> val) { |
| 89 | + this.tones = val; |
| 90 | + return this; |
| 91 | + } |
| 92 | + /** |
| 93 | + * The delayBetweenTonesMs parameter value |
| 94 | + */ |
| 95 | + @Nullable |
| 96 | + protected Integer delayBetweenTonesMs; |
| 97 | + /** |
| 98 | + * Sets the DelayBetweenTonesMs |
| 99 | + * @param val the value to set it to |
| 100 | + * @return the current builder object |
| 101 | + */ |
| 102 | + @Nonnull |
| 103 | + public CallSendDtmfTonesParameterSetBuilder withDelayBetweenTonesMs(@Nullable final Integer val) { |
| 104 | + this.delayBetweenTonesMs = val; |
| 105 | + return this; |
| 106 | + } |
| 107 | + /** |
| 108 | + * The clientContext parameter value |
| 109 | + */ |
| 110 | + @Nullable |
| 111 | + protected String clientContext; |
| 112 | + /** |
| 113 | + * Sets the ClientContext |
| 114 | + * @param val the value to set it to |
| 115 | + * @return the current builder object |
| 116 | + */ |
| 117 | + @Nonnull |
| 118 | + public CallSendDtmfTonesParameterSetBuilder withClientContext(@Nullable final String val) { |
| 119 | + this.clientContext = val; |
| 120 | + return this; |
| 121 | + } |
| 122 | + /** |
| 123 | + * Instanciates a new CallSendDtmfTonesParameterSetBuilder |
| 124 | + */ |
| 125 | + @Nullable |
| 126 | + protected CallSendDtmfTonesParameterSetBuilder(){} |
| 127 | + /** |
| 128 | + * Buils the resulting body object to be passed to the request |
| 129 | + * @return the body object to pass to the request |
| 130 | + */ |
| 131 | + @Nonnull |
| 132 | + public CallSendDtmfTonesParameterSet build() { |
| 133 | + return new CallSendDtmfTonesParameterSet(this); |
| 134 | + } |
| 135 | + } |
| 136 | + /** |
| 137 | + * Gets the functions options from the properties that have been set |
| 138 | + * @return a list of function options for the request |
| 139 | + */ |
| 140 | + @Nonnull |
| 141 | + public java.util.List<com.microsoft.graph.options.FunctionOption> getFunctionOptions() { |
| 142 | + final ArrayList<com.microsoft.graph.options.FunctionOption> result = new ArrayList<>(); |
| 143 | + if(this.tones != null) { |
| 144 | + result.add(new com.microsoft.graph.options.FunctionOption("tones", tones)); |
| 145 | + } |
| 146 | + if(this.delayBetweenTonesMs != null) { |
| 147 | + result.add(new com.microsoft.graph.options.FunctionOption("delayBetweenTonesMs", delayBetweenTonesMs)); |
| 148 | + } |
| 149 | + if(this.clientContext != null) { |
| 150 | + result.add(new com.microsoft.graph.options.FunctionOption("clientContext", clientContext)); |
| 151 | + } |
| 152 | + return result; |
| 153 | + } |
| 154 | +} |
0 commit comments