/sdk/apimanagement/mgmt-v2018_06_01_preview/src/main/java/com/microsoft/azure/management/apimanagement/v2018_06_01_preview/AuthorizationServerUpdateContract.java

http://github.com/WindowsAzure/azure-sdk-for-java · Java · 455 lines · 152 code · 51 blank · 252 comment · 0 complexity · 48d8ac126266e9d454430e7b66fd4418 MD5 · raw file

  1. /**
  2. * Copyright (c) Microsoft Corporation. All rights reserved.
  3. * Licensed under the MIT License. See License.txt in the project root for
  4. * license information.
  5. *
  6. * Code generated by Microsoft (R) AutoRest Code Generator.
  7. */
  8. package com.microsoft.azure.management.apimanagement.v2018_06_01_preview;
  9. import java.util.List;
  10. import com.fasterxml.jackson.annotation.JsonProperty;
  11. import com.microsoft.rest.serializer.JsonFlatten;
  12. import com.microsoft.azure.ProxyResource;
  13. /**
  14. * External OAuth authorization server settings.
  15. */
  16. @JsonFlatten
  17. public class AuthorizationServerUpdateContract extends ProxyResource {
  18. /**
  19. * Description of the authorization server. Can contain HTML formatting
  20. * tags.
  21. */
  22. @JsonProperty(value = "properties.description")
  23. private String description;
  24. /**
  25. * HTTP verbs supported by the authorization endpoint. GET must be always
  26. * present. POST is optional.
  27. */
  28. @JsonProperty(value = "properties.authorizationMethods")
  29. private List<AuthorizationMethod> authorizationMethods;
  30. /**
  31. * Method of authentication supported by the token endpoint of this
  32. * authorization server. Possible values are Basic and/or Body. When Body
  33. * is specified, client credentials and other parameters are passed within
  34. * the request body in the application/x-www-form-urlencoded format.
  35. */
  36. @JsonProperty(value = "properties.clientAuthenticationMethod")
  37. private List<ClientAuthenticationMethod> clientAuthenticationMethod;
  38. /**
  39. * Additional parameters required by the token endpoint of this
  40. * authorization server represented as an array of JSON objects with name
  41. * and value string properties, i.e. {"name" : "name value", "value": "a
  42. * value"}.
  43. */
  44. @JsonProperty(value = "properties.tokenBodyParameters")
  45. private List<TokenBodyParameterContract> tokenBodyParameters;
  46. /**
  47. * OAuth token endpoint. Contains absolute URI to entity being referenced.
  48. */
  49. @JsonProperty(value = "properties.tokenEndpoint")
  50. private String tokenEndpoint;
  51. /**
  52. * If true, authorization server will include state parameter from the
  53. * authorization request to its response. Client may use state parameter to
  54. * raise protocol security.
  55. */
  56. @JsonProperty(value = "properties.supportState")
  57. private Boolean supportState;
  58. /**
  59. * Access token scope that is going to be requested by default. Can be
  60. * overridden at the API level. Should be provided in the form of a string
  61. * containing space-delimited values.
  62. */
  63. @JsonProperty(value = "properties.defaultScope")
  64. private String defaultScope;
  65. /**
  66. * Specifies the mechanism by which access token is passed to the API.
  67. */
  68. @JsonProperty(value = "properties.bearerTokenSendingMethods")
  69. private List<BearerTokenSendingMethod> bearerTokenSendingMethods;
  70. /**
  71. * Client or app secret registered with this authorization server.
  72. */
  73. @JsonProperty(value = "properties.clientSecret")
  74. private String clientSecret;
  75. /**
  76. * Can be optionally specified when resource owner password grant type is
  77. * supported by this authorization server. Default resource owner username.
  78. */
  79. @JsonProperty(value = "properties.resourceOwnerUsername")
  80. private String resourceOwnerUsername;
  81. /**
  82. * Can be optionally specified when resource owner password grant type is
  83. * supported by this authorization server. Default resource owner password.
  84. */
  85. @JsonProperty(value = "properties.resourceOwnerPassword")
  86. private String resourceOwnerPassword;
  87. /**
  88. * User-friendly authorization server name.
  89. */
  90. @JsonProperty(value = "properties.displayName")
  91. private String displayName;
  92. /**
  93. * Optional reference to a page where client or app registration for this
  94. * authorization server is performed. Contains absolute URL to entity being
  95. * referenced.
  96. */
  97. @JsonProperty(value = "properties.clientRegistrationEndpoint")
  98. private String clientRegistrationEndpoint;
  99. /**
  100. * OAuth authorization endpoint. See
  101. * http://tools.ietf.org/html/rfc6749#section-3.2.
  102. */
  103. @JsonProperty(value = "properties.authorizationEndpoint")
  104. private String authorizationEndpoint;
  105. /**
  106. * Form of an authorization grant, which the client uses to request the
  107. * access token.
  108. */
  109. @JsonProperty(value = "properties.grantTypes")
  110. private List<GrantType> grantTypes;
  111. /**
  112. * Client or app id registered with this authorization server.
  113. */
  114. @JsonProperty(value = "properties.clientId")
  115. private String clientId;
  116. /**
  117. * Get description of the authorization server. Can contain HTML formatting tags.
  118. *
  119. * @return the description value
  120. */
  121. public String description() {
  122. return this.description;
  123. }
  124. /**
  125. * Set description of the authorization server. Can contain HTML formatting tags.
  126. *
  127. * @param description the description value to set
  128. * @return the AuthorizationServerUpdateContract object itself.
  129. */
  130. public AuthorizationServerUpdateContract withDescription(String description) {
  131. this.description = description;
  132. return this;
  133. }
  134. /**
  135. * Get hTTP verbs supported by the authorization endpoint. GET must be always present. POST is optional.
  136. *
  137. * @return the authorizationMethods value
  138. */
  139. public List<AuthorizationMethod> authorizationMethods() {
  140. return this.authorizationMethods;
  141. }
  142. /**
  143. * Set hTTP verbs supported by the authorization endpoint. GET must be always present. POST is optional.
  144. *
  145. * @param authorizationMethods the authorizationMethods value to set
  146. * @return the AuthorizationServerUpdateContract object itself.
  147. */
  148. public AuthorizationServerUpdateContract withAuthorizationMethods(List<AuthorizationMethod> authorizationMethods) {
  149. this.authorizationMethods = authorizationMethods;
  150. return this;
  151. }
  152. /**
  153. * Get method of authentication supported by the token endpoint of this authorization server. Possible values are Basic and/or Body. When Body is specified, client credentials and other parameters are passed within the request body in the application/x-www-form-urlencoded format.
  154. *
  155. * @return the clientAuthenticationMethod value
  156. */
  157. public List<ClientAuthenticationMethod> clientAuthenticationMethod() {
  158. return this.clientAuthenticationMethod;
  159. }
  160. /**
  161. * Set method of authentication supported by the token endpoint of this authorization server. Possible values are Basic and/or Body. When Body is specified, client credentials and other parameters are passed within the request body in the application/x-www-form-urlencoded format.
  162. *
  163. * @param clientAuthenticationMethod the clientAuthenticationMethod value to set
  164. * @return the AuthorizationServerUpdateContract object itself.
  165. */
  166. public AuthorizationServerUpdateContract withClientAuthenticationMethod(List<ClientAuthenticationMethod> clientAuthenticationMethod) {
  167. this.clientAuthenticationMethod = clientAuthenticationMethod;
  168. return this;
  169. }
  170. /**
  171. * Get additional parameters required by the token endpoint of this authorization server represented as an array of JSON objects with name and value string properties, i.e. {"name" : "name value", "value": "a value"}.
  172. *
  173. * @return the tokenBodyParameters value
  174. */
  175. public List<TokenBodyParameterContract> tokenBodyParameters() {
  176. return this.tokenBodyParameters;
  177. }
  178. /**
  179. * Set additional parameters required by the token endpoint of this authorization server represented as an array of JSON objects with name and value string properties, i.e. {"name" : "name value", "value": "a value"}.
  180. *
  181. * @param tokenBodyParameters the tokenBodyParameters value to set
  182. * @return the AuthorizationServerUpdateContract object itself.
  183. */
  184. public AuthorizationServerUpdateContract withTokenBodyParameters(List<TokenBodyParameterContract> tokenBodyParameters) {
  185. this.tokenBodyParameters = tokenBodyParameters;
  186. return this;
  187. }
  188. /**
  189. * Get oAuth token endpoint. Contains absolute URI to entity being referenced.
  190. *
  191. * @return the tokenEndpoint value
  192. */
  193. public String tokenEndpoint() {
  194. return this.tokenEndpoint;
  195. }
  196. /**
  197. * Set oAuth token endpoint. Contains absolute URI to entity being referenced.
  198. *
  199. * @param tokenEndpoint the tokenEndpoint value to set
  200. * @return the AuthorizationServerUpdateContract object itself.
  201. */
  202. public AuthorizationServerUpdateContract withTokenEndpoint(String tokenEndpoint) {
  203. this.tokenEndpoint = tokenEndpoint;
  204. return this;
  205. }
  206. /**
  207. * Get if true, authorization server will include state parameter from the authorization request to its response. Client may use state parameter to raise protocol security.
  208. *
  209. * @return the supportState value
  210. */
  211. public Boolean supportState() {
  212. return this.supportState;
  213. }
  214. /**
  215. * Set if true, authorization server will include state parameter from the authorization request to its response. Client may use state parameter to raise protocol security.
  216. *
  217. * @param supportState the supportState value to set
  218. * @return the AuthorizationServerUpdateContract object itself.
  219. */
  220. public AuthorizationServerUpdateContract withSupportState(Boolean supportState) {
  221. this.supportState = supportState;
  222. return this;
  223. }
  224. /**
  225. * Get access token scope that is going to be requested by default. Can be overridden at the API level. Should be provided in the form of a string containing space-delimited values.
  226. *
  227. * @return the defaultScope value
  228. */
  229. public String defaultScope() {
  230. return this.defaultScope;
  231. }
  232. /**
  233. * Set access token scope that is going to be requested by default. Can be overridden at the API level. Should be provided in the form of a string containing space-delimited values.
  234. *
  235. * @param defaultScope the defaultScope value to set
  236. * @return the AuthorizationServerUpdateContract object itself.
  237. */
  238. public AuthorizationServerUpdateContract withDefaultScope(String defaultScope) {
  239. this.defaultScope = defaultScope;
  240. return this;
  241. }
  242. /**
  243. * Get specifies the mechanism by which access token is passed to the API.
  244. *
  245. * @return the bearerTokenSendingMethods value
  246. */
  247. public List<BearerTokenSendingMethod> bearerTokenSendingMethods() {
  248. return this.bearerTokenSendingMethods;
  249. }
  250. /**
  251. * Set specifies the mechanism by which access token is passed to the API.
  252. *
  253. * @param bearerTokenSendingMethods the bearerTokenSendingMethods value to set
  254. * @return the AuthorizationServerUpdateContract object itself.
  255. */
  256. public AuthorizationServerUpdateContract withBearerTokenSendingMethods(List<BearerTokenSendingMethod> bearerTokenSendingMethods) {
  257. this.bearerTokenSendingMethods = bearerTokenSendingMethods;
  258. return this;
  259. }
  260. /**
  261. * Get client or app secret registered with this authorization server.
  262. *
  263. * @return the clientSecret value
  264. */
  265. public String clientSecret() {
  266. return this.clientSecret;
  267. }
  268. /**
  269. * Set client or app secret registered with this authorization server.
  270. *
  271. * @param clientSecret the clientSecret value to set
  272. * @return the AuthorizationServerUpdateContract object itself.
  273. */
  274. public AuthorizationServerUpdateContract withClientSecret(String clientSecret) {
  275. this.clientSecret = clientSecret;
  276. return this;
  277. }
  278. /**
  279. * Get can be optionally specified when resource owner password grant type is supported by this authorization server. Default resource owner username.
  280. *
  281. * @return the resourceOwnerUsername value
  282. */
  283. public String resourceOwnerUsername() {
  284. return this.resourceOwnerUsername;
  285. }
  286. /**
  287. * Set can be optionally specified when resource owner password grant type is supported by this authorization server. Default resource owner username.
  288. *
  289. * @param resourceOwnerUsername the resourceOwnerUsername value to set
  290. * @return the AuthorizationServerUpdateContract object itself.
  291. */
  292. public AuthorizationServerUpdateContract withResourceOwnerUsername(String resourceOwnerUsername) {
  293. this.resourceOwnerUsername = resourceOwnerUsername;
  294. return this;
  295. }
  296. /**
  297. * Get can be optionally specified when resource owner password grant type is supported by this authorization server. Default resource owner password.
  298. *
  299. * @return the resourceOwnerPassword value
  300. */
  301. public String resourceOwnerPassword() {
  302. return this.resourceOwnerPassword;
  303. }
  304. /**
  305. * Set can be optionally specified when resource owner password grant type is supported by this authorization server. Default resource owner password.
  306. *
  307. * @param resourceOwnerPassword the resourceOwnerPassword value to set
  308. * @return the AuthorizationServerUpdateContract object itself.
  309. */
  310. public AuthorizationServerUpdateContract withResourceOwnerPassword(String resourceOwnerPassword) {
  311. this.resourceOwnerPassword = resourceOwnerPassword;
  312. return this;
  313. }
  314. /**
  315. * Get user-friendly authorization server name.
  316. *
  317. * @return the displayName value
  318. */
  319. public String displayName() {
  320. return this.displayName;
  321. }
  322. /**
  323. * Set user-friendly authorization server name.
  324. *
  325. * @param displayName the displayName value to set
  326. * @return the AuthorizationServerUpdateContract object itself.
  327. */
  328. public AuthorizationServerUpdateContract withDisplayName(String displayName) {
  329. this.displayName = displayName;
  330. return this;
  331. }
  332. /**
  333. * Get optional reference to a page where client or app registration for this authorization server is performed. Contains absolute URL to entity being referenced.
  334. *
  335. * @return the clientRegistrationEndpoint value
  336. */
  337. public String clientRegistrationEndpoint() {
  338. return this.clientRegistrationEndpoint;
  339. }
  340. /**
  341. * Set optional reference to a page where client or app registration for this authorization server is performed. Contains absolute URL to entity being referenced.
  342. *
  343. * @param clientRegistrationEndpoint the clientRegistrationEndpoint value to set
  344. * @return the AuthorizationServerUpdateContract object itself.
  345. */
  346. public AuthorizationServerUpdateContract withClientRegistrationEndpoint(String clientRegistrationEndpoint) {
  347. this.clientRegistrationEndpoint = clientRegistrationEndpoint;
  348. return this;
  349. }
  350. /**
  351. * Get oAuth authorization endpoint. See http://tools.ietf.org/html/rfc6749#section-3.2.
  352. *
  353. * @return the authorizationEndpoint value
  354. */
  355. public String authorizationEndpoint() {
  356. return this.authorizationEndpoint;
  357. }
  358. /**
  359. * Set oAuth authorization endpoint. See http://tools.ietf.org/html/rfc6749#section-3.2.
  360. *
  361. * @param authorizationEndpoint the authorizationEndpoint value to set
  362. * @return the AuthorizationServerUpdateContract object itself.
  363. */
  364. public AuthorizationServerUpdateContract withAuthorizationEndpoint(String authorizationEndpoint) {
  365. this.authorizationEndpoint = authorizationEndpoint;
  366. return this;
  367. }
  368. /**
  369. * Get form of an authorization grant, which the client uses to request the access token.
  370. *
  371. * @return the grantTypes value
  372. */
  373. public List<GrantType> grantTypes() {
  374. return this.grantTypes;
  375. }
  376. /**
  377. * Set form of an authorization grant, which the client uses to request the access token.
  378. *
  379. * @param grantTypes the grantTypes value to set
  380. * @return the AuthorizationServerUpdateContract object itself.
  381. */
  382. public AuthorizationServerUpdateContract withGrantTypes(List<GrantType> grantTypes) {
  383. this.grantTypes = grantTypes;
  384. return this;
  385. }
  386. /**
  387. * Get client or app id registered with this authorization server.
  388. *
  389. * @return the clientId value
  390. */
  391. public String clientId() {
  392. return this.clientId;
  393. }
  394. /**
  395. * Set client or app id registered with this authorization server.
  396. *
  397. * @param clientId the clientId value to set
  398. * @return the AuthorizationServerUpdateContract object itself.
  399. */
  400. public AuthorizationServerUpdateContract withClientId(String clientId) {
  401. this.clientId = clientId;
  402. return this;
  403. }
  404. }