Bug 1660755 [wpt PR 25207] - [scroll-animations] Allow null source in ScrollTimeline...
[gecko.git] / ipc / glue / InputStreamParams.ipdlh
blob9789b58f5644f472983f18a49c5938df4a63aff7
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/. */
5 include ProtocolTypes;
7 include protocol PChildToParentStream;
8 include protocol PParentToChildStream;
9 include protocol PRemoteLazyInputStream;
11 using struct mozilla::void_t
12   from "ipc/IPCMessageUtils.h";
14 namespace mozilla {
15 namespace ipc {
17 struct HeaderEntry
19   nsCString name;
20   nsCString value;
23 struct StringInputStreamParams
25   nsCString data;
28 struct FileInputStreamParams
30   uint32_t fileDescriptorIndex;
31   int32_t behaviorFlags;
32   int32_t ioFlags;
35 struct MultiplexInputStreamParams
37   InputStreamParams[] streams;
38   uint32_t currentStream;
39   nsresult status;
40   bool startedReadingCurrent;
43 struct SlicedInputStreamParams
45   InputStreamParams stream;
46   uint64_t start;
47   uint64_t length;
48   uint64_t curPos;
49   bool closed;
52 struct RemoteLazyInputStreamRef
54   nsID id;
55   uint64_t start;
56   uint64_t length;
59 union RemoteLazyInputStreamParams
61   RemoteLazyInputStreamRef;
62   PRemoteLazyInputStream;
65 union IPCRemoteStreamType
67   PChildToParentStream;
68   PParentToChildStream;
71 struct IPCRemoteStreamParams
73   // If this is true, the stream will send data only when the first operation
74   // is done on the destination side. The benefit of this is that we do not
75   // send data if not needed. On the other hand, it could have a performance
76   // issue.
77   bool delayedStart;
79   IPCRemoteStreamType stream;
81   int64_t length;
84 union InputStreamParams
86   StringInputStreamParams;
87   FileInputStreamParams;
88   BufferedInputStreamParams;
89   MIMEInputStreamParams;
90   MultiplexInputStreamParams;
91   SlicedInputStreamParams;
92   RemoteLazyInputStreamParams;
93   InputStreamLengthWrapperParams;
94   IPCRemoteStreamParams;
95   EncryptedFileInputStreamParams;
98 struct EncryptedFileInputStreamParams
100   FileInputStreamParams fileInputStreamParams;
101   uint8_t[] key;
102   uint32_t blockSize;
105 struct BufferedInputStreamParams
107   InputStreamParams? optionalStream;
108   uint32_t bufferSize;
111 struct MIMEInputStreamParams
113   InputStreamParams? optionalStream;
114   HeaderEntry[] headers;
115   bool startedReading;
118 struct InputStreamLengthWrapperParams
120   InputStreamParams stream;
121   int64_t length;
122   bool consumed;
125 } // namespace ipc
126 } // namespace mozilla