| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 module device; | 5 module device; |
| 6 | 6 |
| 7 enum NFCErrorType { | 7 enum NFCErrorType { |
| 8 SECURITY, | 8 SECURITY, |
| 9 NOT_SUPPORTED, | 9 NOT_SUPPORTED, |
| 10 DEVICE_DISABLED, | 10 DEVICE_DISABLED, |
| 11 NOT_FOUND, | 11 NOT_FOUND, |
| 12 INVALID_MESSAGE, | 12 INVALID_MESSAGE, |
| 13 OPERATION_CANCELLED, | 13 OPERATION_CANCELLED, |
| 14 TIMER_EXPIRED, | 14 TIMER_EXPIRED, |
| 15 CANNOT_CANCEL, | 15 CANNOT_CANCEL, |
| 16 IO_ERROR | 16 IO_ERROR |
| 17 }; | 17 }; |
| 18 | 18 |
| 19 enum NFCRecordType { | 19 enum NFCRecordType { |
| 20 EMPTY, | 20 EMPTY, |
| 21 TEXT, | 21 TEXT, |
| 22 URL, | 22 URL, |
| 23 JSON, | 23 JSON, |
| 24 OPAQUE | 24 OPAQUE_RECORD |
| 25 }; | 25 }; |
| 26 | 26 |
| 27 enum NFCPushTarget { | 27 enum NFCPushTarget { |
| 28 TAG, | 28 TAG, |
| 29 PEER, | 29 PEER, |
| 30 ANY | 30 ANY |
| 31 }; | 31 }; |
| 32 | 32 |
| 33 enum NFCWatchMode { | 33 enum NFCWatchMode { |
| 34 WEBNFC_ONLY, | 34 WEBNFC_ONLY, |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 74 Watch(NFCWatchOptions options) => (uint32 id, NFCError? error); | 74 Watch(NFCWatchOptions options) => (uint32 id, NFCError? error); |
| 75 CancelWatch (uint32 id) => (NFCError? error); | 75 CancelWatch (uint32 id) => (NFCError? error); |
| 76 CancelAllWatches () => (NFCError? error); | 76 CancelAllWatches () => (NFCError? error); |
| 77 SuspendNFCOperations(); | 77 SuspendNFCOperations(); |
| 78 ResumeNFCOperations(); | 78 ResumeNFCOperations(); |
| 79 }; | 79 }; |
| 80 | 80 |
| 81 interface NFCClient { | 81 interface NFCClient { |
| 82 OnWatch(uint32 id, NFCMessage message); | 82 OnWatch(uint32 id, NFCMessage message); |
| 83 }; | 83 }; |
| OLD | NEW |