PTestCancel.ipdl (1174B)
1 /* This Source Code Form is subject to the terms of the Mozilla Public 2 * License, v. 2.0. If a copy of the MPL was not distributed with this 3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 4 5 namespace mozilla { 6 namespace _ipdltest { 7 8 [NestedUpTo=inside_sync, ChildProc=any, ChildImpl=virtual, ParentImpl=virtual] 9 sync protocol PTestCancel 10 { 11 // Immediate Cancel: child sync function cancels immediately, both ends check after cancellation. 12 child: 13 [Nested=inside_sync] sync ImmediateCancel(); 14 15 16 // Nested Cancel: child nested sync function cancels 17 child: 18 async StartNestedCancel(); 19 [Nested=inside_sync] sync NestedCancel(); 20 parent: 21 [Nested=inside_sync] sync CallNestedCancel(); 22 23 24 // Nested Cancel Parent: parent nested sync function cancels 25 child: 26 [Nested=inside_sync] sync StartNestedCancelParent(); 27 parent: 28 [Nested=inside_sync] sync NestedCancelParent(); 29 30 31 // Common functions to check that sync messages still work. 32 child: 33 [Nested=inside_sync] sync CheckChild() returns (uint32_t reply); 34 parent: 35 [Nested=inside_sync] sync CheckParent() returns (uint32_t reply); 36 }; 37 38 } // namespace _ipdltest 39 } // namespace mozilla