User Tools

Site Tools


odtools:od_restorefilefromobject

OD Restore File From Object is a command sequence plugin that lets you restore a file from an object that has been saved with OD Store file With Object. It takes a filename and chunk ID as parameters. It can either be called with command parameters (see below) or without, in which case the UI will pop up, asking for filename and chunk ID.

In python, invoking the command is at follows:

lwsdk.command('cmdseq “OD_RestoreFileFromObject” \“'+ <file on disk> + ', ” + ID + “\”')

this example, will restore a file as c:\test.txt from chunk id ^:

  1. filename = r“c:\test.txt”
  2. ID = “^”
  3. lwsdk.command('cmdseq “OD_RestoreFileFromObject” \“'+ filename + ', ” + ID + “\”')

The file can at any point in time be restored via OD_StoreFileWithObject. One use for the mechanism, is to store copyright trackers (like your name, date, etc) in your object.

The File currently has a size limit of 1 MB. You are allowed to store multiple files (1 per Chunk ID)

odtools/od_restorefilefromobject.txt · Last modified: 2019/01/21 22:06 by oliver