tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

PFileSystemRequest.ipdl (1547B)


      1 /* -*- Mode: c++; c-basic-offset: 2; indent-tabs-mode: nil; tab-width: 40 -*- */
      2 /* vim: set ts=2 et sw=2 tw=80: */
      3 /* This Source Code Form is subject to the terms of the Mozilla Public
      4  * License, v. 2.0. If a copy of the MPL was not distributed with this file,
      5  * You can obtain one at http://mozilla.org/MPL/2.0/. */
      6 
      7 include protocol PBackground;
      8 
      9 include IPCBlob;
     10 
     11 include "mozilla/dom/FileSystemTaskBase.h";
     12 
     13 namespace mozilla {
     14 namespace dom {
     15 
     16 struct FileSystemFileResponse
     17 {
     18   IPCBlob blob;
     19 };
     20 
     21 struct FileSystemDirectoryResponse
     22 {
     23   nsString realPath;
     24 };
     25 
     26 struct FileSystemDirectoryListingResponseFile
     27 {
     28   IPCBlob blob;
     29 };
     30 
     31 struct FileSystemDirectoryListingResponseDirectory
     32 {
     33   // This is the full real path for the directory that we are sending via IPC.
     34   nsString directoryRealPath;
     35 };
     36 
     37 union FileSystemDirectoryListingResponseData
     38 {
     39   FileSystemDirectoryListingResponseFile;
     40   FileSystemDirectoryListingResponseDirectory;
     41 };
     42 
     43 struct FileSystemDirectoryListingResponse
     44 {
     45   FileSystemDirectoryListingResponseData[] data;
     46 };
     47 
     48 struct FileSystemFilesResponse
     49 {
     50   FileSystemFileResponse[] data;
     51 };
     52 
     53 struct FileSystemErrorResponse
     54 {
     55   nsresult error;
     56 };
     57 
     58 union FileSystemResponseValue
     59 {
     60   FileSystemDirectoryResponse;
     61   FileSystemDirectoryListingResponse;
     62   FileSystemFileResponse;
     63   FileSystemFilesResponse;
     64   FileSystemErrorResponse;
     65 };
     66 
     67 [ChildImpl="FileSystemTaskChildBase"]
     68 protocol PFileSystemRequest
     69 {
     70   manager PBackground;
     71 
     72 child:
     73   async __delete__(FileSystemResponseValue response);
     74 };
     75 
     76 } // namespace dom
     77 } // namespace mozilla