nsITransportProvider.idl 1.2 KB

123456789101112131415161718192021222324252627282930313233343536
  1. /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
  2. /* This Source Code Form is subject to the terms of the Mozilla Public
  3. * License, v. 2.0. If a copy of the MPL was not distributed with this
  4. * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  5. interface nsIHttpUpgradeListener;
  6. #include "nsISupports.idl"
  7. %{C++
  8. namespace mozilla {
  9. namespace net {
  10. class PTransportProviderChild;
  11. }
  12. }
  13. %}
  14. [ptr] native PTransportProviderChild(mozilla::net::PTransportProviderChild);
  15. /**
  16. * An interface which can be used to asynchronously request a nsITransport
  17. * together with the input and output streams that go together with it.
  18. */
  19. [scriptable, uuid(6fcec704-cfd2-46ef-a394-a64d5cb1475c)]
  20. interface nsITransportProvider : nsISupports
  21. {
  22. // This must not be called in a child process since transport
  23. // objects are not accessible there. Call getIPCChild instead.
  24. void setListener(in nsIHttpUpgradeListener listener);
  25. // This must be implemented by nsITransportProvider objects running
  26. // in the child process. It must return null when called in the parent
  27. // process.
  28. [noscript] PTransportProviderChild getIPCChild();
  29. };