| // Copyright 2022 The Fuchsia Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| |
| library test.unknowninteractions; |
| |
| open protocol UnknownInteractionsProtocol { |
| // One-Way Methods |
| strict StrictOneWay(); |
| flexible FlexibleOneWay(); |
| |
| // Two-Way Methods |
| strict StrictTwoWay() -> (); |
| strict StrictTwoWayFields() -> (struct { |
| some_field int32; |
| }); |
| strict StrictTwoWayUnion() -> (union { |
| 1: some_field int32; |
| }); |
| strict StrictTwoWayTable() -> (table { |
| 1: some_field int32; |
| }); |
| |
| strict StrictTwoWayErr() -> () error int32; |
| strict StrictTwoWayFieldsErr() -> (struct { |
| some_field int32; |
| }) error int32; |
| strict StrictTwoWayUnionErr() -> (union { |
| 1: some_field int32; |
| }) error int32; |
| strict StrictTwoWayTableErr() -> (table { |
| 1: some_field int32; |
| }) error int32; |
| |
| flexible FlexibleTwoWay() -> (); |
| flexible FlexibleTwoWayFields() -> (struct { |
| some_field int32; |
| }); |
| flexible FlexibleTwoWayUnion() -> (union { |
| 1: some_field int32; |
| }); |
| flexible FlexibleTwoWayTable() -> (table { |
| 1: some_field int32; |
| }); |
| |
| flexible FlexibleTwoWayErr() -> () error int32; |
| flexible FlexibleTwoWayFieldsErr() -> (struct { |
| some_field int32; |
| }) error int32; |
| flexible FlexibleTwoWayUnionErr() -> (union { |
| 1: some_field int32; |
| }) error int32; |
| flexible FlexibleTwoWayTableErr() -> (table { |
| 1: some_field int32; |
| }) error int32; |
| |
| // Events |
| strict -> StrictEvent(); |
| strict -> StrictEventFields(struct { |
| some_field int32; |
| }); |
| strict -> StrictEventUnion(union { |
| 1: some_field int32; |
| }); |
| strict -> StrictEventTable(table { |
| 1: some_field int32; |
| }); |
| |
| flexible -> FlexibleEvent(); |
| flexible -> FlexibleEventFields(struct { |
| some_field int32; |
| }); |
| flexible -> FlexibleEventUnion(union { |
| 1: some_field int32; |
| }); |
| flexible -> FlexibleEventTable(table { |
| 1: some_field int32; |
| }); |
| }; |
| |
| ajar protocol UnknownInteractionsAjarProtocol { |
| // One-Way Methods |
| strict StrictOneWay(); |
| flexible FlexibleOneWay(); |
| |
| // Two-Way Methods |
| strict StrictTwoWay() -> (); |
| strict StrictTwoWayFields() -> (struct { |
| some_field int32; |
| }); |
| strict StrictTwoWayUnion() -> (union { |
| 1: some_field int32; |
| }); |
| strict StrictTwoWayTable() -> (table { |
| 1: some_field int32; |
| }); |
| |
| strict StrictTwoWayErr() -> () error int32; |
| strict StrictTwoWayFieldsErr() -> (struct { |
| some_field int32; |
| }) error int32; |
| strict StrictTwoWayUnionErr() -> (union { |
| 1: some_field int32; |
| }) error int32; |
| strict StrictTwoWayTableErr() -> (table { |
| 1: some_field int32; |
| }) error int32; |
| |
| // Events |
| strict -> StrictEvent(); |
| strict -> StrictEventFields(struct { |
| some_field int32; |
| }); |
| strict -> StrictEventUnion(union { |
| 1: some_field int32; |
| }); |
| strict -> StrictEventTable(table { |
| 1: some_field int32; |
| }); |
| |
| flexible -> FlexibleEvent(); |
| flexible -> FlexibleEventFields(struct { |
| some_field int32; |
| }); |
| flexible -> FlexibleEventUnion(union { |
| 1: some_field int32; |
| }); |
| flexible -> FlexibleEventTable(table { |
| 1: some_field int32; |
| }); |
| }; |
| |
| closed protocol UnknownInteractionsClosedProtocol { |
| // One-Way Methods |
| strict StrictOneWay(); |
| |
| // Two-Way Methods |
| strict StrictTwoWay() -> (); |
| strict StrictTwoWayFields() -> (struct { |
| some_field int32; |
| }); |
| strict StrictTwoWayUnion() -> (union { |
| 1: some_field int32; |
| }); |
| strict StrictTwoWayTable() -> (table { |
| 1: some_field int32; |
| }); |
| |
| strict StrictTwoWayErr() -> () error int32; |
| strict StrictTwoWayFieldsErr() -> (struct { |
| some_field int32; |
| }) error int32; |
| strict StrictTwoWayUnionErr() -> (union { |
| 1: some_field int32; |
| }) error int32; |
| strict StrictTwoWayTableErr() -> (table { |
| 1: some_field int32; |
| }) error int32; |
| |
| // Events |
| strict -> StrictEvent(); |
| strict -> StrictEventFields(struct { |
| some_field int32; |
| }); |
| strict -> StrictEventUnion(union { |
| 1: some_field int32; |
| }); |
| strict -> StrictEventTable(table { |
| 1: some_field int32; |
| }); |
| }; |
| |
| @transport("Driver") |
| open protocol UnknownInteractionsDriverProtocol { |
| // One-Way Methods |
| strict StrictOneWay(); |
| flexible FlexibleOneWay(); |
| |
| // Two-Way Methods |
| strict StrictTwoWay() -> (); |
| strict StrictTwoWayFields() -> (struct { |
| some_field int32; |
| }); |
| strict StrictTwoWayUnion() -> (union { |
| 1: some_field int32; |
| }); |
| strict StrictTwoWayTable() -> (table { |
| 1: some_field int32; |
| }); |
| |
| strict StrictTwoWayErr() -> () error int32; |
| strict StrictTwoWayFieldsErr() -> (struct { |
| some_field int32; |
| }) error int32; |
| strict StrictTwoWayUnionErr() -> (union { |
| 1: some_field int32; |
| }) error int32; |
| strict StrictTwoWayTableErr() -> (table { |
| 1: some_field int32; |
| }) error int32; |
| |
| flexible FlexibleTwoWay() -> (); |
| flexible FlexibleTwoWayFields() -> (struct { |
| some_field int32; |
| }); |
| flexible FlexibleTwoWayUnion() -> (union { |
| 1: some_field int32; |
| }); |
| flexible FlexibleTwoWayTable() -> (table { |
| 1: some_field int32; |
| }); |
| |
| flexible FlexibleTwoWayErr() -> () error int32; |
| flexible FlexibleTwoWayFieldsErr() -> (struct { |
| some_field int32; |
| }) error int32; |
| flexible FlexibleTwoWayUnionErr() -> (union { |
| 1: some_field int32; |
| }) error int32; |
| flexible FlexibleTwoWayTableErr() -> (table { |
| 1: some_field int32; |
| }) error int32; |
| }; |
| |
| @transport("Driver") |
| ajar protocol UnknownInteractionsAjarDriverProtocol { |
| // One-Way Methods |
| strict StrictOneWay(); |
| flexible FlexibleOneWay(); |
| |
| // Two-Way Methods |
| strict StrictTwoWay() -> (); |
| strict StrictTwoWayFields() -> (struct { |
| some_field int32; |
| }); |
| strict StrictTwoWayUnion() -> (union { |
| 1: some_field int32; |
| }); |
| strict StrictTwoWayTable() -> (table { |
| 1: some_field int32; |
| }); |
| |
| strict StrictTwoWayErr() -> () error int32; |
| strict StrictTwoWayFieldsErr() -> (struct { |
| some_field int32; |
| }) error int32; |
| strict StrictTwoWayUnionErr() -> (union { |
| 1: some_field int32; |
| }) error int32; |
| strict StrictTwoWayTableErr() -> (table { |
| 1: some_field int32; |
| }) error int32; |
| }; |
| |
| @transport("Driver") |
| closed protocol UnknownInteractionsClosedDriverProtocol { |
| // One-Way Methods |
| strict StrictOneWay(); |
| |
| // Two-Way Methods |
| strict StrictTwoWay() -> (); |
| strict StrictTwoWayFields() -> (struct { |
| some_field int32; |
| }); |
| strict StrictTwoWayUnion() -> (union { |
| 1: some_field int32; |
| }); |
| strict StrictTwoWayTable() -> (table { |
| 1: some_field int32; |
| }); |
| |
| strict StrictTwoWayErr() -> () error int32; |
| strict StrictTwoWayFieldsErr() -> (struct { |
| some_field int32; |
| }) error int32; |
| strict StrictTwoWayUnionErr() -> (union { |
| 1: some_field int32; |
| }) error int32; |
| strict StrictTwoWayTableErr() -> (table { |
| 1: some_field int32; |
| }) error int32; |
| }; |