michael@0: /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this file, michael@0: * You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: michael@0: include protocol PBlob; michael@0: include protocol PContent; michael@0: michael@0: namespace mozilla { michael@0: namespace dom { michael@0: namespace devicestorage { michael@0: michael@0: michael@0: struct ErrorResponse michael@0: { michael@0: nsString error; michael@0: }; michael@0: michael@0: struct SuccessResponse michael@0: { michael@0: }; michael@0: michael@0: struct FileDescriptorResponse michael@0: { michael@0: FileDescriptor fileDescriptor; michael@0: }; michael@0: michael@0: struct BlobResponse michael@0: { michael@0: PBlob blob; michael@0: }; michael@0: michael@0: struct DeviceStorageFileValue michael@0: { michael@0: nsString storageName; michael@0: nsString name; michael@0: }; michael@0: michael@0: struct EnumerationResponse michael@0: { michael@0: nsString type; michael@0: nsString rootdir; michael@0: DeviceStorageFileValue[] paths; michael@0: }; michael@0: michael@0: struct FreeSpaceStorageResponse michael@0: { michael@0: uint64_t freeBytes; michael@0: }; michael@0: michael@0: struct UsedSpaceStorageResponse michael@0: { michael@0: uint64_t usedBytes; michael@0: }; michael@0: michael@0: struct AvailableStorageResponse michael@0: { michael@0: nsString mountState; michael@0: }; michael@0: michael@0: struct StorageStatusResponse michael@0: { michael@0: nsString storageStatus; michael@0: }; michael@0: michael@0: struct FormatStorageResponse michael@0: { michael@0: nsString mountState; michael@0: }; michael@0: michael@0: struct MountStorageResponse michael@0: { michael@0: nsString storageStatus; michael@0: }; michael@0: michael@0: struct UnmountStorageResponse michael@0: { michael@0: nsString storageStatus; michael@0: }; michael@0: michael@0: union DeviceStorageResponseValue michael@0: { michael@0: ErrorResponse; michael@0: SuccessResponse; michael@0: FileDescriptorResponse; michael@0: BlobResponse; michael@0: EnumerationResponse; michael@0: FreeSpaceStorageResponse; michael@0: UsedSpaceStorageResponse; michael@0: AvailableStorageResponse; michael@0: StorageStatusResponse; michael@0: FormatStorageResponse; michael@0: MountStorageResponse; michael@0: UnmountStorageResponse; michael@0: }; michael@0: michael@0: sync protocol PDeviceStorageRequest { michael@0: manager PContent; michael@0: child: michael@0: __delete__(DeviceStorageResponseValue response); michael@0: }; michael@0: michael@0: } // namespace devicestorage michael@0: } // namespace dom michael@0: } // namespace mozilla