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 #ifndef mozilla_ipc_InputStreamUtils_h
6 #define mozilla_ipc_InputStreamUtils_h
8 #include "mozilla/ipc/InputStreamParams.h"
10 #include "nsIInputStream.h"
19 SerializeInputStream(nsIInputStream
* aInputStream
,
20 InputStreamParams
& aParams
,
21 nsTArray
<FileDescriptor
>& aFileDescriptors
);
24 SerializeInputStream(nsIInputStream
* aInputStream
,
25 OptionalInputStreamParams
& aParams
,
26 nsTArray
<FileDescriptor
>& aFileDescriptors
);
28 already_AddRefed
<nsIInputStream
>
29 DeserializeInputStream(const InputStreamParams
& aParams
,
30 const nsTArray
<FileDescriptor
>& aFileDescriptors
);
32 already_AddRefed
<nsIInputStream
>
33 DeserializeInputStream(const OptionalInputStreamParams
& aParams
,
34 const nsTArray
<FileDescriptor
>& aFileDescriptors
);
37 } // namespace mozilla
39 #endif // mozilla_ipc_InputStreamUtils_h