Wrap a Publisher to record all the values to chain storage.

  • Parameters

    • baggage: Baggage
    • marshaller: ERef<{
          fromCapData: FromCapData<unknown>;
          serialize: ToCapData<unknown>;
          toCapData: ToCapData<unknown>;
          unserialize: FromCapData<unknown>;
      }>

    Returns ((...args: [publisher: Publisher<unknown>, storageNode: DataOnly<StorageNode> & RemotableBrand<DataOnly<StorageNode>, StorageNode>, valueShape: TypedPattern<any>]) => Guarded<{
        getStorageNode(): DataOnly<StorageNode> & RemotableBrand<DataOnly<StorageNode>, StorageNode>;
        getStoragePath(): Promise<string>;
        write(value: any): Promise<void>;
        writeFinal(value: any): Promise<void>;
    }>)

      • (...args): Guarded<{
            getStorageNode(): DataOnly<StorageNode> & RemotableBrand<DataOnly<StorageNode>, StorageNode>;
            getStoragePath(): Promise<string>;
            write(value: any): Promise<void>;
            writeFinal(value: any): Promise<void>;
        }>
      • Parameters

        • Rest...args: [publisher: Publisher<unknown>, storageNode: DataOnly<StorageNode> & RemotableBrand<DataOnly<StorageNode>, StorageNode>, valueShape: TypedPattern<any>]

        Returns Guarded<{
            getStorageNode(): DataOnly<StorageNode> & RemotableBrand<DataOnly<StorageNode>, StorageNode>;
            getStoragePath(): Promise<string>;
            write(value: any): Promise<void>;
            writeFinal(value: any): Promise<void>;
        }>