PageRenderTime 49ms CodeModel.GetById 24ms RepoModel.GetById 0ms app.codeStats 0ms

/hardware_ril/mock-ril/src/generated/java/com/android/internal/telephony/ril_proto/RilCtrlCmds.java

https://code.google.com/
Java | 610 lines | 523 code | 71 blank | 16 comment | 45 complexity | ce8260f93a699c3eabad1c28961ead26 MD5 | raw file
Possible License(s): BSD-3-Clause, LGPL-2.0, LGPL-2.1, CC0-1.0
  1. // Generated by the protocol buffer compiler. DO NOT EDIT!
  2. package com.android.internal.telephony.ril_proto;
  3. public final class RilCtrlCmds {
  4. private RilCtrlCmds() {}
  5. // enum CtrlCmd
  6. public static final int CTRL_CMD_ECHO = 0;
  7. public static final int CTRL_CMD_GET_RADIO_STATE = 1;
  8. public static final int CTRL_CMD_SET_RADIO_STATE = 2;
  9. public static final int CTRL_CMD_SET_MT_CALL = 1001;
  10. public static final int CTRL_CMD_HANGUP_CONN_REMOTE = 1002;
  11. public static final int CTRL_CMD_SET_CALL_TRANSITION_FLAG = 1003;
  12. public static final int CTRL_CMD_SET_CALL_ALERT = 1004;
  13. public static final int CTRL_CMD_SET_CALL_ACTIVE = 1005;
  14. public static final int CTRL_CMD_ADD_DIALING_CALL = 1006;
  15. // enum CtrlStatus
  16. public static final int CTRL_STATUS_OK = 0;
  17. public static final int CTRL_STATUS_ERR = 1;
  18. public static final class CtrlReqRadioState extends
  19. com.google.protobuf.micro.MessageMicro {
  20. public CtrlReqRadioState() {}
  21. // required .ril_proto.RadioState state = 1;
  22. public static final int STATE_FIELD_NUMBER = 1;
  23. private boolean hasState;
  24. private int state_ = com.android.internal.telephony.ril_proto.RilCmds.RADIOSTATE_OFF;
  25. public boolean hasState() { return hasState; }
  26. public int getState() { return state_; }
  27. public CtrlReqRadioState setState(int value) {
  28. hasState = true;
  29. state_ = value;
  30. return this;
  31. }
  32. public CtrlReqRadioState clearState() {
  33. hasState = false;
  34. state_ = com.android.internal.telephony.ril_proto.RilCmds.RADIOSTATE_OFF;
  35. return this;
  36. }
  37. public final CtrlReqRadioState clear() {
  38. clearState();
  39. cachedSize = -1;
  40. return this;
  41. }
  42. public final boolean isInitialized() {
  43. if (!hasState) return false;
  44. return true;
  45. }
  46. public void writeTo(com.google.protobuf.micro.CodedOutputStreamMicro output)
  47. throws java.io.IOException {
  48. if (hasState()) {
  49. output.writeInt32(1, getState());
  50. }
  51. }
  52. private int cachedSize = -1;
  53. public int getCachedSize() {
  54. if (cachedSize < 0) {
  55. // getSerializedSize sets cachedSize
  56. getSerializedSize();
  57. }
  58. return cachedSize;
  59. }
  60. public int getSerializedSize() {
  61. int size = 0;
  62. if (hasState()) {
  63. size += com.google.protobuf.micro.CodedOutputStreamMicro
  64. .computeInt32Size(1, getState());
  65. }
  66. cachedSize = size;
  67. return size;
  68. }
  69. public CtrlReqRadioState mergeFrom(
  70. com.google.protobuf.micro.CodedInputStreamMicro input)
  71. throws java.io.IOException {
  72. while (true) {
  73. int tag = input.readTag();
  74. switch (tag) {
  75. case 0:
  76. return this;
  77. default: {
  78. if (!parseUnknownField(input, tag)) {
  79. return this;
  80. }
  81. break;
  82. }
  83. case 8: {
  84. setState(input.readInt32());
  85. break;
  86. }
  87. }
  88. }
  89. }
  90. public static CtrlReqRadioState parseFrom(byte[] data)
  91. throws com.google.protobuf.micro.InvalidProtocolBufferMicroException {
  92. return (CtrlReqRadioState) (new CtrlReqRadioState().mergeFrom(data));
  93. }
  94. public static CtrlReqRadioState parseFrom(
  95. com.google.protobuf.micro.CodedInputStreamMicro input)
  96. throws java.io.IOException {
  97. return (CtrlReqRadioState) (new CtrlReqRadioState().mergeFrom(input));
  98. }
  99. }
  100. public static final class CtrlRspRadioState extends
  101. com.google.protobuf.micro.MessageMicro {
  102. public CtrlRspRadioState() {}
  103. // required .ril_proto.RadioState state = 1;
  104. public static final int STATE_FIELD_NUMBER = 1;
  105. private boolean hasState;
  106. private int state_ = com.android.internal.telephony.ril_proto.RilCmds.RADIOSTATE_OFF;
  107. public boolean hasState() { return hasState; }
  108. public int getState() { return state_; }
  109. public CtrlRspRadioState setState(int value) {
  110. hasState = true;
  111. state_ = value;
  112. return this;
  113. }
  114. public CtrlRspRadioState clearState() {
  115. hasState = false;
  116. state_ = com.android.internal.telephony.ril_proto.RilCmds.RADIOSTATE_OFF;
  117. return this;
  118. }
  119. public final CtrlRspRadioState clear() {
  120. clearState();
  121. cachedSize = -1;
  122. return this;
  123. }
  124. public final boolean isInitialized() {
  125. if (!hasState) return false;
  126. return true;
  127. }
  128. public void writeTo(com.google.protobuf.micro.CodedOutputStreamMicro output)
  129. throws java.io.IOException {
  130. if (hasState()) {
  131. output.writeInt32(1, getState());
  132. }
  133. }
  134. private int cachedSize = -1;
  135. public int getCachedSize() {
  136. if (cachedSize < 0) {
  137. // getSerializedSize sets cachedSize
  138. getSerializedSize();
  139. }
  140. return cachedSize;
  141. }
  142. public int getSerializedSize() {
  143. int size = 0;
  144. if (hasState()) {
  145. size += com.google.protobuf.micro.CodedOutputStreamMicro
  146. .computeInt32Size(1, getState());
  147. }
  148. cachedSize = size;
  149. return size;
  150. }
  151. public CtrlRspRadioState mergeFrom(
  152. com.google.protobuf.micro.CodedInputStreamMicro input)
  153. throws java.io.IOException {
  154. while (true) {
  155. int tag = input.readTag();
  156. switch (tag) {
  157. case 0:
  158. return this;
  159. default: {
  160. if (!parseUnknownField(input, tag)) {
  161. return this;
  162. }
  163. break;
  164. }
  165. case 8: {
  166. setState(input.readInt32());
  167. break;
  168. }
  169. }
  170. }
  171. }
  172. public static CtrlRspRadioState parseFrom(byte[] data)
  173. throws com.google.protobuf.micro.InvalidProtocolBufferMicroException {
  174. return (CtrlRspRadioState) (new CtrlRspRadioState().mergeFrom(data));
  175. }
  176. public static CtrlRspRadioState parseFrom(
  177. com.google.protobuf.micro.CodedInputStreamMicro input)
  178. throws java.io.IOException {
  179. return (CtrlRspRadioState) (new CtrlRspRadioState().mergeFrom(input));
  180. }
  181. }
  182. public static final class CtrlReqSetMTCall extends
  183. com.google.protobuf.micro.MessageMicro {
  184. public CtrlReqSetMTCall() {}
  185. // required string phone_number = 1;
  186. public static final int PHONE_NUMBER_FIELD_NUMBER = 1;
  187. private boolean hasPhoneNumber;
  188. private java.lang.String phoneNumber_ = "";
  189. public java.lang.String getPhoneNumber() { return phoneNumber_; }
  190. public boolean hasPhoneNumber() { return hasPhoneNumber; }
  191. public CtrlReqSetMTCall setPhoneNumber(java.lang.String value) {
  192. hasPhoneNumber = true;
  193. phoneNumber_ = value;
  194. return this;
  195. }
  196. public CtrlReqSetMTCall clearPhoneNumber() {
  197. hasPhoneNumber = false;
  198. phoneNumber_ = "";
  199. return this;
  200. }
  201. public final CtrlReqSetMTCall clear() {
  202. clearPhoneNumber();
  203. cachedSize = -1;
  204. return this;
  205. }
  206. public final boolean isInitialized() {
  207. if (!hasPhoneNumber) return false;
  208. return true;
  209. }
  210. public void writeTo(com.google.protobuf.micro.CodedOutputStreamMicro output)
  211. throws java.io.IOException {
  212. if (hasPhoneNumber()) {
  213. output.writeString(1, getPhoneNumber());
  214. }
  215. }
  216. private int cachedSize = -1;
  217. public int getCachedSize() {
  218. if (cachedSize < 0) {
  219. // getSerializedSize sets cachedSize
  220. getSerializedSize();
  221. }
  222. return cachedSize;
  223. }
  224. public int getSerializedSize() {
  225. int size = 0;
  226. if (hasPhoneNumber()) {
  227. size += com.google.protobuf.micro.CodedOutputStreamMicro
  228. .computeStringSize(1, getPhoneNumber());
  229. }
  230. cachedSize = size;
  231. return size;
  232. }
  233. public CtrlReqSetMTCall mergeFrom(
  234. com.google.protobuf.micro.CodedInputStreamMicro input)
  235. throws java.io.IOException {
  236. while (true) {
  237. int tag = input.readTag();
  238. switch (tag) {
  239. case 0:
  240. return this;
  241. default: {
  242. if (!parseUnknownField(input, tag)) {
  243. return this;
  244. }
  245. break;
  246. }
  247. case 10: {
  248. setPhoneNumber(input.readString());
  249. break;
  250. }
  251. }
  252. }
  253. }
  254. public static CtrlReqSetMTCall parseFrom(byte[] data)
  255. throws com.google.protobuf.micro.InvalidProtocolBufferMicroException {
  256. return (CtrlReqSetMTCall) (new CtrlReqSetMTCall().mergeFrom(data));
  257. }
  258. public static CtrlReqSetMTCall parseFrom(
  259. com.google.protobuf.micro.CodedInputStreamMicro input)
  260. throws java.io.IOException {
  261. return (CtrlReqSetMTCall) (new CtrlReqSetMTCall().mergeFrom(input));
  262. }
  263. }
  264. public static final class CtrlHangupConnRemote extends
  265. com.google.protobuf.micro.MessageMicro {
  266. public CtrlHangupConnRemote() {}
  267. // required int32 connection_id = 1;
  268. public static final int CONNECTION_ID_FIELD_NUMBER = 1;
  269. private boolean hasConnectionId;
  270. private int connectionId_ = 0;
  271. public int getConnectionId() { return connectionId_; }
  272. public boolean hasConnectionId() { return hasConnectionId; }
  273. public CtrlHangupConnRemote setConnectionId(int value) {
  274. hasConnectionId = true;
  275. connectionId_ = value;
  276. return this;
  277. }
  278. public CtrlHangupConnRemote clearConnectionId() {
  279. hasConnectionId = false;
  280. connectionId_ = 0;
  281. return this;
  282. }
  283. // required int32 call_fail_cause = 2;
  284. public static final int CALL_FAIL_CAUSE_FIELD_NUMBER = 2;
  285. private boolean hasCallFailCause;
  286. private int callFailCause_ = 0;
  287. public int getCallFailCause() { return callFailCause_; }
  288. public boolean hasCallFailCause() { return hasCallFailCause; }
  289. public CtrlHangupConnRemote setCallFailCause(int value) {
  290. hasCallFailCause = true;
  291. callFailCause_ = value;
  292. return this;
  293. }
  294. public CtrlHangupConnRemote clearCallFailCause() {
  295. hasCallFailCause = false;
  296. callFailCause_ = 0;
  297. return this;
  298. }
  299. public final CtrlHangupConnRemote clear() {
  300. clearConnectionId();
  301. clearCallFailCause();
  302. cachedSize = -1;
  303. return this;
  304. }
  305. public final boolean isInitialized() {
  306. if (!hasConnectionId) return false;
  307. if (!hasCallFailCause) return false;
  308. return true;
  309. }
  310. public void writeTo(com.google.protobuf.micro.CodedOutputStreamMicro output)
  311. throws java.io.IOException {
  312. if (hasConnectionId()) {
  313. output.writeInt32(1, getConnectionId());
  314. }
  315. if (hasCallFailCause()) {
  316. output.writeInt32(2, getCallFailCause());
  317. }
  318. }
  319. private int cachedSize = -1;
  320. public int getCachedSize() {
  321. if (cachedSize < 0) {
  322. // getSerializedSize sets cachedSize
  323. getSerializedSize();
  324. }
  325. return cachedSize;
  326. }
  327. public int getSerializedSize() {
  328. int size = 0;
  329. if (hasConnectionId()) {
  330. size += com.google.protobuf.micro.CodedOutputStreamMicro
  331. .computeInt32Size(1, getConnectionId());
  332. }
  333. if (hasCallFailCause()) {
  334. size += com.google.protobuf.micro.CodedOutputStreamMicro
  335. .computeInt32Size(2, getCallFailCause());
  336. }
  337. cachedSize = size;
  338. return size;
  339. }
  340. public CtrlHangupConnRemote mergeFrom(
  341. com.google.protobuf.micro.CodedInputStreamMicro input)
  342. throws java.io.IOException {
  343. while (true) {
  344. int tag = input.readTag();
  345. switch (tag) {
  346. case 0:
  347. return this;
  348. default: {
  349. if (!parseUnknownField(input, tag)) {
  350. return this;
  351. }
  352. break;
  353. }
  354. case 8: {
  355. setConnectionId(input.readInt32());
  356. break;
  357. }
  358. case 16: {
  359. setCallFailCause(input.readInt32());
  360. break;
  361. }
  362. }
  363. }
  364. }
  365. public static CtrlHangupConnRemote parseFrom(byte[] data)
  366. throws com.google.protobuf.micro.InvalidProtocolBufferMicroException {
  367. return (CtrlHangupConnRemote) (new CtrlHangupConnRemote().mergeFrom(data));
  368. }
  369. public static CtrlHangupConnRemote parseFrom(
  370. com.google.protobuf.micro.CodedInputStreamMicro input)
  371. throws java.io.IOException {
  372. return (CtrlHangupConnRemote) (new CtrlHangupConnRemote().mergeFrom(input));
  373. }
  374. }
  375. public static final class CtrlSetCallTransitionFlag extends
  376. com.google.protobuf.micro.MessageMicro {
  377. public CtrlSetCallTransitionFlag() {}
  378. // required bool flag = 1;
  379. public static final int FLAG_FIELD_NUMBER = 1;
  380. private boolean hasFlag;
  381. private boolean flag_ = false;
  382. public boolean getFlag() { return flag_; }
  383. public boolean hasFlag() { return hasFlag; }
  384. public CtrlSetCallTransitionFlag setFlag(boolean value) {
  385. hasFlag = true;
  386. flag_ = value;
  387. return this;
  388. }
  389. public CtrlSetCallTransitionFlag clearFlag() {
  390. hasFlag = false;
  391. flag_ = false;
  392. return this;
  393. }
  394. public final CtrlSetCallTransitionFlag clear() {
  395. clearFlag();
  396. cachedSize = -1;
  397. return this;
  398. }
  399. public final boolean isInitialized() {
  400. if (!hasFlag) return false;
  401. return true;
  402. }
  403. public void writeTo(com.google.protobuf.micro.CodedOutputStreamMicro output)
  404. throws java.io.IOException {
  405. if (hasFlag()) {
  406. output.writeBool(1, getFlag());
  407. }
  408. }
  409. private int cachedSize = -1;
  410. public int getCachedSize() {
  411. if (cachedSize < 0) {
  412. // getSerializedSize sets cachedSize
  413. getSerializedSize();
  414. }
  415. return cachedSize;
  416. }
  417. public int getSerializedSize() {
  418. int size = 0;
  419. if (hasFlag()) {
  420. size += com.google.protobuf.micro.CodedOutputStreamMicro
  421. .computeBoolSize(1, getFlag());
  422. }
  423. cachedSize = size;
  424. return size;
  425. }
  426. public CtrlSetCallTransitionFlag mergeFrom(
  427. com.google.protobuf.micro.CodedInputStreamMicro input)
  428. throws java.io.IOException {
  429. while (true) {
  430. int tag = input.readTag();
  431. switch (tag) {
  432. case 0:
  433. return this;
  434. default: {
  435. if (!parseUnknownField(input, tag)) {
  436. return this;
  437. }
  438. break;
  439. }
  440. case 8: {
  441. setFlag(input.readBool());
  442. break;
  443. }
  444. }
  445. }
  446. }
  447. public static CtrlSetCallTransitionFlag parseFrom(byte[] data)
  448. throws com.google.protobuf.micro.InvalidProtocolBufferMicroException {
  449. return (CtrlSetCallTransitionFlag) (new CtrlSetCallTransitionFlag().mergeFrom(data));
  450. }
  451. public static CtrlSetCallTransitionFlag parseFrom(
  452. com.google.protobuf.micro.CodedInputStreamMicro input)
  453. throws java.io.IOException {
  454. return (CtrlSetCallTransitionFlag) (new CtrlSetCallTransitionFlag().mergeFrom(input));
  455. }
  456. }
  457. public static final class CtrlReqAddDialingCall extends
  458. com.google.protobuf.micro.MessageMicro {
  459. public CtrlReqAddDialingCall() {}
  460. // required string phone_number = 1;
  461. public static final int PHONE_NUMBER_FIELD_NUMBER = 1;
  462. private boolean hasPhoneNumber;
  463. private java.lang.String phoneNumber_ = "";
  464. public java.lang.String getPhoneNumber() { return phoneNumber_; }
  465. public boolean hasPhoneNumber() { return hasPhoneNumber; }
  466. public CtrlReqAddDialingCall setPhoneNumber(java.lang.String value) {
  467. hasPhoneNumber = true;
  468. phoneNumber_ = value;
  469. return this;
  470. }
  471. public CtrlReqAddDialingCall clearPhoneNumber() {
  472. hasPhoneNumber = false;
  473. phoneNumber_ = "";
  474. return this;
  475. }
  476. public final CtrlReqAddDialingCall clear() {
  477. clearPhoneNumber();
  478. cachedSize = -1;
  479. return this;
  480. }
  481. public final boolean isInitialized() {
  482. if (!hasPhoneNumber) return false;
  483. return true;
  484. }
  485. public void writeTo(com.google.protobuf.micro.CodedOutputStreamMicro output)
  486. throws java.io.IOException {
  487. if (hasPhoneNumber()) {
  488. output.writeString(1, getPhoneNumber());
  489. }
  490. }
  491. private int cachedSize = -1;
  492. public int getCachedSize() {
  493. if (cachedSize < 0) {
  494. // getSerializedSize sets cachedSize
  495. getSerializedSize();
  496. }
  497. return cachedSize;
  498. }
  499. public int getSerializedSize() {
  500. int size = 0;
  501. if (hasPhoneNumber()) {
  502. size += com.google.protobuf.micro.CodedOutputStreamMicro
  503. .computeStringSize(1, getPhoneNumber());
  504. }
  505. cachedSize = size;
  506. return size;
  507. }
  508. public CtrlReqAddDialingCall mergeFrom(
  509. com.google.protobuf.micro.CodedInputStreamMicro input)
  510. throws java.io.IOException {
  511. while (true) {
  512. int tag = input.readTag();
  513. switch (tag) {
  514. case 0:
  515. return this;
  516. default: {
  517. if (!parseUnknownField(input, tag)) {
  518. return this;
  519. }
  520. break;
  521. }
  522. case 10: {
  523. setPhoneNumber(input.readString());
  524. break;
  525. }
  526. }
  527. }
  528. }
  529. public static CtrlReqAddDialingCall parseFrom(byte[] data)
  530. throws com.google.protobuf.micro.InvalidProtocolBufferMicroException {
  531. return (CtrlReqAddDialingCall) (new CtrlReqAddDialingCall().mergeFrom(data));
  532. }
  533. public static CtrlReqAddDialingCall parseFrom(
  534. com.google.protobuf.micro.CodedInputStreamMicro input)
  535. throws java.io.IOException {
  536. return (CtrlReqAddDialingCall) (new CtrlReqAddDialingCall().mergeFrom(input));
  537. }
  538. }
  539. }