SENTRY-2192: supress date value in @Generated annotation generated by thrift.(Kalyan...
[sentry.git] / sentry-provider / sentry-provider-db / src / gen / thrift / gen-javabean / org / apache / sentry / provider / db / generic / service / thrift / SentryGenericPolicyService.java
1 /**
2 * Autogenerated by Thrift Compiler (0.9.3)
3 *
4 * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
5 * @generated
6 */
7 package org.apache.sentry.provider.db.generic.service.thrift;
8
9 import org.apache.thrift.scheme.IScheme;
10 import org.apache.thrift.scheme.SchemeFactory;
11 import org.apache.thrift.scheme.StandardScheme;
12
13 import org.apache.thrift.scheme.TupleScheme;
14 import org.apache.thrift.protocol.TTupleProtocol;
15 import org.apache.thrift.protocol.TProtocolException;
16 import org.apache.thrift.EncodingUtils;
17 import org.apache.thrift.TException;
18 import org.apache.thrift.async.AsyncMethodCallback;
19 import org.apache.thrift.server.AbstractNonblockingServer.*;
20 import java.util.List;
21 import java.util.ArrayList;
22 import java.util.Map;
23 import java.util.HashMap;
24 import java.util.EnumMap;
25 import java.util.Set;
26 import java.util.HashSet;
27 import java.util.EnumSet;
28 import java.util.Collections;
29 import java.util.BitSet;
30 import java.nio.ByteBuffer;
31 import java.util.Arrays;
32 import javax.annotation.Generated;
33 import org.slf4j.Logger;
34 import org.slf4j.LoggerFactory;
35
36 @SuppressWarnings({"cast", "rawtypes", "serial", "unchecked"})
37 @Generated(value = "Autogenerated by Thrift Compiler (0.9.3)")
38 public class SentryGenericPolicyService {
39
40 public interface Iface {
41
42 public TCreateSentryRoleResponse create_sentry_role(TCreateSentryRoleRequest request) throws org.apache.thrift.TException;
43
44 public TDropSentryRoleResponse drop_sentry_role(TDropSentryRoleRequest request) throws org.apache.thrift.TException;
45
46 public TAlterSentryRoleGrantPrivilegeResponse alter_sentry_role_grant_privilege(TAlterSentryRoleGrantPrivilegeRequest request) throws org.apache.thrift.TException;
47
48 public TAlterSentryRoleRevokePrivilegeResponse alter_sentry_role_revoke_privilege(TAlterSentryRoleRevokePrivilegeRequest request) throws org.apache.thrift.TException;
49
50 public TAlterSentryRoleAddGroupsResponse alter_sentry_role_add_groups(TAlterSentryRoleAddGroupsRequest request) throws org.apache.thrift.TException;
51
52 public TAlterSentryRoleDeleteGroupsResponse alter_sentry_role_delete_groups(TAlterSentryRoleDeleteGroupsRequest request) throws org.apache.thrift.TException;
53
54 public TListSentryRolesResponse list_sentry_roles_by_group(TListSentryRolesRequest request) throws org.apache.thrift.TException;
55
56 public TListSentryPrivilegesResponse list_sentry_privileges_by_role(TListSentryPrivilegesRequest request) throws org.apache.thrift.TException;
57
58 public TListSentryPrivilegesForProviderResponse list_sentry_privileges_for_provider(TListSentryPrivilegesForProviderRequest request) throws org.apache.thrift.TException;
59
60 public TListSentryPrivilegesByAuthResponse list_sentry_privileges_by_authorizable(TListSentryPrivilegesByAuthRequest request) throws org.apache.thrift.TException;
61
62 public TDropPrivilegesResponse drop_sentry_privilege(TDropPrivilegesRequest request) throws org.apache.thrift.TException;
63
64 public TRenamePrivilegesResponse rename_sentry_privilege(TRenamePrivilegesRequest request) throws org.apache.thrift.TException;
65
66 }
67
68 public interface AsyncIface {
69
70 public void create_sentry_role(TCreateSentryRoleRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
71
72 public void drop_sentry_role(TDropSentryRoleRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
73
74 public void alter_sentry_role_grant_privilege(TAlterSentryRoleGrantPrivilegeRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
75
76 public void alter_sentry_role_revoke_privilege(TAlterSentryRoleRevokePrivilegeRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
77
78 public void alter_sentry_role_add_groups(TAlterSentryRoleAddGroupsRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
79
80 public void alter_sentry_role_delete_groups(TAlterSentryRoleDeleteGroupsRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
81
82 public void list_sentry_roles_by_group(TListSentryRolesRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
83
84 public void list_sentry_privileges_by_role(TListSentryPrivilegesRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
85
86 public void list_sentry_privileges_for_provider(TListSentryPrivilegesForProviderRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
87
88 public void list_sentry_privileges_by_authorizable(TListSentryPrivilegesByAuthRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
89
90 public void drop_sentry_privilege(TDropPrivilegesRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
91
92 public void rename_sentry_privilege(TRenamePrivilegesRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException;
93
94 }
95
96 public static class Client extends org.apache.thrift.TServiceClient implements Iface {
97 public static class Factory implements org.apache.thrift.TServiceClientFactory<Client> {
98 public Factory() {}
99 public Client getClient(org.apache.thrift.protocol.TProtocol prot) {
100 return new Client(prot);
101 }
102 public Client getClient(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
103 return new Client(iprot, oprot);
104 }
105 }
106
107 public Client(org.apache.thrift.protocol.TProtocol prot)
108 {
109 super(prot, prot);
110 }
111
112 public Client(org.apache.thrift.protocol.TProtocol iprot, org.apache.thrift.protocol.TProtocol oprot) {
113 super(iprot, oprot);
114 }
115
116 public TCreateSentryRoleResponse create_sentry_role(TCreateSentryRoleRequest request) throws org.apache.thrift.TException
117 {
118 send_create_sentry_role(request);
119 return recv_create_sentry_role();
120 }
121
122 public void send_create_sentry_role(TCreateSentryRoleRequest request) throws org.apache.thrift.TException
123 {
124 create_sentry_role_args args = new create_sentry_role_args();
125 args.setRequest(request);
126 sendBase("create_sentry_role", args);
127 }
128
129 public TCreateSentryRoleResponse recv_create_sentry_role() throws org.apache.thrift.TException
130 {
131 create_sentry_role_result result = new create_sentry_role_result();
132 receiveBase(result, "create_sentry_role");
133 if (result.isSetSuccess()) {
134 return result.success;
135 }
136 throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "create_sentry_role failed: unknown result");
137 }
138
139 public TDropSentryRoleResponse drop_sentry_role(TDropSentryRoleRequest request) throws org.apache.thrift.TException
140 {
141 send_drop_sentry_role(request);
142 return recv_drop_sentry_role();
143 }
144
145 public void send_drop_sentry_role(TDropSentryRoleRequest request) throws org.apache.thrift.TException
146 {
147 drop_sentry_role_args args = new drop_sentry_role_args();
148 args.setRequest(request);
149 sendBase("drop_sentry_role", args);
150 }
151
152 public TDropSentryRoleResponse recv_drop_sentry_role() throws org.apache.thrift.TException
153 {
154 drop_sentry_role_result result = new drop_sentry_role_result();
155 receiveBase(result, "drop_sentry_role");
156 if (result.isSetSuccess()) {
157 return result.success;
158 }
159 throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "drop_sentry_role failed: unknown result");
160 }
161
162 public TAlterSentryRoleGrantPrivilegeResponse alter_sentry_role_grant_privilege(TAlterSentryRoleGrantPrivilegeRequest request) throws org.apache.thrift.TException
163 {
164 send_alter_sentry_role_grant_privilege(request);
165 return recv_alter_sentry_role_grant_privilege();
166 }
167
168 public void send_alter_sentry_role_grant_privilege(TAlterSentryRoleGrantPrivilegeRequest request) throws org.apache.thrift.TException
169 {
170 alter_sentry_role_grant_privilege_args args = new alter_sentry_role_grant_privilege_args();
171 args.setRequest(request);
172 sendBase("alter_sentry_role_grant_privilege", args);
173 }
174
175 public TAlterSentryRoleGrantPrivilegeResponse recv_alter_sentry_role_grant_privilege() throws org.apache.thrift.TException
176 {
177 alter_sentry_role_grant_privilege_result result = new alter_sentry_role_grant_privilege_result();
178 receiveBase(result, "alter_sentry_role_grant_privilege");
179 if (result.isSetSuccess()) {
180 return result.success;
181 }
182 throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "alter_sentry_role_grant_privilege failed: unknown result");
183 }
184
185 public TAlterSentryRoleRevokePrivilegeResponse alter_sentry_role_revoke_privilege(TAlterSentryRoleRevokePrivilegeRequest request) throws org.apache.thrift.TException
186 {
187 send_alter_sentry_role_revoke_privilege(request);
188 return recv_alter_sentry_role_revoke_privilege();
189 }
190
191 public void send_alter_sentry_role_revoke_privilege(TAlterSentryRoleRevokePrivilegeRequest request) throws org.apache.thrift.TException
192 {
193 alter_sentry_role_revoke_privilege_args args = new alter_sentry_role_revoke_privilege_args();
194 args.setRequest(request);
195 sendBase("alter_sentry_role_revoke_privilege", args);
196 }
197
198 public TAlterSentryRoleRevokePrivilegeResponse recv_alter_sentry_role_revoke_privilege() throws org.apache.thrift.TException
199 {
200 alter_sentry_role_revoke_privilege_result result = new alter_sentry_role_revoke_privilege_result();
201 receiveBase(result, "alter_sentry_role_revoke_privilege");
202 if (result.isSetSuccess()) {
203 return result.success;
204 }
205 throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "alter_sentry_role_revoke_privilege failed: unknown result");
206 }
207
208 public TAlterSentryRoleAddGroupsResponse alter_sentry_role_add_groups(TAlterSentryRoleAddGroupsRequest request) throws org.apache.thrift.TException
209 {
210 send_alter_sentry_role_add_groups(request);
211 return recv_alter_sentry_role_add_groups();
212 }
213
214 public void send_alter_sentry_role_add_groups(TAlterSentryRoleAddGroupsRequest request) throws org.apache.thrift.TException
215 {
216 alter_sentry_role_add_groups_args args = new alter_sentry_role_add_groups_args();
217 args.setRequest(request);
218 sendBase("alter_sentry_role_add_groups", args);
219 }
220
221 public TAlterSentryRoleAddGroupsResponse recv_alter_sentry_role_add_groups() throws org.apache.thrift.TException
222 {
223 alter_sentry_role_add_groups_result result = new alter_sentry_role_add_groups_result();
224 receiveBase(result, "alter_sentry_role_add_groups");
225 if (result.isSetSuccess()) {
226 return result.success;
227 }
228 throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "alter_sentry_role_add_groups failed: unknown result");
229 }
230
231 public TAlterSentryRoleDeleteGroupsResponse alter_sentry_role_delete_groups(TAlterSentryRoleDeleteGroupsRequest request) throws org.apache.thrift.TException
232 {
233 send_alter_sentry_role_delete_groups(request);
234 return recv_alter_sentry_role_delete_groups();
235 }
236
237 public void send_alter_sentry_role_delete_groups(TAlterSentryRoleDeleteGroupsRequest request) throws org.apache.thrift.TException
238 {
239 alter_sentry_role_delete_groups_args args = new alter_sentry_role_delete_groups_args();
240 args.setRequest(request);
241 sendBase("alter_sentry_role_delete_groups", args);
242 }
243
244 public TAlterSentryRoleDeleteGroupsResponse recv_alter_sentry_role_delete_groups() throws org.apache.thrift.TException
245 {
246 alter_sentry_role_delete_groups_result result = new alter_sentry_role_delete_groups_result();
247 receiveBase(result, "alter_sentry_role_delete_groups");
248 if (result.isSetSuccess()) {
249 return result.success;
250 }
251 throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "alter_sentry_role_delete_groups failed: unknown result");
252 }
253
254 public TListSentryRolesResponse list_sentry_roles_by_group(TListSentryRolesRequest request) throws org.apache.thrift.TException
255 {
256 send_list_sentry_roles_by_group(request);
257 return recv_list_sentry_roles_by_group();
258 }
259
260 public void send_list_sentry_roles_by_group(TListSentryRolesRequest request) throws org.apache.thrift.TException
261 {
262 list_sentry_roles_by_group_args args = new list_sentry_roles_by_group_args();
263 args.setRequest(request);
264 sendBase("list_sentry_roles_by_group", args);
265 }
266
267 public TListSentryRolesResponse recv_list_sentry_roles_by_group() throws org.apache.thrift.TException
268 {
269 list_sentry_roles_by_group_result result = new list_sentry_roles_by_group_result();
270 receiveBase(result, "list_sentry_roles_by_group");
271 if (result.isSetSuccess()) {
272 return result.success;
273 }
274 throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "list_sentry_roles_by_group failed: unknown result");
275 }
276
277 public TListSentryPrivilegesResponse list_sentry_privileges_by_role(TListSentryPrivilegesRequest request) throws org.apache.thrift.TException
278 {
279 send_list_sentry_privileges_by_role(request);
280 return recv_list_sentry_privileges_by_role();
281 }
282
283 public void send_list_sentry_privileges_by_role(TListSentryPrivilegesRequest request) throws org.apache.thrift.TException
284 {
285 list_sentry_privileges_by_role_args args = new list_sentry_privileges_by_role_args();
286 args.setRequest(request);
287 sendBase("list_sentry_privileges_by_role", args);
288 }
289
290 public TListSentryPrivilegesResponse recv_list_sentry_privileges_by_role() throws org.apache.thrift.TException
291 {
292 list_sentry_privileges_by_role_result result = new list_sentry_privileges_by_role_result();
293 receiveBase(result, "list_sentry_privileges_by_role");
294 if (result.isSetSuccess()) {
295 return result.success;
296 }
297 throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "list_sentry_privileges_by_role failed: unknown result");
298 }
299
300 public TListSentryPrivilegesForProviderResponse list_sentry_privileges_for_provider(TListSentryPrivilegesForProviderRequest request) throws org.apache.thrift.TException
301 {
302 send_list_sentry_privileges_for_provider(request);
303 return recv_list_sentry_privileges_for_provider();
304 }
305
306 public void send_list_sentry_privileges_for_provider(TListSentryPrivilegesForProviderRequest request) throws org.apache.thrift.TException
307 {
308 list_sentry_privileges_for_provider_args args = new list_sentry_privileges_for_provider_args();
309 args.setRequest(request);
310 sendBase("list_sentry_privileges_for_provider", args);
311 }
312
313 public TListSentryPrivilegesForProviderResponse recv_list_sentry_privileges_for_provider() throws org.apache.thrift.TException
314 {
315 list_sentry_privileges_for_provider_result result = new list_sentry_privileges_for_provider_result();
316 receiveBase(result, "list_sentry_privileges_for_provider");
317 if (result.isSetSuccess()) {
318 return result.success;
319 }
320 throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "list_sentry_privileges_for_provider failed: unknown result");
321 }
322
323 public TListSentryPrivilegesByAuthResponse list_sentry_privileges_by_authorizable(TListSentryPrivilegesByAuthRequest request) throws org.apache.thrift.TException
324 {
325 send_list_sentry_privileges_by_authorizable(request);
326 return recv_list_sentry_privileges_by_authorizable();
327 }
328
329 public void send_list_sentry_privileges_by_authorizable(TListSentryPrivilegesByAuthRequest request) throws org.apache.thrift.TException
330 {
331 list_sentry_privileges_by_authorizable_args args = new list_sentry_privileges_by_authorizable_args();
332 args.setRequest(request);
333 sendBase("list_sentry_privileges_by_authorizable", args);
334 }
335
336 public TListSentryPrivilegesByAuthResponse recv_list_sentry_privileges_by_authorizable() throws org.apache.thrift.TException
337 {
338 list_sentry_privileges_by_authorizable_result result = new list_sentry_privileges_by_authorizable_result();
339 receiveBase(result, "list_sentry_privileges_by_authorizable");
340 if (result.isSetSuccess()) {
341 return result.success;
342 }
343 throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "list_sentry_privileges_by_authorizable failed: unknown result");
344 }
345
346 public TDropPrivilegesResponse drop_sentry_privilege(TDropPrivilegesRequest request) throws org.apache.thrift.TException
347 {
348 send_drop_sentry_privilege(request);
349 return recv_drop_sentry_privilege();
350 }
351
352 public void send_drop_sentry_privilege(TDropPrivilegesRequest request) throws org.apache.thrift.TException
353 {
354 drop_sentry_privilege_args args = new drop_sentry_privilege_args();
355 args.setRequest(request);
356 sendBase("drop_sentry_privilege", args);
357 }
358
359 public TDropPrivilegesResponse recv_drop_sentry_privilege() throws org.apache.thrift.TException
360 {
361 drop_sentry_privilege_result result = new drop_sentry_privilege_result();
362 receiveBase(result, "drop_sentry_privilege");
363 if (result.isSetSuccess()) {
364 return result.success;
365 }
366 throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "drop_sentry_privilege failed: unknown result");
367 }
368
369 public TRenamePrivilegesResponse rename_sentry_privilege(TRenamePrivilegesRequest request) throws org.apache.thrift.TException
370 {
371 send_rename_sentry_privilege(request);
372 return recv_rename_sentry_privilege();
373 }
374
375 public void send_rename_sentry_privilege(TRenamePrivilegesRequest request) throws org.apache.thrift.TException
376 {
377 rename_sentry_privilege_args args = new rename_sentry_privilege_args();
378 args.setRequest(request);
379 sendBase("rename_sentry_privilege", args);
380 }
381
382 public TRenamePrivilegesResponse recv_rename_sentry_privilege() throws org.apache.thrift.TException
383 {
384 rename_sentry_privilege_result result = new rename_sentry_privilege_result();
385 receiveBase(result, "rename_sentry_privilege");
386 if (result.isSetSuccess()) {
387 return result.success;
388 }
389 throw new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.MISSING_RESULT, "rename_sentry_privilege failed: unknown result");
390 }
391
392 }
393 public static class AsyncClient extends org.apache.thrift.async.TAsyncClient implements AsyncIface {
394 public static class Factory implements org.apache.thrift.async.TAsyncClientFactory<AsyncClient> {
395 private org.apache.thrift.async.TAsyncClientManager clientManager;
396 private org.apache.thrift.protocol.TProtocolFactory protocolFactory;
397 public Factory(org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.protocol.TProtocolFactory protocolFactory) {
398 this.clientManager = clientManager;
399 this.protocolFactory = protocolFactory;
400 }
401 public AsyncClient getAsyncClient(org.apache.thrift.transport.TNonblockingTransport transport) {
402 return new AsyncClient(protocolFactory, clientManager, transport);
403 }
404 }
405
406 public AsyncClient(org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.async.TAsyncClientManager clientManager, org.apache.thrift.transport.TNonblockingTransport transport) {
407 super(protocolFactory, clientManager, transport);
408 }
409
410 public void create_sentry_role(TCreateSentryRoleRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
411 checkReady();
412 create_sentry_role_call method_call = new create_sentry_role_call(request, resultHandler, this, ___protocolFactory, ___transport);
413 this.___currentMethod = method_call;
414 ___manager.call(method_call);
415 }
416
417 public static class create_sentry_role_call extends org.apache.thrift.async.TAsyncMethodCall {
418 private TCreateSentryRoleRequest request;
419 public create_sentry_role_call(TCreateSentryRoleRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
420 super(client, protocolFactory, transport, resultHandler, false);
421 this.request = request;
422 }
423
424 public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
425 prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("create_sentry_role", org.apache.thrift.protocol.TMessageType.CALL, 0));
426 create_sentry_role_args args = new create_sentry_role_args();
427 args.setRequest(request);
428 args.write(prot);
429 prot.writeMessageEnd();
430 }
431
432 public TCreateSentryRoleResponse getResult() throws org.apache.thrift.TException {
433 if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
434 throw new IllegalStateException("Method call not finished!");
435 }
436 org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
437 org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
438 return (new Client(prot)).recv_create_sentry_role();
439 }
440 }
441
442 public void drop_sentry_role(TDropSentryRoleRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
443 checkReady();
444 drop_sentry_role_call method_call = new drop_sentry_role_call(request, resultHandler, this, ___protocolFactory, ___transport);
445 this.___currentMethod = method_call;
446 ___manager.call(method_call);
447 }
448
449 public static class drop_sentry_role_call extends org.apache.thrift.async.TAsyncMethodCall {
450 private TDropSentryRoleRequest request;
451 public drop_sentry_role_call(TDropSentryRoleRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
452 super(client, protocolFactory, transport, resultHandler, false);
453 this.request = request;
454 }
455
456 public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
457 prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("drop_sentry_role", org.apache.thrift.protocol.TMessageType.CALL, 0));
458 drop_sentry_role_args args = new drop_sentry_role_args();
459 args.setRequest(request);
460 args.write(prot);
461 prot.writeMessageEnd();
462 }
463
464 public TDropSentryRoleResponse getResult() throws org.apache.thrift.TException {
465 if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
466 throw new IllegalStateException("Method call not finished!");
467 }
468 org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
469 org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
470 return (new Client(prot)).recv_drop_sentry_role();
471 }
472 }
473
474 public void alter_sentry_role_grant_privilege(TAlterSentryRoleGrantPrivilegeRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
475 checkReady();
476 alter_sentry_role_grant_privilege_call method_call = new alter_sentry_role_grant_privilege_call(request, resultHandler, this, ___protocolFactory, ___transport);
477 this.___currentMethod = method_call;
478 ___manager.call(method_call);
479 }
480
481 public static class alter_sentry_role_grant_privilege_call extends org.apache.thrift.async.TAsyncMethodCall {
482 private TAlterSentryRoleGrantPrivilegeRequest request;
483 public alter_sentry_role_grant_privilege_call(TAlterSentryRoleGrantPrivilegeRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
484 super(client, protocolFactory, transport, resultHandler, false);
485 this.request = request;
486 }
487
488 public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
489 prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("alter_sentry_role_grant_privilege", org.apache.thrift.protocol.TMessageType.CALL, 0));
490 alter_sentry_role_grant_privilege_args args = new alter_sentry_role_grant_privilege_args();
491 args.setRequest(request);
492 args.write(prot);
493 prot.writeMessageEnd();
494 }
495
496 public TAlterSentryRoleGrantPrivilegeResponse getResult() throws org.apache.thrift.TException {
497 if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
498 throw new IllegalStateException("Method call not finished!");
499 }
500 org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
501 org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
502 return (new Client(prot)).recv_alter_sentry_role_grant_privilege();
503 }
504 }
505
506 public void alter_sentry_role_revoke_privilege(TAlterSentryRoleRevokePrivilegeRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
507 checkReady();
508 alter_sentry_role_revoke_privilege_call method_call = new alter_sentry_role_revoke_privilege_call(request, resultHandler, this, ___protocolFactory, ___transport);
509 this.___currentMethod = method_call;
510 ___manager.call(method_call);
511 }
512
513 public static class alter_sentry_role_revoke_privilege_call extends org.apache.thrift.async.TAsyncMethodCall {
514 private TAlterSentryRoleRevokePrivilegeRequest request;
515 public alter_sentry_role_revoke_privilege_call(TAlterSentryRoleRevokePrivilegeRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
516 super(client, protocolFactory, transport, resultHandler, false);
517 this.request = request;
518 }
519
520 public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
521 prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("alter_sentry_role_revoke_privilege", org.apache.thrift.protocol.TMessageType.CALL, 0));
522 alter_sentry_role_revoke_privilege_args args = new alter_sentry_role_revoke_privilege_args();
523 args.setRequest(request);
524 args.write(prot);
525 prot.writeMessageEnd();
526 }
527
528 public TAlterSentryRoleRevokePrivilegeResponse getResult() throws org.apache.thrift.TException {
529 if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
530 throw new IllegalStateException("Method call not finished!");
531 }
532 org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
533 org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
534 return (new Client(prot)).recv_alter_sentry_role_revoke_privilege();
535 }
536 }
537
538 public void alter_sentry_role_add_groups(TAlterSentryRoleAddGroupsRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
539 checkReady();
540 alter_sentry_role_add_groups_call method_call = new alter_sentry_role_add_groups_call(request, resultHandler, this, ___protocolFactory, ___transport);
541 this.___currentMethod = method_call;
542 ___manager.call(method_call);
543 }
544
545 public static class alter_sentry_role_add_groups_call extends org.apache.thrift.async.TAsyncMethodCall {
546 private TAlterSentryRoleAddGroupsRequest request;
547 public alter_sentry_role_add_groups_call(TAlterSentryRoleAddGroupsRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
548 super(client, protocolFactory, transport, resultHandler, false);
549 this.request = request;
550 }
551
552 public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
553 prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("alter_sentry_role_add_groups", org.apache.thrift.protocol.TMessageType.CALL, 0));
554 alter_sentry_role_add_groups_args args = new alter_sentry_role_add_groups_args();
555 args.setRequest(request);
556 args.write(prot);
557 prot.writeMessageEnd();
558 }
559
560 public TAlterSentryRoleAddGroupsResponse getResult() throws org.apache.thrift.TException {
561 if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
562 throw new IllegalStateException("Method call not finished!");
563 }
564 org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
565 org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
566 return (new Client(prot)).recv_alter_sentry_role_add_groups();
567 }
568 }
569
570 public void alter_sentry_role_delete_groups(TAlterSentryRoleDeleteGroupsRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
571 checkReady();
572 alter_sentry_role_delete_groups_call method_call = new alter_sentry_role_delete_groups_call(request, resultHandler, this, ___protocolFactory, ___transport);
573 this.___currentMethod = method_call;
574 ___manager.call(method_call);
575 }
576
577 public static class alter_sentry_role_delete_groups_call extends org.apache.thrift.async.TAsyncMethodCall {
578 private TAlterSentryRoleDeleteGroupsRequest request;
579 public alter_sentry_role_delete_groups_call(TAlterSentryRoleDeleteGroupsRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
580 super(client, protocolFactory, transport, resultHandler, false);
581 this.request = request;
582 }
583
584 public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
585 prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("alter_sentry_role_delete_groups", org.apache.thrift.protocol.TMessageType.CALL, 0));
586 alter_sentry_role_delete_groups_args args = new alter_sentry_role_delete_groups_args();
587 args.setRequest(request);
588 args.write(prot);
589 prot.writeMessageEnd();
590 }
591
592 public TAlterSentryRoleDeleteGroupsResponse getResult() throws org.apache.thrift.TException {
593 if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
594 throw new IllegalStateException("Method call not finished!");
595 }
596 org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
597 org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
598 return (new Client(prot)).recv_alter_sentry_role_delete_groups();
599 }
600 }
601
602 public void list_sentry_roles_by_group(TListSentryRolesRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
603 checkReady();
604 list_sentry_roles_by_group_call method_call = new list_sentry_roles_by_group_call(request, resultHandler, this, ___protocolFactory, ___transport);
605 this.___currentMethod = method_call;
606 ___manager.call(method_call);
607 }
608
609 public static class list_sentry_roles_by_group_call extends org.apache.thrift.async.TAsyncMethodCall {
610 private TListSentryRolesRequest request;
611 public list_sentry_roles_by_group_call(TListSentryRolesRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
612 super(client, protocolFactory, transport, resultHandler, false);
613 this.request = request;
614 }
615
616 public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
617 prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("list_sentry_roles_by_group", org.apache.thrift.protocol.TMessageType.CALL, 0));
618 list_sentry_roles_by_group_args args = new list_sentry_roles_by_group_args();
619 args.setRequest(request);
620 args.write(prot);
621 prot.writeMessageEnd();
622 }
623
624 public TListSentryRolesResponse getResult() throws org.apache.thrift.TException {
625 if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
626 throw new IllegalStateException("Method call not finished!");
627 }
628 org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
629 org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
630 return (new Client(prot)).recv_list_sentry_roles_by_group();
631 }
632 }
633
634 public void list_sentry_privileges_by_role(TListSentryPrivilegesRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
635 checkReady();
636 list_sentry_privileges_by_role_call method_call = new list_sentry_privileges_by_role_call(request, resultHandler, this, ___protocolFactory, ___transport);
637 this.___currentMethod = method_call;
638 ___manager.call(method_call);
639 }
640
641 public static class list_sentry_privileges_by_role_call extends org.apache.thrift.async.TAsyncMethodCall {
642 private TListSentryPrivilegesRequest request;
643 public list_sentry_privileges_by_role_call(TListSentryPrivilegesRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
644 super(client, protocolFactory, transport, resultHandler, false);
645 this.request = request;
646 }
647
648 public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
649 prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("list_sentry_privileges_by_role", org.apache.thrift.protocol.TMessageType.CALL, 0));
650 list_sentry_privileges_by_role_args args = new list_sentry_privileges_by_role_args();
651 args.setRequest(request);
652 args.write(prot);
653 prot.writeMessageEnd();
654 }
655
656 public TListSentryPrivilegesResponse getResult() throws org.apache.thrift.TException {
657 if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
658 throw new IllegalStateException("Method call not finished!");
659 }
660 org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
661 org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
662 return (new Client(prot)).recv_list_sentry_privileges_by_role();
663 }
664 }
665
666 public void list_sentry_privileges_for_provider(TListSentryPrivilegesForProviderRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
667 checkReady();
668 list_sentry_privileges_for_provider_call method_call = new list_sentry_privileges_for_provider_call(request, resultHandler, this, ___protocolFactory, ___transport);
669 this.___currentMethod = method_call;
670 ___manager.call(method_call);
671 }
672
673 public static class list_sentry_privileges_for_provider_call extends org.apache.thrift.async.TAsyncMethodCall {
674 private TListSentryPrivilegesForProviderRequest request;
675 public list_sentry_privileges_for_provider_call(TListSentryPrivilegesForProviderRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
676 super(client, protocolFactory, transport, resultHandler, false);
677 this.request = request;
678 }
679
680 public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
681 prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("list_sentry_privileges_for_provider", org.apache.thrift.protocol.TMessageType.CALL, 0));
682 list_sentry_privileges_for_provider_args args = new list_sentry_privileges_for_provider_args();
683 args.setRequest(request);
684 args.write(prot);
685 prot.writeMessageEnd();
686 }
687
688 public TListSentryPrivilegesForProviderResponse getResult() throws org.apache.thrift.TException {
689 if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
690 throw new IllegalStateException("Method call not finished!");
691 }
692 org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
693 org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
694 return (new Client(prot)).recv_list_sentry_privileges_for_provider();
695 }
696 }
697
698 public void list_sentry_privileges_by_authorizable(TListSentryPrivilegesByAuthRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
699 checkReady();
700 list_sentry_privileges_by_authorizable_call method_call = new list_sentry_privileges_by_authorizable_call(request, resultHandler, this, ___protocolFactory, ___transport);
701 this.___currentMethod = method_call;
702 ___manager.call(method_call);
703 }
704
705 public static class list_sentry_privileges_by_authorizable_call extends org.apache.thrift.async.TAsyncMethodCall {
706 private TListSentryPrivilegesByAuthRequest request;
707 public list_sentry_privileges_by_authorizable_call(TListSentryPrivilegesByAuthRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
708 super(client, protocolFactory, transport, resultHandler, false);
709 this.request = request;
710 }
711
712 public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
713 prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("list_sentry_privileges_by_authorizable", org.apache.thrift.protocol.TMessageType.CALL, 0));
714 list_sentry_privileges_by_authorizable_args args = new list_sentry_privileges_by_authorizable_args();
715 args.setRequest(request);
716 args.write(prot);
717 prot.writeMessageEnd();
718 }
719
720 public TListSentryPrivilegesByAuthResponse getResult() throws org.apache.thrift.TException {
721 if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
722 throw new IllegalStateException("Method call not finished!");
723 }
724 org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
725 org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
726 return (new Client(prot)).recv_list_sentry_privileges_by_authorizable();
727 }
728 }
729
730 public void drop_sentry_privilege(TDropPrivilegesRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
731 checkReady();
732 drop_sentry_privilege_call method_call = new drop_sentry_privilege_call(request, resultHandler, this, ___protocolFactory, ___transport);
733 this.___currentMethod = method_call;
734 ___manager.call(method_call);
735 }
736
737 public static class drop_sentry_privilege_call extends org.apache.thrift.async.TAsyncMethodCall {
738 private TDropPrivilegesRequest request;
739 public drop_sentry_privilege_call(TDropPrivilegesRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
740 super(client, protocolFactory, transport, resultHandler, false);
741 this.request = request;
742 }
743
744 public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
745 prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("drop_sentry_privilege", org.apache.thrift.protocol.TMessageType.CALL, 0));
746 drop_sentry_privilege_args args = new drop_sentry_privilege_args();
747 args.setRequest(request);
748 args.write(prot);
749 prot.writeMessageEnd();
750 }
751
752 public TDropPrivilegesResponse getResult() throws org.apache.thrift.TException {
753 if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
754 throw new IllegalStateException("Method call not finished!");
755 }
756 org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
757 org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
758 return (new Client(prot)).recv_drop_sentry_privilege();
759 }
760 }
761
762 public void rename_sentry_privilege(TRenamePrivilegesRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler) throws org.apache.thrift.TException {
763 checkReady();
764 rename_sentry_privilege_call method_call = new rename_sentry_privilege_call(request, resultHandler, this, ___protocolFactory, ___transport);
765 this.___currentMethod = method_call;
766 ___manager.call(method_call);
767 }
768
769 public static class rename_sentry_privilege_call extends org.apache.thrift.async.TAsyncMethodCall {
770 private TRenamePrivilegesRequest request;
771 public rename_sentry_privilege_call(TRenamePrivilegesRequest request, org.apache.thrift.async.AsyncMethodCallback resultHandler, org.apache.thrift.async.TAsyncClient client, org.apache.thrift.protocol.TProtocolFactory protocolFactory, org.apache.thrift.transport.TNonblockingTransport transport) throws org.apache.thrift.TException {
772 super(client, protocolFactory, transport, resultHandler, false);
773 this.request = request;
774 }
775
776 public void write_args(org.apache.thrift.protocol.TProtocol prot) throws org.apache.thrift.TException {
777 prot.writeMessageBegin(new org.apache.thrift.protocol.TMessage("rename_sentry_privilege", org.apache.thrift.protocol.TMessageType.CALL, 0));
778 rename_sentry_privilege_args args = new rename_sentry_privilege_args();
779 args.setRequest(request);
780 args.write(prot);
781 prot.writeMessageEnd();
782 }
783
784 public TRenamePrivilegesResponse getResult() throws org.apache.thrift.TException {
785 if (getState() != org.apache.thrift.async.TAsyncMethodCall.State.RESPONSE_READ) {
786 throw new IllegalStateException("Method call not finished!");
787 }
788 org.apache.thrift.transport.TMemoryInputTransport memoryTransport = new org.apache.thrift.transport.TMemoryInputTransport(getFrameBuffer().array());
789 org.apache.thrift.protocol.TProtocol prot = client.getProtocolFactory().getProtocol(memoryTransport);
790 return (new Client(prot)).recv_rename_sentry_privilege();
791 }
792 }
793
794 }
795
796 public static class Processor<I extends Iface> extends org.apache.thrift.TBaseProcessor<I> implements org.apache.thrift.TProcessor {
797 private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
798 public Processor(I iface) {
799 super(iface, getProcessMap(new HashMap<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>>()));
800 }
801
802 protected Processor(I iface, Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {
803 super(iface, getProcessMap(processMap));
804 }
805
806 private static <I extends Iface> Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> getProcessMap(Map<String, org.apache.thrift.ProcessFunction<I, ? extends org.apache.thrift.TBase>> processMap) {
807 processMap.put("create_sentry_role", new create_sentry_role());
808 processMap.put("drop_sentry_role", new drop_sentry_role());
809 processMap.put("alter_sentry_role_grant_privilege", new alter_sentry_role_grant_privilege());
810 processMap.put("alter_sentry_role_revoke_privilege", new alter_sentry_role_revoke_privilege());
811 processMap.put("alter_sentry_role_add_groups", new alter_sentry_role_add_groups());
812 processMap.put("alter_sentry_role_delete_groups", new alter_sentry_role_delete_groups());
813 processMap.put("list_sentry_roles_by_group", new list_sentry_roles_by_group());
814 processMap.put("list_sentry_privileges_by_role", new list_sentry_privileges_by_role());
815 processMap.put("list_sentry_privileges_for_provider", new list_sentry_privileges_for_provider());
816 processMap.put("list_sentry_privileges_by_authorizable", new list_sentry_privileges_by_authorizable());
817 processMap.put("drop_sentry_privilege", new drop_sentry_privilege());
818 processMap.put("rename_sentry_privilege", new rename_sentry_privilege());
819 return processMap;
820 }
821
822 public static class create_sentry_role<I extends Iface> extends org.apache.thrift.ProcessFunction<I, create_sentry_role_args> {
823 public create_sentry_role() {
824 super("create_sentry_role");
825 }
826
827 public create_sentry_role_args getEmptyArgsInstance() {
828 return new create_sentry_role_args();
829 }
830
831 protected boolean isOneway() {
832 return false;
833 }
834
835 public create_sentry_role_result getResult(I iface, create_sentry_role_args args) throws org.apache.thrift.TException {
836 create_sentry_role_result result = new create_sentry_role_result();
837 result.success = iface.create_sentry_role(args.request);
838 return result;
839 }
840 }
841
842 public static class drop_sentry_role<I extends Iface> extends org.apache.thrift.ProcessFunction<I, drop_sentry_role_args> {
843 public drop_sentry_role() {
844 super("drop_sentry_role");
845 }
846
847 public drop_sentry_role_args getEmptyArgsInstance() {
848 return new drop_sentry_role_args();
849 }
850
851 protected boolean isOneway() {
852 return false;
853 }
854
855 public drop_sentry_role_result getResult(I iface, drop_sentry_role_args args) throws org.apache.thrift.TException {
856 drop_sentry_role_result result = new drop_sentry_role_result();
857 result.success = iface.drop_sentry_role(args.request);
858 return result;
859 }
860 }
861
862 public static class alter_sentry_role_grant_privilege<I extends Iface> extends org.apache.thrift.ProcessFunction<I, alter_sentry_role_grant_privilege_args> {
863 public alter_sentry_role_grant_privilege() {
864 super("alter_sentry_role_grant_privilege");
865 }
866
867 public alter_sentry_role_grant_privilege_args getEmptyArgsInstance() {
868 return new alter_sentry_role_grant_privilege_args();
869 }
870
871 protected boolean isOneway() {
872 return false;
873 }
874
875 public alter_sentry_role_grant_privilege_result getResult(I iface, alter_sentry_role_grant_privilege_args args) throws org.apache.thrift.TException {
876 alter_sentry_role_grant_privilege_result result = new alter_sentry_role_grant_privilege_result();
877 result.success = iface.alter_sentry_role_grant_privilege(args.request);
878 return result;
879 }
880 }
881
882 public static class alter_sentry_role_revoke_privilege<I extends Iface> extends org.apache.thrift.ProcessFunction<I, alter_sentry_role_revoke_privilege_args> {
883 public alter_sentry_role_revoke_privilege() {
884 super("alter_sentry_role_revoke_privilege");
885 }
886
887 public alter_sentry_role_revoke_privilege_args getEmptyArgsInstance() {
888 return new alter_sentry_role_revoke_privilege_args();
889 }
890
891 protected boolean isOneway() {
892 return false;
893 }
894
895 public alter_sentry_role_revoke_privilege_result getResult(I iface, alter_sentry_role_revoke_privilege_args args) throws org.apache.thrift.TException {
896 alter_sentry_role_revoke_privilege_result result = new alter_sentry_role_revoke_privilege_result();
897 result.success = iface.alter_sentry_role_revoke_privilege(args.request);
898 return result;
899 }
900 }
901
902 public static class alter_sentry_role_add_groups<I extends Iface> extends org.apache.thrift.ProcessFunction<I, alter_sentry_role_add_groups_args> {
903 public alter_sentry_role_add_groups() {
904 super("alter_sentry_role_add_groups");
905 }
906
907 public alter_sentry_role_add_groups_args getEmptyArgsInstance() {
908 return new alter_sentry_role_add_groups_args();
909 }
910
911 protected boolean isOneway() {
912 return false;
913 }
914
915 public alter_sentry_role_add_groups_result getResult(I iface, alter_sentry_role_add_groups_args args) throws org.apache.thrift.TException {
916 alter_sentry_role_add_groups_result result = new alter_sentry_role_add_groups_result();
917 result.success = iface.alter_sentry_role_add_groups(args.request);
918 return result;
919 }
920 }
921
922 public static class alter_sentry_role_delete_groups<I extends Iface> extends org.apache.thrift.ProcessFunction<I, alter_sentry_role_delete_groups_args> {
923 public alter_sentry_role_delete_groups() {
924 super("alter_sentry_role_delete_groups");
925 }
926
927 public alter_sentry_role_delete_groups_args getEmptyArgsInstance() {
928 return new alter_sentry_role_delete_groups_args();
929 }
930
931 protected boolean isOneway() {
932 return false;
933 }
934
935 public alter_sentry_role_delete_groups_result getResult(I iface, alter_sentry_role_delete_groups_args args) throws org.apache.thrift.TException {
936 alter_sentry_role_delete_groups_result result = new alter_sentry_role_delete_groups_result();
937 result.success = iface.alter_sentry_role_delete_groups(args.request);
938 return result;
939 }
940 }
941
942 public static class list_sentry_roles_by_group<I extends Iface> extends org.apache.thrift.ProcessFunction<I, list_sentry_roles_by_group_args> {
943 public list_sentry_roles_by_group() {
944 super("list_sentry_roles_by_group");
945 }
946
947 public list_sentry_roles_by_group_args getEmptyArgsInstance() {
948 return new list_sentry_roles_by_group_args();
949 }
950
951 protected boolean isOneway() {
952 return false;
953 }
954
955 public list_sentry_roles_by_group_result getResult(I iface, list_sentry_roles_by_group_args args) throws org.apache.thrift.TException {
956 list_sentry_roles_by_group_result result = new list_sentry_roles_by_group_result();
957 result.success = iface.list_sentry_roles_by_group(args.request);
958 return result;
959 }
960 }
961
962 public static class list_sentry_privileges_by_role<I extends Iface> extends org.apache.thrift.ProcessFunction<I, list_sentry_privileges_by_role_args> {
963 public list_sentry_privileges_by_role() {
964 super("list_sentry_privileges_by_role");
965 }
966
967 public list_sentry_privileges_by_role_args getEmptyArgsInstance() {
968 return new list_sentry_privileges_by_role_args();
969 }
970
971 protected boolean isOneway() {
972 return false;
973 }
974
975 public list_sentry_privileges_by_role_result getResult(I iface, list_sentry_privileges_by_role_args args) throws org.apache.thrift.TException {
976 list_sentry_privileges_by_role_result result = new list_sentry_privileges_by_role_result();
977 result.success = iface.list_sentry_privileges_by_role(args.request);
978 return result;
979 }
980 }
981
982 public static class list_sentry_privileges_for_provider<I extends Iface> extends org.apache.thrift.ProcessFunction<I, list_sentry_privileges_for_provider_args> {
983 public list_sentry_privileges_for_provider() {
984 super("list_sentry_privileges_for_provider");
985 }
986
987 public list_sentry_privileges_for_provider_args getEmptyArgsInstance() {
988 return new list_sentry_privileges_for_provider_args();
989 }
990
991 protected boolean isOneway() {
992 return false;
993 }
994
995 public list_sentry_privileges_for_provider_result getResult(I iface, list_sentry_privileges_for_provider_args args) throws org.apache.thrift.TException {
996 list_sentry_privileges_for_provider_result result = new list_sentry_privileges_for_provider_result();
997 result.success = iface.list_sentry_privileges_for_provider(args.request);
998 return result;
999 }
1000 }
1001
1002 public static class list_sentry_privileges_by_authorizable<I extends Iface> extends org.apache.thrift.ProcessFunction<I, list_sentry_privileges_by_authorizable_args> {
1003 public list_sentry_privileges_by_authorizable() {
1004 super("list_sentry_privileges_by_authorizable");
1005 }
1006
1007 public list_sentry_privileges_by_authorizable_args getEmptyArgsInstance() {
1008 return new list_sentry_privileges_by_authorizable_args();
1009 }
1010
1011 protected boolean isOneway() {
1012 return false;
1013 }
1014
1015 public list_sentry_privileges_by_authorizable_result getResult(I iface, list_sentry_privileges_by_authorizable_args args) throws org.apache.thrift.TException {
1016 list_sentry_privileges_by_authorizable_result result = new list_sentry_privileges_by_authorizable_result();
1017 result.success = iface.list_sentry_privileges_by_authorizable(args.request);
1018 return result;
1019 }
1020 }
1021
1022 public static class drop_sentry_privilege<I extends Iface> extends org.apache.thrift.ProcessFunction<I, drop_sentry_privilege_args> {
1023 public drop_sentry_privilege() {
1024 super("drop_sentry_privilege");
1025 }
1026
1027 public drop_sentry_privilege_args getEmptyArgsInstance() {
1028 return new drop_sentry_privilege_args();
1029 }
1030
1031 protected boolean isOneway() {
1032 return false;
1033 }
1034
1035 public drop_sentry_privilege_result getResult(I iface, drop_sentry_privilege_args args) throws org.apache.thrift.TException {
1036 drop_sentry_privilege_result result = new drop_sentry_privilege_result();
1037 result.success = iface.drop_sentry_privilege(args.request);
1038 return result;
1039 }
1040 }
1041
1042 public static class rename_sentry_privilege<I extends Iface> extends org.apache.thrift.ProcessFunction<I, rename_sentry_privilege_args> {
1043 public rename_sentry_privilege() {
1044 super("rename_sentry_privilege");
1045 }
1046
1047 public rename_sentry_privilege_args getEmptyArgsInstance() {
1048 return new rename_sentry_privilege_args();
1049 }
1050
1051 protected boolean isOneway() {
1052 return false;
1053 }
1054
1055 public rename_sentry_privilege_result getResult(I iface, rename_sentry_privilege_args args) throws org.apache.thrift.TException {
1056 rename_sentry_privilege_result result = new rename_sentry_privilege_result();
1057 result.success = iface.rename_sentry_privilege(args.request);
1058 return result;
1059 }
1060 }
1061
1062 }
1063
1064 public static class AsyncProcessor<I extends AsyncIface> extends org.apache.thrift.TBaseAsyncProcessor<I> {
1065 private static final Logger LOGGER = LoggerFactory.getLogger(AsyncProcessor.class.getName());
1066 public AsyncProcessor(I iface) {
1067 super(iface, getProcessMap(new HashMap<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>>()));
1068 }
1069
1070 protected AsyncProcessor(I iface, Map<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>> processMap) {
1071 super(iface, getProcessMap(processMap));
1072 }
1073
1074 private static <I extends AsyncIface> Map<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase,?>> getProcessMap(Map<String, org.apache.thrift.AsyncProcessFunction<I, ? extends org.apache.thrift.TBase, ?>> processMap) {
1075 processMap.put("create_sentry_role", new create_sentry_role());
1076 processMap.put("drop_sentry_role", new drop_sentry_role());
1077 processMap.put("alter_sentry_role_grant_privilege", new alter_sentry_role_grant_privilege());
1078 processMap.put("alter_sentry_role_revoke_privilege", new alter_sentry_role_revoke_privilege());
1079 processMap.put("alter_sentry_role_add_groups", new alter_sentry_role_add_groups());
1080 processMap.put("alter_sentry_role_delete_groups", new alter_sentry_role_delete_groups());
1081 processMap.put("list_sentry_roles_by_group", new list_sentry_roles_by_group());
1082 processMap.put("list_sentry_privileges_by_role", new list_sentry_privileges_by_role());
1083 processMap.put("list_sentry_privileges_for_provider", new list_sentry_privileges_for_provider());
1084 processMap.put("list_sentry_privileges_by_authorizable", new list_sentry_privileges_by_authorizable());
1085 processMap.put("drop_sentry_privilege", new drop_sentry_privilege());
1086 processMap.put("rename_sentry_privilege", new rename_sentry_privilege());
1087 return processMap;
1088 }
1089
1090 public static class create_sentry_role<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, create_sentry_role_args, TCreateSentryRoleResponse> {
1091 public create_sentry_role() {
1092 super("create_sentry_role");
1093 }
1094
1095 public create_sentry_role_args getEmptyArgsInstance() {
1096 return new create_sentry_role_args();
1097 }
1098
1099 public AsyncMethodCallback<TCreateSentryRoleResponse> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
1100 final org.apache.thrift.AsyncProcessFunction fcall = this;
1101 return new AsyncMethodCallback<TCreateSentryRoleResponse>() {
1102 public void onComplete(TCreateSentryRoleResponse o) {
1103 create_sentry_role_result result = new create_sentry_role_result();
1104 result.success = o;
1105 try {
1106 fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
1107 return;
1108 } catch (Exception e) {
1109 LOGGER.error("Exception writing to internal frame buffer", e);
1110 }
1111 fb.close();
1112 }
1113 public void onError(Exception e) {
1114 byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
1115 org.apache.thrift.TBase msg;
1116 create_sentry_role_result result = new create_sentry_role_result();
1117 {
1118 msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
1119 msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
1120 }
1121 try {
1122 fcall.sendResponse(fb,msg,msgType,seqid);
1123 return;
1124 } catch (Exception ex) {
1125 LOGGER.error("Exception writing to internal frame buffer", ex);
1126 }
1127 fb.close();
1128 }
1129 };
1130 }
1131
1132 protected boolean isOneway() {
1133 return false;
1134 }
1135
1136 public void start(I iface, create_sentry_role_args args, org.apache.thrift.async.AsyncMethodCallback<TCreateSentryRoleResponse> resultHandler) throws TException {
1137 iface.create_sentry_role(args.request,resultHandler);
1138 }
1139 }
1140
1141 public static class drop_sentry_role<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, drop_sentry_role_args, TDropSentryRoleResponse> {
1142 public drop_sentry_role() {
1143 super("drop_sentry_role");
1144 }
1145
1146 public drop_sentry_role_args getEmptyArgsInstance() {
1147 return new drop_sentry_role_args();
1148 }
1149
1150 public AsyncMethodCallback<TDropSentryRoleResponse> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
1151 final org.apache.thrift.AsyncProcessFunction fcall = this;
1152 return new AsyncMethodCallback<TDropSentryRoleResponse>() {
1153 public void onComplete(TDropSentryRoleResponse o) {
1154 drop_sentry_role_result result = new drop_sentry_role_result();
1155 result.success = o;
1156 try {
1157 fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
1158 return;
1159 } catch (Exception e) {
1160 LOGGER.error("Exception writing to internal frame buffer", e);
1161 }
1162 fb.close();
1163 }
1164 public void onError(Exception e) {
1165 byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
1166 org.apache.thrift.TBase msg;
1167 drop_sentry_role_result result = new drop_sentry_role_result();
1168 {
1169 msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
1170 msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
1171 }
1172 try {
1173 fcall.sendResponse(fb,msg,msgType,seqid);
1174 return;
1175 } catch (Exception ex) {
1176 LOGGER.error("Exception writing to internal frame buffer", ex);
1177 }
1178 fb.close();
1179 }
1180 };
1181 }
1182
1183 protected boolean isOneway() {
1184 return false;
1185 }
1186
1187 public void start(I iface, drop_sentry_role_args args, org.apache.thrift.async.AsyncMethodCallback<TDropSentryRoleResponse> resultHandler) throws TException {
1188 iface.drop_sentry_role(args.request,resultHandler);
1189 }
1190 }
1191
1192 public static class alter_sentry_role_grant_privilege<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, alter_sentry_role_grant_privilege_args, TAlterSentryRoleGrantPrivilegeResponse> {
1193 public alter_sentry_role_grant_privilege() {
1194 super("alter_sentry_role_grant_privilege");
1195 }
1196
1197 public alter_sentry_role_grant_privilege_args getEmptyArgsInstance() {
1198 return new alter_sentry_role_grant_privilege_args();
1199 }
1200
1201 public AsyncMethodCallback<TAlterSentryRoleGrantPrivilegeResponse> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
1202 final org.apache.thrift.AsyncProcessFunction fcall = this;
1203 return new AsyncMethodCallback<TAlterSentryRoleGrantPrivilegeResponse>() {
1204 public void onComplete(TAlterSentryRoleGrantPrivilegeResponse o) {
1205 alter_sentry_role_grant_privilege_result result = new alter_sentry_role_grant_privilege_result();
1206 result.success = o;
1207 try {
1208 fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
1209 return;
1210 } catch (Exception e) {
1211 LOGGER.error("Exception writing to internal frame buffer", e);
1212 }
1213 fb.close();
1214 }
1215 public void onError(Exception e) {
1216 byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
1217 org.apache.thrift.TBase msg;
1218 alter_sentry_role_grant_privilege_result result = new alter_sentry_role_grant_privilege_result();
1219 {
1220 msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
1221 msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
1222 }
1223 try {
1224 fcall.sendResponse(fb,msg,msgType,seqid);
1225 return;
1226 } catch (Exception ex) {
1227 LOGGER.error("Exception writing to internal frame buffer", ex);
1228 }
1229 fb.close();
1230 }
1231 };
1232 }
1233
1234 protected boolean isOneway() {
1235 return false;
1236 }
1237
1238 public void start(I iface, alter_sentry_role_grant_privilege_args args, org.apache.thrift.async.AsyncMethodCallback<TAlterSentryRoleGrantPrivilegeResponse> resultHandler) throws TException {
1239 iface.alter_sentry_role_grant_privilege(args.request,resultHandler);
1240 }
1241 }
1242
1243 public static class alter_sentry_role_revoke_privilege<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, alter_sentry_role_revoke_privilege_args, TAlterSentryRoleRevokePrivilegeResponse> {
1244 public alter_sentry_role_revoke_privilege() {
1245 super("alter_sentry_role_revoke_privilege");
1246 }
1247
1248 public alter_sentry_role_revoke_privilege_args getEmptyArgsInstance() {
1249 return new alter_sentry_role_revoke_privilege_args();
1250 }
1251
1252 public AsyncMethodCallback<TAlterSentryRoleRevokePrivilegeResponse> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
1253 final org.apache.thrift.AsyncProcessFunction fcall = this;
1254 return new AsyncMethodCallback<TAlterSentryRoleRevokePrivilegeResponse>() {
1255 public void onComplete(TAlterSentryRoleRevokePrivilegeResponse o) {
1256 alter_sentry_role_revoke_privilege_result result = new alter_sentry_role_revoke_privilege_result();
1257 result.success = o;
1258 try {
1259 fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
1260 return;
1261 } catch (Exception e) {
1262 LOGGER.error("Exception writing to internal frame buffer", e);
1263 }
1264 fb.close();
1265 }
1266 public void onError(Exception e) {
1267 byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
1268 org.apache.thrift.TBase msg;
1269 alter_sentry_role_revoke_privilege_result result = new alter_sentry_role_revoke_privilege_result();
1270 {
1271 msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
1272 msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
1273 }
1274 try {
1275 fcall.sendResponse(fb,msg,msgType,seqid);
1276 return;
1277 } catch (Exception ex) {
1278 LOGGER.error("Exception writing to internal frame buffer", ex);
1279 }
1280 fb.close();
1281 }
1282 };
1283 }
1284
1285 protected boolean isOneway() {
1286 return false;
1287 }
1288
1289 public void start(I iface, alter_sentry_role_revoke_privilege_args args, org.apache.thrift.async.AsyncMethodCallback<TAlterSentryRoleRevokePrivilegeResponse> resultHandler) throws TException {
1290 iface.alter_sentry_role_revoke_privilege(args.request,resultHandler);
1291 }
1292 }
1293
1294 public static class alter_sentry_role_add_groups<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, alter_sentry_role_add_groups_args, TAlterSentryRoleAddGroupsResponse> {
1295 public alter_sentry_role_add_groups() {
1296 super("alter_sentry_role_add_groups");
1297 }
1298
1299 public alter_sentry_role_add_groups_args getEmptyArgsInstance() {
1300 return new alter_sentry_role_add_groups_args();
1301 }
1302
1303 public AsyncMethodCallback<TAlterSentryRoleAddGroupsResponse> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
1304 final org.apache.thrift.AsyncProcessFunction fcall = this;
1305 return new AsyncMethodCallback<TAlterSentryRoleAddGroupsResponse>() {
1306 public void onComplete(TAlterSentryRoleAddGroupsResponse o) {
1307 alter_sentry_role_add_groups_result result = new alter_sentry_role_add_groups_result();
1308 result.success = o;
1309 try {
1310 fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
1311 return;
1312 } catch (Exception e) {
1313 LOGGER.error("Exception writing to internal frame buffer", e);
1314 }
1315 fb.close();
1316 }
1317 public void onError(Exception e) {
1318 byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
1319 org.apache.thrift.TBase msg;
1320 alter_sentry_role_add_groups_result result = new alter_sentry_role_add_groups_result();
1321 {
1322 msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
1323 msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
1324 }
1325 try {
1326 fcall.sendResponse(fb,msg,msgType,seqid);
1327 return;
1328 } catch (Exception ex) {
1329 LOGGER.error("Exception writing to internal frame buffer", ex);
1330 }
1331 fb.close();
1332 }
1333 };
1334 }
1335
1336 protected boolean isOneway() {
1337 return false;
1338 }
1339
1340 public void start(I iface, alter_sentry_role_add_groups_args args, org.apache.thrift.async.AsyncMethodCallback<TAlterSentryRoleAddGroupsResponse> resultHandler) throws TException {
1341 iface.alter_sentry_role_add_groups(args.request,resultHandler);
1342 }
1343 }
1344
1345 public static class alter_sentry_role_delete_groups<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, alter_sentry_role_delete_groups_args, TAlterSentryRoleDeleteGroupsResponse> {
1346 public alter_sentry_role_delete_groups() {
1347 super("alter_sentry_role_delete_groups");
1348 }
1349
1350 public alter_sentry_role_delete_groups_args getEmptyArgsInstance() {
1351 return new alter_sentry_role_delete_groups_args();
1352 }
1353
1354 public AsyncMethodCallback<TAlterSentryRoleDeleteGroupsResponse> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
1355 final org.apache.thrift.AsyncProcessFunction fcall = this;
1356 return new AsyncMethodCallback<TAlterSentryRoleDeleteGroupsResponse>() {
1357 public void onComplete(TAlterSentryRoleDeleteGroupsResponse o) {
1358 alter_sentry_role_delete_groups_result result = new alter_sentry_role_delete_groups_result();
1359 result.success = o;
1360 try {
1361 fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
1362 return;
1363 } catch (Exception e) {
1364 LOGGER.error("Exception writing to internal frame buffer", e);
1365 }
1366 fb.close();
1367 }
1368 public void onError(Exception e) {
1369 byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
1370 org.apache.thrift.TBase msg;
1371 alter_sentry_role_delete_groups_result result = new alter_sentry_role_delete_groups_result();
1372 {
1373 msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
1374 msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
1375 }
1376 try {
1377 fcall.sendResponse(fb,msg,msgType,seqid);
1378 return;
1379 } catch (Exception ex) {
1380 LOGGER.error("Exception writing to internal frame buffer", ex);
1381 }
1382 fb.close();
1383 }
1384 };
1385 }
1386
1387 protected boolean isOneway() {
1388 return false;
1389 }
1390
1391 public void start(I iface, alter_sentry_role_delete_groups_args args, org.apache.thrift.async.AsyncMethodCallback<TAlterSentryRoleDeleteGroupsResponse> resultHandler) throws TException {
1392 iface.alter_sentry_role_delete_groups(args.request,resultHandler);
1393 }
1394 }
1395
1396 public static class list_sentry_roles_by_group<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, list_sentry_roles_by_group_args, TListSentryRolesResponse> {
1397 public list_sentry_roles_by_group() {
1398 super("list_sentry_roles_by_group");
1399 }
1400
1401 public list_sentry_roles_by_group_args getEmptyArgsInstance() {
1402 return new list_sentry_roles_by_group_args();
1403 }
1404
1405 public AsyncMethodCallback<TListSentryRolesResponse> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
1406 final org.apache.thrift.AsyncProcessFunction fcall = this;
1407 return new AsyncMethodCallback<TListSentryRolesResponse>() {
1408 public void onComplete(TListSentryRolesResponse o) {
1409 list_sentry_roles_by_group_result result = new list_sentry_roles_by_group_result();
1410 result.success = o;
1411 try {
1412 fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
1413 return;
1414 } catch (Exception e) {
1415 LOGGER.error("Exception writing to internal frame buffer", e);
1416 }
1417 fb.close();
1418 }
1419 public void onError(Exception e) {
1420 byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
1421 org.apache.thrift.TBase msg;
1422 list_sentry_roles_by_group_result result = new list_sentry_roles_by_group_result();
1423 {
1424 msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
1425 msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
1426 }
1427 try {
1428 fcall.sendResponse(fb,msg,msgType,seqid);
1429 return;
1430 } catch (Exception ex) {
1431 LOGGER.error("Exception writing to internal frame buffer", ex);
1432 }
1433 fb.close();
1434 }
1435 };
1436 }
1437
1438 protected boolean isOneway() {
1439 return false;
1440 }
1441
1442 public void start(I iface, list_sentry_roles_by_group_args args, org.apache.thrift.async.AsyncMethodCallback<TListSentryRolesResponse> resultHandler) throws TException {
1443 iface.list_sentry_roles_by_group(args.request,resultHandler);
1444 }
1445 }
1446
1447 public static class list_sentry_privileges_by_role<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, list_sentry_privileges_by_role_args, TListSentryPrivilegesResponse> {
1448 public list_sentry_privileges_by_role() {
1449 super("list_sentry_privileges_by_role");
1450 }
1451
1452 public list_sentry_privileges_by_role_args getEmptyArgsInstance() {
1453 return new list_sentry_privileges_by_role_args();
1454 }
1455
1456 public AsyncMethodCallback<TListSentryPrivilegesResponse> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
1457 final org.apache.thrift.AsyncProcessFunction fcall = this;
1458 return new AsyncMethodCallback<TListSentryPrivilegesResponse>() {
1459 public void onComplete(TListSentryPrivilegesResponse o) {
1460 list_sentry_privileges_by_role_result result = new list_sentry_privileges_by_role_result();
1461 result.success = o;
1462 try {
1463 fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
1464 return;
1465 } catch (Exception e) {
1466 LOGGER.error("Exception writing to internal frame buffer", e);
1467 }
1468 fb.close();
1469 }
1470 public void onError(Exception e) {
1471 byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
1472 org.apache.thrift.TBase msg;
1473 list_sentry_privileges_by_role_result result = new list_sentry_privileges_by_role_result();
1474 {
1475 msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
1476 msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
1477 }
1478 try {
1479 fcall.sendResponse(fb,msg,msgType,seqid);
1480 return;
1481 } catch (Exception ex) {
1482 LOGGER.error("Exception writing to internal frame buffer", ex);
1483 }
1484 fb.close();
1485 }
1486 };
1487 }
1488
1489 protected boolean isOneway() {
1490 return false;
1491 }
1492
1493 public void start(I iface, list_sentry_privileges_by_role_args args, org.apache.thrift.async.AsyncMethodCallback<TListSentryPrivilegesResponse> resultHandler) throws TException {
1494 iface.list_sentry_privileges_by_role(args.request,resultHandler);
1495 }
1496 }
1497
1498 public static class list_sentry_privileges_for_provider<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, list_sentry_privileges_for_provider_args, TListSentryPrivilegesForProviderResponse> {
1499 public list_sentry_privileges_for_provider() {
1500 super("list_sentry_privileges_for_provider");
1501 }
1502
1503 public list_sentry_privileges_for_provider_args getEmptyArgsInstance() {
1504 return new list_sentry_privileges_for_provider_args();
1505 }
1506
1507 public AsyncMethodCallback<TListSentryPrivilegesForProviderResponse> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
1508 final org.apache.thrift.AsyncProcessFunction fcall = this;
1509 return new AsyncMethodCallback<TListSentryPrivilegesForProviderResponse>() {
1510 public void onComplete(TListSentryPrivilegesForProviderResponse o) {
1511 list_sentry_privileges_for_provider_result result = new list_sentry_privileges_for_provider_result();
1512 result.success = o;
1513 try {
1514 fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
1515 return;
1516 } catch (Exception e) {
1517 LOGGER.error("Exception writing to internal frame buffer", e);
1518 }
1519 fb.close();
1520 }
1521 public void onError(Exception e) {
1522 byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
1523 org.apache.thrift.TBase msg;
1524 list_sentry_privileges_for_provider_result result = new list_sentry_privileges_for_provider_result();
1525 {
1526 msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
1527 msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
1528 }
1529 try {
1530 fcall.sendResponse(fb,msg,msgType,seqid);
1531 return;
1532 } catch (Exception ex) {
1533 LOGGER.error("Exception writing to internal frame buffer", ex);
1534 }
1535 fb.close();
1536 }
1537 };
1538 }
1539
1540 protected boolean isOneway() {
1541 return false;
1542 }
1543
1544 public void start(I iface, list_sentry_privileges_for_provider_args args, org.apache.thrift.async.AsyncMethodCallback<TListSentryPrivilegesForProviderResponse> resultHandler) throws TException {
1545 iface.list_sentry_privileges_for_provider(args.request,resultHandler);
1546 }
1547 }
1548
1549 public static class list_sentry_privileges_by_authorizable<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, list_sentry_privileges_by_authorizable_args, TListSentryPrivilegesByAuthResponse> {
1550 public list_sentry_privileges_by_authorizable() {
1551 super("list_sentry_privileges_by_authorizable");
1552 }
1553
1554 public list_sentry_privileges_by_authorizable_args getEmptyArgsInstance() {
1555 return new list_sentry_privileges_by_authorizable_args();
1556 }
1557
1558 public AsyncMethodCallback<TListSentryPrivilegesByAuthResponse> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
1559 final org.apache.thrift.AsyncProcessFunction fcall = this;
1560 return new AsyncMethodCallback<TListSentryPrivilegesByAuthResponse>() {
1561 public void onComplete(TListSentryPrivilegesByAuthResponse o) {
1562 list_sentry_privileges_by_authorizable_result result = new list_sentry_privileges_by_authorizable_result();
1563 result.success = o;
1564 try {
1565 fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
1566 return;
1567 } catch (Exception e) {
1568 LOGGER.error("Exception writing to internal frame buffer", e);
1569 }
1570 fb.close();
1571 }
1572 public void onError(Exception e) {
1573 byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
1574 org.apache.thrift.TBase msg;
1575 list_sentry_privileges_by_authorizable_result result = new list_sentry_privileges_by_authorizable_result();
1576 {
1577 msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
1578 msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
1579 }
1580 try {
1581 fcall.sendResponse(fb,msg,msgType,seqid);
1582 return;
1583 } catch (Exception ex) {
1584 LOGGER.error("Exception writing to internal frame buffer", ex);
1585 }
1586 fb.close();
1587 }
1588 };
1589 }
1590
1591 protected boolean isOneway() {
1592 return false;
1593 }
1594
1595 public void start(I iface, list_sentry_privileges_by_authorizable_args args, org.apache.thrift.async.AsyncMethodCallback<TListSentryPrivilegesByAuthResponse> resultHandler) throws TException {
1596 iface.list_sentry_privileges_by_authorizable(args.request,resultHandler);
1597 }
1598 }
1599
1600 public static class drop_sentry_privilege<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, drop_sentry_privilege_args, TDropPrivilegesResponse> {
1601 public drop_sentry_privilege() {
1602 super("drop_sentry_privilege");
1603 }
1604
1605 public drop_sentry_privilege_args getEmptyArgsInstance() {
1606 return new drop_sentry_privilege_args();
1607 }
1608
1609 public AsyncMethodCallback<TDropPrivilegesResponse> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
1610 final org.apache.thrift.AsyncProcessFunction fcall = this;
1611 return new AsyncMethodCallback<TDropPrivilegesResponse>() {
1612 public void onComplete(TDropPrivilegesResponse o) {
1613 drop_sentry_privilege_result result = new drop_sentry_privilege_result();
1614 result.success = o;
1615 try {
1616 fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
1617 return;
1618 } catch (Exception e) {
1619 LOGGER.error("Exception writing to internal frame buffer", e);
1620 }
1621 fb.close();
1622 }
1623 public void onError(Exception e) {
1624 byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
1625 org.apache.thrift.TBase msg;
1626 drop_sentry_privilege_result result = new drop_sentry_privilege_result();
1627 {
1628 msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
1629 msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
1630 }
1631 try {
1632 fcall.sendResponse(fb,msg,msgType,seqid);
1633 return;
1634 } catch (Exception ex) {
1635 LOGGER.error("Exception writing to internal frame buffer", ex);
1636 }
1637 fb.close();
1638 }
1639 };
1640 }
1641
1642 protected boolean isOneway() {
1643 return false;
1644 }
1645
1646 public void start(I iface, drop_sentry_privilege_args args, org.apache.thrift.async.AsyncMethodCallback<TDropPrivilegesResponse> resultHandler) throws TException {
1647 iface.drop_sentry_privilege(args.request,resultHandler);
1648 }
1649 }
1650
1651 public static class rename_sentry_privilege<I extends AsyncIface> extends org.apache.thrift.AsyncProcessFunction<I, rename_sentry_privilege_args, TRenamePrivilegesResponse> {
1652 public rename_sentry_privilege() {
1653 super("rename_sentry_privilege");
1654 }
1655
1656 public rename_sentry_privilege_args getEmptyArgsInstance() {
1657 return new rename_sentry_privilege_args();
1658 }
1659
1660 public AsyncMethodCallback<TRenamePrivilegesResponse> getResultHandler(final AsyncFrameBuffer fb, final int seqid) {
1661 final org.apache.thrift.AsyncProcessFunction fcall = this;
1662 return new AsyncMethodCallback<TRenamePrivilegesResponse>() {
1663 public void onComplete(TRenamePrivilegesResponse o) {
1664 rename_sentry_privilege_result result = new rename_sentry_privilege_result();
1665 result.success = o;
1666 try {
1667 fcall.sendResponse(fb,result, org.apache.thrift.protocol.TMessageType.REPLY,seqid);
1668 return;
1669 } catch (Exception e) {
1670 LOGGER.error("Exception writing to internal frame buffer", e);
1671 }
1672 fb.close();
1673 }
1674 public void onError(Exception e) {
1675 byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
1676 org.apache.thrift.TBase msg;
1677 rename_sentry_privilege_result result = new rename_sentry_privilege_result();
1678 {
1679 msgType = org.apache.thrift.protocol.TMessageType.EXCEPTION;
1680 msg = (org.apache.thrift.TBase)new org.apache.thrift.TApplicationException(org.apache.thrift.TApplicationException.INTERNAL_ERROR, e.getMessage());
1681 }
1682 try {
1683 fcall.sendResponse(fb,msg,msgType,seqid);
1684 return;
1685 } catch (Exception ex) {
1686 LOGGER.error("Exception writing to internal frame buffer", ex);
1687 }
1688 fb.close();
1689 }
1690 };
1691 }
1692
1693 protected boolean isOneway() {
1694 return false;
1695 }
1696
1697 public void start(I iface, rename_sentry_privilege_args args, org.apache.thrift.async.AsyncMethodCallback<TRenamePrivilegesResponse> resultHandler) throws TException {
1698 iface.rename_sentry_privilege(args.request,resultHandler);
1699 }
1700 }
1701
1702 }
1703
1704 public static class create_sentry_role_args implements org.apache.thrift.TBase<create_sentry_role_args, create_sentry_role_args._Fields>, java.io.Serializable, Cloneable, Comparable<create_sentry_role_args> {
1705 private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("create_sentry_role_args");
1706
1707 private static final org.apache.thrift.protocol.TField REQUEST_FIELD_DESC = new org.apache.thrift.protocol.TField("request", org.apache.thrift.protocol.TType.STRUCT, (short)1);
1708
1709 private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
1710 static {
1711 schemes.put(StandardScheme.class, new create_sentry_role_argsStandardSchemeFactory());
1712 schemes.put(TupleScheme.class, new create_sentry_role_argsTupleSchemeFactory());
1713 }
1714
1715 private TCreateSentryRoleRequest request; // required
1716
1717 /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
1718 public enum _Fields implements org.apache.thrift.TFieldIdEnum {
1719 REQUEST((short)1, "request");
1720
1721 private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
1722
1723 static {
1724 for (_Fields field : EnumSet.allOf(_Fields.class)) {
1725 byName.put(field.getFieldName(), field);
1726 }
1727 }
1728
1729 /**
1730 * Find the _Fields constant that matches fieldId, or null if its not found.
1731 */
1732 public static _Fields findByThriftId(int fieldId) {
1733 switch(fieldId) {
1734 case 1: // REQUEST
1735 return REQUEST;
1736 default:
1737 return null;
1738 }
1739 }
1740
1741 /**
1742 * Find the _Fields constant that matches fieldId, throwing an exception
1743 * if it is not found.
1744 */
1745 public static _Fields findByThriftIdOrThrow(int fieldId) {
1746 _Fields fields = findByThriftId(fieldId);
1747 if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
1748 return fields;
1749 }
1750
1751 /**
1752 * Find the _Fields constant that matches name, or null if its not found.
1753 */
1754 public static _Fields findByName(String name) {
1755 return byName.get(name);
1756 }
1757
1758 private final short _thriftId;
1759 private final String _fieldName;
1760
1761 _Fields(short thriftId, String fieldName) {
1762 _thriftId = thriftId;
1763 _fieldName = fieldName;
1764 }
1765
1766 public short getThriftFieldId() {
1767 return _thriftId;
1768 }
1769
1770 public String getFieldName() {
1771 return _fieldName;
1772 }
1773 }
1774
1775 // isset id assignments
1776 public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
1777 static {
1778 Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
1779 tmpMap.put(_Fields.REQUEST, new org.apache.thrift.meta_data.FieldMetaData("request", org.apache.thrift.TFieldRequirementType.DEFAULT,
1780 new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TCreateSentryRoleRequest.class)));
1781 metaDataMap = Collections.unmodifiableMap(tmpMap);
1782 org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(create_sentry_role_args.class, metaDataMap);
1783 }
1784
1785 public create_sentry_role_args() {
1786 }
1787
1788 public create_sentry_role_args(
1789 TCreateSentryRoleRequest request)
1790 {
1791 this();
1792 this.request = request;
1793 }
1794
1795 /**
1796 * Performs a deep copy on <i>other</i>.
1797 */
1798 public create_sentry_role_args(create_sentry_role_args other) {
1799 if (other.isSetRequest()) {
1800 this.request = new TCreateSentryRoleRequest(other.request);
1801 }
1802 }
1803
1804 public create_sentry_role_args deepCopy() {
1805 return new create_sentry_role_args(this);
1806 }
1807
1808 @Override
1809 public void clear() {
1810 this.request = null;
1811 }
1812
1813 public TCreateSentryRoleRequest getRequest() {
1814 return this.request;
1815 }
1816
1817 public void setRequest(TCreateSentryRoleRequest request) {
1818 this.request = request;
1819 }
1820
1821 public void unsetRequest() {
1822 this.request = null;
1823 }
1824
1825 /** Returns true if field request is set (has been assigned a value) and false otherwise */
1826 public boolean isSetRequest() {
1827 return this.request != null;
1828 }
1829
1830 public void setRequestIsSet(boolean value) {
1831 if (!value) {
1832 this.request = null;
1833 }
1834 }
1835
1836 public void setFieldValue(_Fields field, Object value) {
1837 switch (field) {
1838 case REQUEST:
1839 if (value == null) {
1840 unsetRequest();
1841 } else {
1842 setRequest((TCreateSentryRoleRequest)value);
1843 }
1844 break;
1845
1846 }
1847 }
1848
1849 public Object getFieldValue(_Fields field) {
1850 switch (field) {
1851 case REQUEST:
1852 return getRequest();
1853
1854 }
1855 throw new IllegalStateException();
1856 }
1857
1858 /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
1859 public boolean isSet(_Fields field) {
1860 if (field == null) {
1861 throw new IllegalArgumentException();
1862 }
1863
1864 switch (field) {
1865 case REQUEST:
1866 return isSetRequest();
1867 }
1868 throw new IllegalStateException();
1869 }
1870
1871 @Override
1872 public boolean equals(Object that) {
1873 if (that == null)
1874 return false;
1875 if (that instanceof create_sentry_role_args)
1876 return this.equals((create_sentry_role_args)that);
1877 return false;
1878 }
1879
1880 public boolean equals(create_sentry_role_args that) {
1881 if (that == null)
1882 return false;
1883
1884 boolean this_present_request = true && this.isSetRequest();
1885 boolean that_present_request = true && that.isSetRequest();
1886 if (this_present_request || that_present_request) {
1887 if (!(this_present_request && that_present_request))
1888 return false;
1889 if (!this.request.equals(that.request))
1890 return false;
1891 }
1892
1893 return true;
1894 }
1895
1896 @Override
1897 public int hashCode() {
1898 List<Object> list = new ArrayList<Object>();
1899
1900 boolean present_request = true && (isSetRequest());
1901 list.add(present_request);
1902 if (present_request)
1903 list.add(request);
1904
1905 return list.hashCode();
1906 }
1907
1908 @Override
1909 public int compareTo(create_sentry_role_args other) {
1910 if (!getClass().equals(other.getClass())) {
1911 return getClass().getName().compareTo(other.getClass().getName());
1912 }
1913
1914 int lastComparison = 0;
1915
1916 lastComparison = Boolean.valueOf(isSetRequest()).compareTo(other.isSetRequest());
1917 if (lastComparison != 0) {
1918 return lastComparison;
1919 }
1920 if (isSetRequest()) {
1921 lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.request, other.request);
1922 if (lastComparison != 0) {
1923 return lastComparison;
1924 }
1925 }
1926 return 0;
1927 }
1928
1929 public _Fields fieldForId(int fieldId) {
1930 return _Fields.findByThriftId(fieldId);
1931 }
1932
1933 public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
1934 schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
1935 }
1936
1937 public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
1938 schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
1939 }
1940
1941 @Override
1942 public String toString() {
1943 StringBuilder sb = new StringBuilder("create_sentry_role_args(");
1944 boolean first = true;
1945
1946 sb.append("request:");
1947 if (this.request == null) {
1948 sb.append("null");
1949 } else {
1950 sb.append(this.request);
1951 }
1952 first = false;
1953 sb.append(")");
1954 return sb.toString();
1955 }
1956
1957 public void validate() throws org.apache.thrift.TException {
1958 // check for required fields
1959 // check for sub-struct validity
1960 if (request != null) {
1961 request.validate();
1962 }
1963 }
1964
1965 private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
1966 try {
1967 write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
1968 } catch (org.apache.thrift.TException te) {
1969 throw new java.io.IOException(te);
1970 }
1971 }
1972
1973 private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
1974 try {
1975 read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
1976 } catch (org.apache.thrift.TException te) {
1977 throw new java.io.IOException(te);
1978 }
1979 }
1980
1981 private static class create_sentry_role_argsStandardSchemeFactory implements SchemeFactory {
1982 public create_sentry_role_argsStandardScheme getScheme() {
1983 return new create_sentry_role_argsStandardScheme();
1984 }
1985 }
1986
1987 private static class create_sentry_role_argsStandardScheme extends StandardScheme<create_sentry_role_args> {
1988
1989 public void read(org.apache.thrift.protocol.TProtocol iprot, create_sentry_role_args struct) throws org.apache.thrift.TException {
1990 org.apache.thrift.protocol.TField schemeField;
1991 iprot.readStructBegin();
1992 while (true)
1993 {
1994 schemeField = iprot.readFieldBegin();
1995 if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
1996 break;
1997 }
1998 switch (schemeField.id) {
1999 case 1: // REQUEST
2000 if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
2001 struct.request = new TCreateSentryRoleRequest();
2002 struct.request.read(iprot);
2003 struct.setRequestIsSet(true);
2004 } else {
2005 org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
2006 }
2007 break;
2008 default:
2009 org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
2010 }
2011 iprot.readFieldEnd();
2012 }
2013 iprot.readStructEnd();
2014 struct.validate();
2015 }
2016
2017 public void write(org.apache.thrift.protocol.TProtocol oprot, create_sentry_role_args struct) throws org.apache.thrift.TException {
2018 struct.validate();
2019
2020 oprot.writeStructBegin(STRUCT_DESC);
2021 if (struct.request != null) {
2022 oprot.writeFieldBegin(REQUEST_FIELD_DESC);
2023 struct.request.write(oprot);
2024 oprot.writeFieldEnd();
2025 }
2026 oprot.writeFieldStop();
2027 oprot.writeStructEnd();
2028 }
2029
2030 }
2031
2032 private static class create_sentry_role_argsTupleSchemeFactory implements SchemeFactory {
2033 public create_sentry_role_argsTupleScheme getScheme() {
2034 return new create_sentry_role_argsTupleScheme();
2035 }
2036 }
2037
2038 private static class create_sentry_role_argsTupleScheme extends TupleScheme<create_sentry_role_args> {
2039
2040 @Override
2041 public void write(org.apache.thrift.protocol.TProtocol prot, create_sentry_role_args struct) throws org.apache.thrift.TException {
2042 TTupleProtocol oprot = (TTupleProtocol) prot;
2043 BitSet optionals = new BitSet();
2044 if (struct.isSetRequest()) {
2045 optionals.set(0);
2046 }
2047 oprot.writeBitSet(optionals, 1);
2048 if (struct.isSetRequest()) {
2049 struct.request.write(oprot);
2050 }
2051 }
2052
2053 @Override
2054 public void read(org.apache.thrift.protocol.TProtocol prot, create_sentry_role_args struct) throws org.apache.thrift.TException {
2055 TTupleProtocol iprot = (TTupleProtocol) prot;
2056 BitSet incoming = iprot.readBitSet(1);
2057 if (incoming.get(0)) {
2058 struct.request = new TCreateSentryRoleRequest();
2059 struct.request.read(iprot);
2060 struct.setRequestIsSet(true);
2061 }
2062 }
2063 }
2064
2065 }
2066
2067 public static class create_sentry_role_result implements org.apache.thrift.TBase<create_sentry_role_result, create_sentry_role_result._Fields>, java.io.Serializable, Cloneable, Comparable<create_sentry_role_result> {
2068 private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("create_sentry_role_result");
2069
2070 private static final org.apache.thrift.protocol.TField SUCCESS_FIELD_DESC = new org.apache.thrift.protocol.TField("success", org.apache.thrift.protocol.TType.STRUCT, (short)0);
2071
2072 private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();
2073 static {
2074 schemes.put(StandardScheme.class, new create_sentry_role_resultStandardSchemeFactory());
2075 schemes.put(TupleScheme.class, new create_sentry_role_resultTupleSchemeFactory());
2076 }
2077
2078 private TCreateSentryRoleResponse success; // required
2079
2080 /** The set of fields this struct contains, along with convenience methods for finding and manipulating them. */
2081 public enum _Fields implements org.apache.thrift.TFieldIdEnum {
2082 SUCCESS((short)0, "success");
2083
2084 private static final Map<String, _Fields> byName = new HashMap<String, _Fields>();
2085
2086 static {
2087 for (_Fields field : EnumSet.allOf(_Fields.class)) {
2088 byName.put(field.getFieldName(), field);
2089 }
2090 }
2091
2092 /**
2093 * Find the _Fields constant that matches fieldId, or null if its not found.
2094 */
2095 public static _Fields findByThriftId(int fieldId) {
2096 switch(fieldId) {
2097 case 0: // SUCCESS
2098 return SUCCESS;
2099 default:
2100 return null;
2101 }
2102 }
2103
2104 /**
2105 * Find the _Fields constant that matches fieldId, throwing an exception
2106 * if it is not found.
2107 */
2108 public static _Fields findByThriftIdOrThrow(int fieldId) {
2109 _Fields fields = findByThriftId(fieldId);
2110 if (fields == null) throw new IllegalArgumentException("Field " + fieldId + " doesn't exist!");
2111 return fields;
2112 }
2113
2114 /**
2115 * Find the _Fields constant that matches name, or null if its not found.
2116 */
2117 public static _Fields findByName(String name) {
2118 return byName.get(name);
2119 }
2120
2121 private final short _thriftId;
2122 private final String _fieldName;
2123
2124 _Fields(short thriftId, String fieldName) {
2125 _thriftId = thriftId;
2126 _fieldName = fieldName;
2127 }
2128
2129 public short getThriftFieldId() {
2130 return _thriftId;
2131 }
2132
2133 public String getFieldName() {
2134 return _fieldName;
2135 }
2136 }
2137
2138 // isset id assignments
2139 public static final Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> metaDataMap;
2140 static {
2141 Map<_Fields, org.apache.thrift.meta_data.FieldMetaData> tmpMap = new EnumMap<_Fields, org.apache.thrift.meta_data.FieldMetaData>(_Fields.class);
2142 tmpMap.put(_Fields.SUCCESS, new org.apache.thrift.meta_data.FieldMetaData("success", org.apache.thrift.TFieldRequirementType.DEFAULT,
2143 new org.apache.thrift.meta_data.StructMetaData(org.apache.thrift.protocol.TType.STRUCT, TCreateSentryRoleResponse.class)));
2144 metaDataMap = Collections.unmodifiableMap(tmpMap);
2145 org.apache.thrift.meta_data.FieldMetaData.addStructMetaDataMap(create_sentry_role_result.class, metaDataMap);
2146 }
2147
2148 public create_sentry_role_result() {
2149 }
2150
2151 public create_sentry_role_result(
2152 TCreateSentryRoleResponse success)
2153 {
2154 this();
2155 this.success = success;
2156 }
2157
2158 /**
2159 * Performs a deep copy on <i>other</i>.
2160 */
2161 public create_sentry_role_result(create_sentry_role_result other) {
2162 if (other.isSetSuccess()) {
2163 this.success = new TCreateSentryRoleResponse(other.success);
2164 }
2165 }
2166
2167 public create_sentry_role_result deepCopy() {
2168 return new create_sentry_role_result(this);
2169 }
2170
2171 @Override
2172 public void clear() {
2173 this.success = null;
2174 }
2175
2176 public TCreateSentryRoleResponse getSuccess() {
2177 return this.success;
2178 }
2179
2180 public void setSuccess(TCreateSentryRoleResponse success) {
2181 this.success = success;
2182 }
2183
2184 public void unsetSuccess() {
2185 this.success = null;
2186 }
2187
2188 /** Returns true if field success is set (has been assigned a value) and false otherwise */
2189 public boolean isSetSuccess() {
2190 return this.success != null;
2191 }
2192
2193 public void setSuccessIsSet(boolean value) {
2194 if (!value) {
2195 this.success = null;
2196 }
2197 }
2198
2199 public void setFieldValue(_Fields field, Object value) {
2200 switch (field) {
2201 case SUCCESS:
2202 if (value == null) {
2203 unsetSuccess();
2204 } else {
2205 setSuccess((TCreateSentryRoleResponse)value);
2206 }
2207 break;
2208
2209 }
2210 }
2211
2212 public Object getFieldValue(_Fields field) {
2213 switch (field) {
2214 case SUCCESS:
2215 return getSuccess();
2216
2217 }
2218 throw new IllegalStateException();
2219 }
2220
2221 /** Returns true if field corresponding to fieldID is set (has been assigned a value) and false otherwise */
2222 public boolean isSet(_Fields field) {
2223 if (field == null) {
2224 throw new IllegalArgumentException();
2225 }
2226
2227 switch (field) {
2228 case SUCCESS:
2229 return isSetSuccess();
2230 }
2231 throw new IllegalStateException();
2232 }
2233
2234 @Override
2235 public boolean equals(Object that) {
2236 if (that == null)
2237 return false;
2238 if (that instanceof create_sentry_role_result)
2239 return this.equals((create_sentry_role_result)that);
2240 return false;
2241 }
2242
2243 public boolean equals(create_sentry_role_result that) {
2244 if (that == null)
2245 return false;
2246
2247 boolean this_present_success = true && this.isSetSuccess();
2248 boolean that_present_success = true && that.isSetSuccess();
2249 if (this_present_success || that_present_success) {
2250 if (!(this_present_success && that_present_success))
2251 return false;
2252 if (!this.success.equals(that.success))
2253 return false;
2254 }
2255
2256 return true;
2257 }
2258
2259 @Override
2260 public int hashCode() {
2261 List<Object> list = new ArrayList<Object>();
2262
2263 boolean present_success = true && (isSetSuccess());
2264 list.add(present_success);
2265 if (present_success)
2266 list.add(success);
2267
2268 return list.hashCode();
2269 }
2270
2271 @Override
2272 public int compareTo(create_sentry_role_result other) {
2273 if (!getClass().equals(other.getClass())) {
2274 return getClass().getName().compareTo(other.getClass().getName());
2275 }
2276
2277 int lastComparison = 0;
2278
2279 lastComparison = Boolean.valueOf(isSetSuccess()).compareTo(other.isSetSuccess());
2280 if (lastComparison != 0) {
2281 return lastComparison;
2282 }
2283 if (isSetSuccess()) {
2284 lastComparison = org.apache.thrift.TBaseHelper.compareTo(this.success, other.success);
2285 if (lastComparison != 0) {
2286 return lastComparison;
2287 }
2288 }
2289 return 0;
2290 }
2291
2292 public _Fields fieldForId(int fieldId) {
2293 return _Fields.findByThriftId(fieldId);
2294 }
2295
2296 public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException {
2297 schemes.get(iprot.getScheme()).getScheme().read(iprot, this);
2298 }
2299
2300 public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException {
2301 schemes.get(oprot.getScheme()).getScheme().write(oprot, this);
2302 }
2303
2304 @Override
2305 public String toString() {
2306 StringBuilder sb = new StringBuilder("create_sentry_role_result(");
2307 boolean first = true;
2308
2309 sb.append("success:");
2310 if (this.success == null) {
2311 sb.append("null");
2312 } else {
2313 sb.append(this.success);
2314 }
2315 first = false;
2316 sb.append(")");
2317 return sb.toString();
2318 }
2319
2320 public void validate() throws org.apache.thrift.TException {
2321 // check for required fields
2322 // check for sub-struct validity
2323 if (success != null) {
2324 success.validate();
2325 }
2326 }
2327
2328 private void writeObject(java.io.ObjectOutputStream out) throws java.io.IOException {
2329 try {
2330 write(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(out)));
2331 } catch (org.apache.thrift.TException te) {
2332 throw new java.io.IOException(te);
2333 }
2334 }
2335
2336 private void readObject(java.io.ObjectInputStream in) throws java.io.IOException, ClassNotFoundException {
2337 try {
2338 read(new org.apache.thrift.protocol.TCompactProtocol(new org.apache.thrift.transport.TIOStreamTransport(in)));
2339 } catch (org.apache.thrift.TException te) {
2340 throw new java.io.IOException(te);
2341 }
2342 }
2343
2344 private static class create_sentry_role_resultStandardSchemeFactory implements SchemeFactory {
2345 public create_sentry_role_resultStandardScheme getScheme() {
2346 return new create_sentry_role_resultStandardScheme();
2347 }
2348 }
2349
2350 private static class create_sentry_role_resultStandardScheme extends StandardScheme<create_sentry_role_result> {
2351
2352 public void read(org.apache.thrift.protocol.TProtocol iprot, create_sentry_role_result struct) throws org.apache.thrift.TException {
2353 org.apache.thrift.protocol.TField schemeField;
2354 iprot.readStructBegin();
2355 while (true)
2356 {
2357 schemeField = iprot.readFieldBegin();
2358 if (schemeField.type == org.apache.thrift.protocol.TType.STOP) {
2359 break;
2360 }
2361 switch (schemeField.id) {
2362 case 0: // SUCCESS
2363 if (schemeField.type == org.apache.thrift.protocol.TType.STRUCT) {
2364 struct.success = new TCreateSentryRoleResponse();
2365 struct.success.read(iprot);
2366 struct.setSuccessIsSet(true);
2367 } else {
2368 org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
2369 }
2370 break;
2371 default:
2372 org.apache.thrift.protocol.TProtocolUtil.skip(iprot, schemeField.type);
2373 }
2374 iprot.readFieldEnd();
2375 }
2376 iprot.readStructEnd();
2377 struct.validate();
2378 }
2379
2380 public void write(org.apache.thrift.protocol.TProtocol oprot, create_sentry_role_result struct) throws org.apache.thrift.TException {
2381 struct.validate();
2382
2383 oprot.writeStructBegin(STRUCT_DESC);
2384 if (struct.success != null) {
2385 oprot.writeFieldBegin(SUCCESS_FIELD_DESC);
2386 struct.success.write(oprot);
2387 oprot.writeFieldEnd();
2388 }
2389 oprot.writeFieldStop();
2390 oprot.writeStructEnd();
2391 }
2392
2393 }
2394
2395 private static class create_sentry_role_resultTupleSchemeFactory implements SchemeFactory {
2396 public create_sentry_role_resultTupleScheme getScheme() {
2397 return new create_sentry_role_resultTupleScheme();
2398 }
2399 }
2400
2401 private static class create_sentry_role_resultTupleScheme extends TupleScheme<create_sentry_role_result> {
2402
2403 @Override
2404 public void write(org.apache.thrift.protocol.TProtocol prot, create_sentry_role_result struct) throws org.apache.thrift.TException {
2405 TTupleProtocol oprot = (TTupleProtocol) prot;
2406 BitSet optionals = new BitSet();
2407 if (struct.isSetSuccess()) {
2408 optionals.set(0);
2409 }
2410 oprot.writeBitSet(optionals, 1);
2411 if (struct.isSetSuccess()) {
2412 struct.success.write(oprot);
2413 }
2414 }
2415
2416 @Override
2417 public void read(org.apache.thrift.protocol.TProtocol prot, create_sentry_role_result struct) throws org.apache.thrift.TException {
2418 TTupleProtocol iprot = (TTupleProtocol) prot;
2419 BitSet incoming = iprot.readBitSet(1);
2420 if (incoming.get(0)) {
2421 struct.success = new TCreateSentryRoleResponse();
2422 struct.success.read(iprot);
2423 struct.setSuccessIsSet(true);
2424 }
2425 }
2426 }
2427
2428 }
2429
2430 public static class drop_sentry_role_args implements org.apache.thrift.TBase<drop_sentry_role_args, drop_sentry_role_args._Fields>, java.io.Serializable, Cloneable, Comparable<drop_sentry_role_args> {
2431 private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("drop_sentry_role_args");
2432
2433 private static final org.apache.thrift.protocol.TField REQUEST_FIELD_DESC = new org.apache.thrift.protocol.TField("request", org.apache.thrift.protocol.TType.STRUCT, (short)1);
2434
2435 private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>();