MachineToMachineOptions.php 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302
  1. <?php
  2. /**
  3. * This code was generated by
  4. * \ / _ _ _| _ _
  5. * | (_)\/(_)(_|\/| |(/_ v1.0.0
  6. * / /
  7. */
  8. namespace Twilio\Rest\Api\V2010\Account\AvailablePhoneNumberCountry;
  9. use Twilio\Options;
  10. use Twilio\Values;
  11. abstract class MachineToMachineOptions {
  12. /**
  13. * @param integer $areaCode The area_code
  14. * @param string $contains The contains
  15. * @param boolean $smsEnabled The sms_enabled
  16. * @param boolean $mmsEnabled The mms_enabled
  17. * @param boolean $voiceEnabled The voice_enabled
  18. * @param boolean $excludeAllAddressRequired The exclude_all_address_required
  19. * @param boolean $excludeLocalAddressRequired The
  20. * exclude_local_address_required
  21. * @param boolean $excludeForeignAddressRequired The
  22. * exclude_foreign_address_required
  23. * @param boolean $beta The beta
  24. * @param string $nearNumber The near_number
  25. * @param string $nearLatLong The near_lat_long
  26. * @param integer $distance The distance
  27. * @param string $inPostalCode The in_postal_code
  28. * @param string $inRegion The in_region
  29. * @param string $inRateCenter The in_rate_center
  30. * @param string $inLata The in_lata
  31. * @param string $inLocality The in_locality
  32. * @param boolean $faxEnabled The fax_enabled
  33. * @return ReadMachineToMachineOptions Options builder
  34. */
  35. public static function read($areaCode = Values::NONE, $contains = Values::NONE, $smsEnabled = Values::NONE, $mmsEnabled = Values::NONE, $voiceEnabled = Values::NONE, $excludeAllAddressRequired = Values::NONE, $excludeLocalAddressRequired = Values::NONE, $excludeForeignAddressRequired = Values::NONE, $beta = Values::NONE, $nearNumber = Values::NONE, $nearLatLong = Values::NONE, $distance = Values::NONE, $inPostalCode = Values::NONE, $inRegion = Values::NONE, $inRateCenter = Values::NONE, $inLata = Values::NONE, $inLocality = Values::NONE, $faxEnabled = Values::NONE) {
  36. return new ReadMachineToMachineOptions($areaCode, $contains, $smsEnabled, $mmsEnabled, $voiceEnabled, $excludeAllAddressRequired, $excludeLocalAddressRequired, $excludeForeignAddressRequired, $beta, $nearNumber, $nearLatLong, $distance, $inPostalCode, $inRegion, $inRateCenter, $inLata, $inLocality, $faxEnabled);
  37. }
  38. }
  39. class ReadMachineToMachineOptions extends Options {
  40. /**
  41. * @param integer $areaCode The area_code
  42. * @param string $contains The contains
  43. * @param boolean $smsEnabled The sms_enabled
  44. * @param boolean $mmsEnabled The mms_enabled
  45. * @param boolean $voiceEnabled The voice_enabled
  46. * @param boolean $excludeAllAddressRequired The exclude_all_address_required
  47. * @param boolean $excludeLocalAddressRequired The
  48. * exclude_local_address_required
  49. * @param boolean $excludeForeignAddressRequired The
  50. * exclude_foreign_address_required
  51. * @param boolean $beta The beta
  52. * @param string $nearNumber The near_number
  53. * @param string $nearLatLong The near_lat_long
  54. * @param integer $distance The distance
  55. * @param string $inPostalCode The in_postal_code
  56. * @param string $inRegion The in_region
  57. * @param string $inRateCenter The in_rate_center
  58. * @param string $inLata The in_lata
  59. * @param string $inLocality The in_locality
  60. * @param boolean $faxEnabled The fax_enabled
  61. */
  62. public function __construct($areaCode = Values::NONE, $contains = Values::NONE, $smsEnabled = Values::NONE, $mmsEnabled = Values::NONE, $voiceEnabled = Values::NONE, $excludeAllAddressRequired = Values::NONE, $excludeLocalAddressRequired = Values::NONE, $excludeForeignAddressRequired = Values::NONE, $beta = Values::NONE, $nearNumber = Values::NONE, $nearLatLong = Values::NONE, $distance = Values::NONE, $inPostalCode = Values::NONE, $inRegion = Values::NONE, $inRateCenter = Values::NONE, $inLata = Values::NONE, $inLocality = Values::NONE, $faxEnabled = Values::NONE) {
  63. $this->options['areaCode'] = $areaCode;
  64. $this->options['contains'] = $contains;
  65. $this->options['smsEnabled'] = $smsEnabled;
  66. $this->options['mmsEnabled'] = $mmsEnabled;
  67. $this->options['voiceEnabled'] = $voiceEnabled;
  68. $this->options['excludeAllAddressRequired'] = $excludeAllAddressRequired;
  69. $this->options['excludeLocalAddressRequired'] = $excludeLocalAddressRequired;
  70. $this->options['excludeForeignAddressRequired'] = $excludeForeignAddressRequired;
  71. $this->options['beta'] = $beta;
  72. $this->options['nearNumber'] = $nearNumber;
  73. $this->options['nearLatLong'] = $nearLatLong;
  74. $this->options['distance'] = $distance;
  75. $this->options['inPostalCode'] = $inPostalCode;
  76. $this->options['inRegion'] = $inRegion;
  77. $this->options['inRateCenter'] = $inRateCenter;
  78. $this->options['inLata'] = $inLata;
  79. $this->options['inLocality'] = $inLocality;
  80. $this->options['faxEnabled'] = $faxEnabled;
  81. }
  82. /**
  83. * The area_code
  84. *
  85. * @param integer $areaCode The area_code
  86. * @return $this Fluent Builder
  87. */
  88. public function setAreaCode($areaCode) {
  89. $this->options['areaCode'] = $areaCode;
  90. return $this;
  91. }
  92. /**
  93. * The contains
  94. *
  95. * @param string $contains The contains
  96. * @return $this Fluent Builder
  97. */
  98. public function setContains($contains) {
  99. $this->options['contains'] = $contains;
  100. return $this;
  101. }
  102. /**
  103. * The sms_enabled
  104. *
  105. * @param boolean $smsEnabled The sms_enabled
  106. * @return $this Fluent Builder
  107. */
  108. public function setSmsEnabled($smsEnabled) {
  109. $this->options['smsEnabled'] = $smsEnabled;
  110. return $this;
  111. }
  112. /**
  113. * The mms_enabled
  114. *
  115. * @param boolean $mmsEnabled The mms_enabled
  116. * @return $this Fluent Builder
  117. */
  118. public function setMmsEnabled($mmsEnabled) {
  119. $this->options['mmsEnabled'] = $mmsEnabled;
  120. return $this;
  121. }
  122. /**
  123. * The voice_enabled
  124. *
  125. * @param boolean $voiceEnabled The voice_enabled
  126. * @return $this Fluent Builder
  127. */
  128. public function setVoiceEnabled($voiceEnabled) {
  129. $this->options['voiceEnabled'] = $voiceEnabled;
  130. return $this;
  131. }
  132. /**
  133. * The exclude_all_address_required
  134. *
  135. * @param boolean $excludeAllAddressRequired The exclude_all_address_required
  136. * @return $this Fluent Builder
  137. */
  138. public function setExcludeAllAddressRequired($excludeAllAddressRequired) {
  139. $this->options['excludeAllAddressRequired'] = $excludeAllAddressRequired;
  140. return $this;
  141. }
  142. /**
  143. * The exclude_local_address_required
  144. *
  145. * @param boolean $excludeLocalAddressRequired The
  146. * exclude_local_address_required
  147. * @return $this Fluent Builder
  148. */
  149. public function setExcludeLocalAddressRequired($excludeLocalAddressRequired) {
  150. $this->options['excludeLocalAddressRequired'] = $excludeLocalAddressRequired;
  151. return $this;
  152. }
  153. /**
  154. * The exclude_foreign_address_required
  155. *
  156. * @param boolean $excludeForeignAddressRequired The
  157. * exclude_foreign_address_required
  158. * @return $this Fluent Builder
  159. */
  160. public function setExcludeForeignAddressRequired($excludeForeignAddressRequired) {
  161. $this->options['excludeForeignAddressRequired'] = $excludeForeignAddressRequired;
  162. return $this;
  163. }
  164. /**
  165. * The beta
  166. *
  167. * @param boolean $beta The beta
  168. * @return $this Fluent Builder
  169. */
  170. public function setBeta($beta) {
  171. $this->options['beta'] = $beta;
  172. return $this;
  173. }
  174. /**
  175. * The near_number
  176. *
  177. * @param string $nearNumber The near_number
  178. * @return $this Fluent Builder
  179. */
  180. public function setNearNumber($nearNumber) {
  181. $this->options['nearNumber'] = $nearNumber;
  182. return $this;
  183. }
  184. /**
  185. * The near_lat_long
  186. *
  187. * @param string $nearLatLong The near_lat_long
  188. * @return $this Fluent Builder
  189. */
  190. public function setNearLatLong($nearLatLong) {
  191. $this->options['nearLatLong'] = $nearLatLong;
  192. return $this;
  193. }
  194. /**
  195. * The distance
  196. *
  197. * @param integer $distance The distance
  198. * @return $this Fluent Builder
  199. */
  200. public function setDistance($distance) {
  201. $this->options['distance'] = $distance;
  202. return $this;
  203. }
  204. /**
  205. * The in_postal_code
  206. *
  207. * @param string $inPostalCode The in_postal_code
  208. * @return $this Fluent Builder
  209. */
  210. public function setInPostalCode($inPostalCode) {
  211. $this->options['inPostalCode'] = $inPostalCode;
  212. return $this;
  213. }
  214. /**
  215. * The in_region
  216. *
  217. * @param string $inRegion The in_region
  218. * @return $this Fluent Builder
  219. */
  220. public function setInRegion($inRegion) {
  221. $this->options['inRegion'] = $inRegion;
  222. return $this;
  223. }
  224. /**
  225. * The in_rate_center
  226. *
  227. * @param string $inRateCenter The in_rate_center
  228. * @return $this Fluent Builder
  229. */
  230. public function setInRateCenter($inRateCenter) {
  231. $this->options['inRateCenter'] = $inRateCenter;
  232. return $this;
  233. }
  234. /**
  235. * The in_lata
  236. *
  237. * @param string $inLata The in_lata
  238. * @return $this Fluent Builder
  239. */
  240. public function setInLata($inLata) {
  241. $this->options['inLata'] = $inLata;
  242. return $this;
  243. }
  244. /**
  245. * The in_locality
  246. *
  247. * @param string $inLocality The in_locality
  248. * @return $this Fluent Builder
  249. */
  250. public function setInLocality($inLocality) {
  251. $this->options['inLocality'] = $inLocality;
  252. return $this;
  253. }
  254. /**
  255. * The fax_enabled
  256. *
  257. * @param boolean $faxEnabled The fax_enabled
  258. * @return $this Fluent Builder
  259. */
  260. public function setFaxEnabled($faxEnabled) {
  261. $this->options['faxEnabled'] = $faxEnabled;
  262. return $this;
  263. }
  264. /**
  265. * Provide a friendly representation
  266. *
  267. * @return string Machine friendly representation
  268. */
  269. public function __toString() {
  270. $options = array();
  271. foreach ($this->options as $key => $value) {
  272. if ($value != Values::NONE) {
  273. $options[] = "$key=$value";
  274. }
  275. }
  276. return '[Twilio.Api.V2010.ReadMachineToMachineOptions ' . implode(' ', $options) . ']';
  277. }
  278. }