home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: SysTools / SysTools.zip / backres.zip / PSNSAPI.INF (.txt) < prev    next >
OS/2 Help File  |  1999-04-08  |  249KB  |  10,539 lines

  1.  
  2. ΓòÉΓòÉΓòÉ 1. Notices ΓòÉΓòÉΓòÉ
  3.  
  4. References in this publication to IBM products, programs or services do not 
  5. imply that IBM intends to make these available in all countries in which IBM 
  6. operates. Any reference to an IBM product, program, or service is not intended 
  7. to state or imply that only IBM's product, program, or service may be used. Any 
  8. functionally equivalent product, program, or service that does not infringe any 
  9. of IBM's intellectual property rights may be used instead of the IBM product, 
  10. program, or service. Evaluation and verification of operation in conjunction 
  11. with other products, except those expressly designated by IBM, is the user's 
  12. responsibility. 
  13.  
  14. IBM may have patents or pending patent applications covering subject matter in 
  15. this document. The furnishing of this document does not give you any license to 
  16. these patents. 
  17.  
  18.  
  19. ΓòÉΓòÉΓòÉ 1.1. Copyright notices ΓòÉΓòÉΓòÉ
  20.  
  21. (C) Copyright International Business Machines Corporation 1995, 1997. All 
  22. rights reserved. 
  23.  
  24. Note to U.S. Government Users - Documentation related to restricted rights - 
  25. Use, duplication or disclosure is subject to restrictions set forth in GSA ADP 
  26. Schedule Contract with IBM Corp. 
  27.  
  28.  
  29. ΓòÉΓòÉΓòÉ 1.2. Trademarks ΓòÉΓòÉΓòÉ
  30.  
  31. For a list of IBM and non-IBM trademarks, refer to the online book Trademarks 
  32. in the Information folder. 
  33.  
  34.  
  35. ΓòÉΓòÉΓòÉ 2. Starting the API server ΓòÉΓòÉΓòÉ
  36.  
  37. To start the API server, you must run the program PSNSD.EXE or double-click on 
  38. its icon in the OS/2 Warp Server Backup/Restore folder.  The syntax of the 
  39. command is as follows: 
  40.  
  41.           ΓöîΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÉ
  42.                                 Γöé
  43. ΓöÇΓöÇPSNSDΓöÇΓö¼ΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓöÇΓö╝ΓöÇΓöÇΓöÇ
  44.           Γöé                      Γöé
  45.           Γö£ΓöÇ/Pipe:<pipename>ΓöÇΓöÇΓöÇΓöÇΓöÇΓöñ
  46.           Γöé                      Γöé
  47.           Γö£ΓöÇ/Port:<servicename>ΓöÇΓöÇΓöñ
  48.           Γöé                      Γöé
  49.           ΓööΓöÇ/Port:<portnumber>ΓöÇΓöÇΓöÇΓöÿ
  50.  
  51.      <pipename> is the name of a named pipe to listen on 
  52.  
  53.      <servicename> is the name of a service which will be looked up in the 
  54.       TCP/IP services file to decide which port to listen on 
  55.  
  56.      <portnumber> is the number of a port to listen on 
  57.  
  58.  The pipe name, service name or port number should be the same as that which 
  59.  will be passed to PsnsInit in the client which is going to connect to the 
  60.  server. 
  61.  
  62.  As many named pipes or TCP/IP ports can be opened as are specified on the 
  63.  command line.  If you specify /Pipe: without a pipe name, a default pipe name 
  64.  will be used.  If you specify /Port: without a port name or service number, 
  65.  the service psnsapi will be looked up in the TCP/IP services file to find out 
  66.  which port to use. 
  67.  
  68.  
  69. ΓòÉΓòÉΓòÉ 3. OS/2 Warp Server Backup/Restore functions ΓòÉΓòÉΓòÉ
  70.  
  71. This section lists the functions available in the OS/2 Warp Server 
  72. Backup/Restore C API. 
  73.  
  74.      Initialisation / termination functions 
  75.  
  76.         -  PsnsInit 
  77.         -  PsnsTerm 
  78.  
  79.      Backup method functions 
  80.  
  81.         -  PsnsCreateBackupMethod 
  82.         -  PsnsDeleteBackupMethod 
  83.         -  PsnsRenameBackupMethod 
  84.         -  PsnsCopyBackupMethod 
  85.         -  PsnsBackupMethodInfo 
  86.         -  PsnsListBackupMethods 
  87.         -  PsnsEstimateBackupMethod 
  88.         -  PsnsRunBackupMethod 
  89.  
  90.      Restore method functions 
  91.  
  92.         -  PsnsCreateRestoreMethod 
  93.         -  PsnsDeleteRestoreMethod 
  94.         -  PsnsRenameRestoreMethod 
  95.         -  PsnsCopyRestoreMethod 
  96.         -  PsnsRestoreMethodInfo 
  97.         -  PsnsListRestoreMethods 
  98.         -  PsnsEstimateRestoreMethod 
  99.         -  PsnsRunRestoreMethod 
  100.  
  101.      Backup set functions 
  102.  
  103.         -  PsnsCreateBackupSet 
  104.         -  PsnsDeleteBackupSet 
  105.         -  PsnsBackupSetInfo 
  106.         -  PsnsSetBackupSetConfig 
  107.         -  PsnsGetBackupSetConfig 
  108.         -  PsnsListBackupSets 
  109.         -  PsnsTransferBackupSet 
  110.         -  PsnsGetLogFile 
  111.         -  PsnsEmptyBackupSet 
  112.  
  113.      Storage device functions 
  114.  
  115.         -  PsnsCreateStorageDevice 
  116.         -  PsnsDeleteStorageDevice 
  117.         -  PsnsStorageDeviceInfo 
  118.         -  PsnsSetStorageDeviceConfig 
  119.         -  PsnsGetStorageDeviceConfig 
  120.         -  PsnsListStorageDevices 
  121.         -  PsnsRefreshStorageDevices 
  122.  
  123.      Volume functions 
  124.  
  125.         -  PsnsCreateVolume 
  126.         -  PsnsDeleteVolume 
  127.         -  PsnsVolumeInfo 
  128.         -  PsnsListVolumes 
  129.         -  PsnsListVolumeBackupSets 
  130.         -  PsnsActivateVolume 
  131.         -  PsnsAssociateVolume 
  132.  
  133.      Schedule event functions 
  134.  
  135.         -  PsnsCreateEvent 
  136.         -  PsnsDeleteEvent 
  137.         -  PsnsCopyEvent 
  138.         -  PsnsEventInfo 
  139.         -  PsnsListEvents 
  140.         -  PsnsGetNextEvent 
  141.         -  PsnsActivateEvent 
  142.  
  143.      File filter functions 
  144.  
  145.         -  PsnsCreateFileFilter 
  146.         -  PsnsDeleteFileFilter 
  147.         -  PsnsRenameFileFilter 
  148.         -  PsnsCopyFileFilter 
  149.         -  PsnsFileFilterInfo 
  150.         -  PsnsListFileFilters 
  151.         -  PsnsAddFileFilterRule 
  152.         -  PsnsDeleteFileFilterRule 
  153.         -  PsnsFileFilterRuleInfo 
  154.  
  155.      Rulebook functions 
  156.  
  157.         -  PsnsCreateRulebook 
  158.         -  PsnsDeleteRulebook 
  159.         -  PsnsRenameRulebook 
  160.         -  PsnsCopyRulebook 
  161.         -  PsnsRulebookInfo 
  162.         -  PsnsListRulebooks 
  163.         -  PsnsAddRulebookRule 
  164.         -  PsnsDeleteRulebookRule 
  165.         -  PsnsRulebookRuleInfo 
  166.  
  167.      Source drive functions 
  168.  
  169.         -  PsnsListSourceDrives 
  170.         -  PsnsSelectSourceDrive 
  171.         -  PsnsRefreshSourceDrives 
  172.         -  PsnsSourceDriveType 
  173.  
  174.      Settings and defaults 
  175.  
  176.         -  PsnsDefaults 
  177.         -  PsnsSettings 
  178.  
  179.      File functions 
  180.  
  181.         -  PsnsListFiles 
  182.         -  PsnsDropFiles 
  183.         -  PsnsAddFile 
  184.         -  PsnsBackupFiles 
  185.         -  PsnsRestoreFiles 
  186.         -  PsnsPurgeFiles 
  187.  
  188.      Utility functions 
  189.  
  190.         -  PsnsCloseList 
  191.         -  PsnsMessageCallback 
  192.         -  PsnsGetMessageText 
  193.  
  194.  
  195. ΓòÉΓòÉΓòÉ 3.1. PsnsActivateEvent ΓòÉΓòÉΓòÉ
  196.  
  197. Select an item 
  198.  
  199.      Syntax 
  200.      Parameters 
  201.      Returns 
  202.      Remarks 
  203.      Example 
  204.      Related functions 
  205.  
  206.  
  207. ΓòÉΓòÉΓòÉ <hidden> PsnsActivateEvent - Syntax ΓòÉΓòÉΓòÉ
  208.  
  209. /****************************************************/
  210. /* This function activates or deactivates an event  */
  211. /* in the scheduler.                                */
  212. /****************************************************/
  213.  
  214. int PsnsActivateEvent(PSNSHANDLE handle,
  215.                       USHORT eventID,
  216.                       BOOL activate);
  217.  
  218.  
  219. ΓòÉΓòÉΓòÉ <hidden> PsnsActivateEvent - Parameters ΓòÉΓòÉΓòÉ
  220.  
  221.  handle (PSNSHANDLE) 
  222.            Handle returned by PsnsInit. 
  223.  
  224.  eventID (USHORT) 
  225.            ID of the event to be activated or deactivated. 
  226.  
  227.  activate (BOOL) 
  228.  
  229.            TRUE           Activate the event. 
  230.            FALSE          Deactivate the event. 
  231.  
  232.  
  233. ΓòÉΓòÉΓòÉ <hidden> PsnsActivateEvent - Returns ΓòÉΓòÉΓòÉ
  234.  
  235.       PSNS_OK 
  236.       PSNS_HANDLE_IN_USE 
  237.       PSNS_COMMUNICATIONS_ERROR 
  238.       PSNS_INVALID_HANDLE 
  239.       PSNS_INVALID_EVENT 
  240.  
  241.  
  242. ΓòÉΓòÉΓòÉ <hidden> PsnsActivateEvent - Remarks ΓòÉΓòÉΓòÉ
  243.  
  244. Use this function to activate or deactivate an event in the OS/2 Warp Server 
  245. Backup/Restore scheduler. When an event is deactivated, nothing will happen 
  246. when the event's time is reached. This can be useful to temporarily stop a 
  247. scheduled backup happening, for example, during a vacation or during system 
  248. maintenance. 
  249.  
  250.  
  251. ΓòÉΓòÉΓòÉ <hidden> PsnsActivateEvent - Related functions ΓòÉΓòÉΓòÉ
  252.  
  253.      PsnsCreateEvent 
  254.  
  255.      PsnsDeleteEvent 
  256.  
  257.      PsnsCopyEvent 
  258.  
  259.      PsnsEventInfo 
  260.  
  261.      PsnsListEvents 
  262.  
  263.      PsnsGetNextEvent 
  264.  
  265.  
  266. ΓòÉΓòÉΓòÉ 3.2. PsnsActivateVolume ΓòÉΓòÉΓòÉ
  267.  
  268. Select an item 
  269.  
  270.      Syntax 
  271.      Parameters 
  272.      Returns 
  273.      Remarks 
  274.      Example 
  275.      Related functions 
  276.  
  277.  
  278. ΓòÉΓòÉΓòÉ <hidden> PsnsActivateVolume - Syntax ΓòÉΓòÉΓòÉ
  279.  
  280. /****************************************************/
  281. /* This function marks a volume as active or        */
  282. /* inactive.                                        */
  283. /****************************************************/
  284.  
  285. int PsnsActivateVolume(PSNSHANDLE handle,
  286.                        ULONG volumeID,
  287.                        BOOL activate);
  288.  
  289.  
  290. ΓòÉΓòÉΓòÉ <hidden> PsnsActivateVolume - Parameters ΓòÉΓòÉΓòÉ
  291.  
  292.  handle (PSNSHANDLE) 
  293.            Handle returned by PsnsInit. 
  294.  
  295.  volumeID (ULONG) 
  296.            Volume ID of the volume to be activated or deactivated. 
  297.  
  298.  activate (BOOL) 
  299.            Possible values: 
  300.  
  301.            TRUE           Activate the volume. 
  302.            FALSE          Deactivate the volume. 
  303.  
  304.  
  305. ΓòÉΓòÉΓòÉ <hidden> PsnsActivateVolume - Returns ΓòÉΓòÉΓòÉ
  306.  
  307.       PSNS_OK 
  308.       PSNS_HANDLE_IN_USE 
  309.       PSNS_COMMUNICATIONS_ERROR 
  310.       PSNS_INVALID_HANDLE 
  311.       PSNS_INVALID_VOLUME 
  312.       PSNS_FIXED_VOLUME 
  313.       PSNS_INDEX_DISKETTE 
  314.       PSNS_TRANSFERRED_OUT 
  315.       PSNS_IN_USE 
  316.  
  317.  
  318. ΓòÉΓòÉΓòÉ <hidden> PsnsActivateVolume - Remarks ΓòÉΓòÉΓòÉ
  319.  
  320. Use this function to mark a volume as available or unavailable.  When a volume 
  321. is marked as unavailable (deactivated), OS/2 Warp Server Backup/Restore will 
  322. not ask you for that volume when performing a backup.  If you try to restore 
  323. files from a backup set which contains deactivated volumes, you will see a 
  324. warning message and files on the deactivated volumes will not be restored. 
  325.  
  326.  
  327. ΓòÉΓòÉΓòÉ <hidden> PsnsActivateVolume - Related functions ΓòÉΓòÉΓòÉ
  328.  
  329.      PsnsCreateVolume 
  330.  
  331.      PsnsDeleteVolume 
  332.  
  333.      PsnsVolumeInfo 
  334.  
  335.      PsnsListVolumes 
  336.  
  337.      PsnsListVolumeBackupSets 
  338.  
  339.      PsnsAssociateVolume 
  340.  
  341.  
  342. ΓòÉΓòÉΓòÉ 3.3. PsnsAddFile ΓòÉΓòÉΓòÉ
  343.  
  344. Select an item 
  345.  
  346.      Syntax 
  347.      Parameters 
  348.      Returns 
  349.      Remarks 
  350.      Example 
  351.      Related functions 
  352.  
  353.  
  354. ΓòÉΓòÉΓòÉ <hidden> PsnsAddFile - Syntax ΓòÉΓòÉΓòÉ
  355.  
  356. /****************************************************/
  357. /* This function adds a file or group of files to   */
  358. /* the list of files to be backed up, restored or   */
  359. /* dropped manually.                                */
  360. /****************************************************/
  361.  
  362. int PsnsAddFile(PSNSHANDLE handle,
  363.                 const char *filename,
  364.                 short reserved);
  365.  
  366.  
  367. ΓòÉΓòÉΓòÉ <hidden> PsnsAddFile - Parameters ΓòÉΓòÉΓòÉ
  368.  
  369.  handle (PSNSHANDLE) 
  370.            Handle returned by PsnsInit. 
  371.  
  372.  filename (const char *) 
  373.            Name of the file to add to the list.  To add all files in a given 
  374.            directory to the list, append a backslash to the directory name. To 
  375.            add all files in a given directory, and all files in all 
  376.            subdirectories beneath that directory, use a filename such as 
  377.            C:\Project\*\. No other wildcards are allowed in the filename. 
  378.  
  379.  reserved (short) 
  380.            Reserved, must be 0. 
  381.  
  382.  
  383. ΓòÉΓòÉΓòÉ <hidden> PsnsAddFile - Returns ΓòÉΓòÉΓòÉ
  384.  
  385.       PSNS_OK 
  386.       PSNS_HANDLE_IN_USE 
  387.       PSNS_COMMUNICATIONS_ERROR 
  388.       PSNS_INVALID_HANDLE 
  389.       PSNS_INVALID_PATH 
  390.  
  391.  
  392. ΓòÉΓòÉΓòÉ <hidden> PsnsAddFile - Remarks ΓòÉΓòÉΓòÉ
  393.  
  394. Use this function to add a file or group of files to the list of files to be 
  395. backed up, restored, or dropped.  When you have added all the necessary files 
  396. to the list, they can be backed up using PsnsBackupFiles, restored using 
  397. PsnsRestoreFiles, or dropped using PsnsDropFiles. If you choose to cancel the 
  398. operation and not backup or restore the files, call PsnsPurgeFiles to empty the 
  399. list without taking any other action. 
  400.  
  401. If there is a list of files which you commonly back up, you should consider 
  402. using a backup method with a rulebook to back up the files instead of this 
  403. function. 
  404.  
  405.  
  406. ΓòÉΓòÉΓòÉ <hidden> PsnsAddFile - Related functions ΓòÉΓòÉΓòÉ
  407.  
  408.      PsnsBackupFiles 
  409.  
  410.      PsnsDropFiles 
  411.  
  412.      PsnsRestoreFiles 
  413.  
  414.      PsnsPurgeFiles 
  415.  
  416.  
  417. ΓòÉΓòÉΓòÉ 3.4. PsnsAddFileFilterRule ΓòÉΓòÉΓòÉ
  418.  
  419. Select an item 
  420.  
  421.      Syntax 
  422.      Parameters 
  423.      Returns 
  424.      Remarks 
  425.      Example 
  426.      Related functions 
  427.  
  428.  
  429. ΓòÉΓòÉΓòÉ <hidden> PsnsAddFileFilterRule - Syntax ΓòÉΓòÉΓòÉ
  430.  
  431. /****************************************************/
  432. /* This function adds a new rule to a file filter.  */
  433. /****************************************************/
  434.  
  435. int PsnsAddFileFilterRule(PSNSHANDLE handle,
  436.                           const char *fileFilter,
  437.                           PFILEFILTERRULE pFileFilterRule,
  438.                           int position);
  439.  
  440.  
  441. ΓòÉΓòÉΓòÉ <hidden> PsnsAddFileFilterRule - Parameters ΓòÉΓòÉΓòÉ
  442.  
  443.  handle (PSNSHANDLE) 
  444.            Handle returned by PsnsInit. 
  445.  
  446.  fileFilter (const char *) 
  447.            Name of the file filter to which the rule is to be added. 
  448.  
  449.  pFileFilterRule (PFILEFILTERRULE) 
  450.            Pointer to a FILEFILTERRULE structure which details the rule which 
  451.            is to be added to the file filter. 
  452.  
  453.  position (int) 
  454.            This specifies the position where the rule is to be added to the 
  455.            file filter; 1 means add at the beginning, 2 after the first rule 
  456.            and so on. 
  457.  
  458.  
  459. ΓòÉΓòÉΓòÉ <hidden> PsnsAddFileFilterRule - Returns ΓòÉΓòÉΓòÉ
  460.  
  461.       PSNS_OK 
  462.       PSNS_HANDLE_IN_USE 
  463.       PSNS_COMMUNICATIONS_ERROR 
  464.       PSNS_INVALID_HANDLE 
  465.       PSNS_INVALID_FILE_FILTER 
  466.       PSNS_INVALID_DRIVE 
  467.       PSNS_INVALID_PATH 
  468.       PSNS_INVALID_FILENAME 
  469.       PSNS_INVALID_POSITION 
  470.  
  471.  
  472. ΓòÉΓòÉΓòÉ <hidden> PsnsAddFileFilterRule - Remarks ΓòÉΓòÉΓòÉ
  473.  
  474. Use this function to add a new rule to a file filter.  The rules are applied in 
  475. order, from first to last, to decide which files will be backed up. You can add 
  476. the new rule in any position before the 'last' rule. 
  477.  
  478.  
  479. ΓòÉΓòÉΓòÉ <hidden> PsnsAddFileFilterRule - Related functions ΓòÉΓòÉΓòÉ
  480.  
  481.      PsnsDeleteFileFilterRule 
  482.  
  483.      PsnsFileFilterRuleInfo 
  484.  
  485.  
  486. ΓòÉΓòÉΓòÉ 3.5. PsnsAddRulebookRule ΓòÉΓòÉΓòÉ
  487.  
  488. Select an item 
  489.  
  490.      Syntax 
  491.      Parameters 
  492.      Returns 
  493.      Remarks 
  494.      Example 
  495.      Related functions 
  496.  
  497.  
  498. ΓòÉΓòÉΓòÉ <hidden> PsnsAddRulebookRule - Syntax ΓòÉΓòÉΓòÉ
  499.  
  500. /****************************************************/
  501. /* This function adds a new rule to a rulebook.     */
  502. /****************************************************/
  503.  
  504. int PsnsAddRulebookRule(PSNSHANDLE handle,
  505.                         const char *rulebook,
  506.                         PRULEBOOKRULE pRulebookRule,
  507.                         int position);
  508.  
  509.  
  510. ΓòÉΓòÉΓòÉ <hidden> PsnsAddRulebookRule - Parameters ΓòÉΓòÉΓòÉ
  511.  
  512.  handle (PSNSHANDLE) 
  513.            Handle returned by PsnsInit. 
  514.  
  515.  rulebook (const char *) 
  516.            Name of the rulebook to which the rule is to be added. 
  517.  
  518.  pRulebookRule (PRULEBOOKRULE) 
  519.            Pointer to a RULEBOOKRULE structure which details the rule which is 
  520.            to be added to the rulebook. 
  521.  
  522.  position (int) 
  523.            This specifies the position where the rule is to be added to the 
  524.            rulebook; 1 means at the beginning, 2 after the first rule and so 
  525.            on. 
  526.  
  527.  
  528. ΓòÉΓòÉΓòÉ <hidden> PsnsAddRulebookRule - Returns ΓòÉΓòÉΓòÉ
  529.  
  530.       PSNS_OK 
  531.       PSNS_HANDLE_IN_USE 
  532.       PSNS_COMMUNICATIONS_ERROR 
  533.       PSNS_INVALID_HANDLE 
  534.       PSNS_INVALID_RULEBOOK 
  535.       PSNS_INVALID_DRIVE 
  536.       PSNS_INVALID_PATH 
  537.       PSNS_INVALID_FILENAME 
  538.       PSNS_INVALID_POSITION 
  539.  
  540.  
  541. ΓòÉΓòÉΓòÉ <hidden> PsnsAddRulebookRule - Remarks ΓòÉΓòÉΓòÉ
  542.  
  543. Use this function to add a new rule to a rulebook.  The rules are applied in 
  544. order, from first to last, to decide whether compression will be used and how 
  545. many generations of individual files to keep. You can add the new rule in any 
  546. position before the 'last' rule. 
  547.  
  548.  
  549. ΓòÉΓòÉΓòÉ <hidden> PsnsAddRulebookRule - Related functions ΓòÉΓòÉΓòÉ
  550.  
  551.      PsnsDeleteRulebookRule 
  552.  
  553.      PsnsRulebookRuleInfo 
  554.  
  555.  
  556. ΓòÉΓòÉΓòÉ 3.6. PsnsAssociateVolume ΓòÉΓòÉΓòÉ
  557.  
  558. Select an item 
  559.  
  560.      Syntax 
  561.      Parameters 
  562.      Returns 
  563.      Remarks 
  564.      Example 
  565.      Related functions 
  566.  
  567.  
  568. ΓòÉΓòÉΓòÉ <hidden> PsnsAssociateVolume - Syntax ΓòÉΓòÉΓòÉ
  569.  
  570. /****************************************************/
  571. /* This function associates an existing volume with */
  572. /* a backup set.                                    */
  573. /****************************************************/
  574.  
  575. int PsnsAssociateVolume(PSNSHANDLE handle,
  576.                         ULONG volumeID,
  577.                         const char *backupSet);
  578.  
  579.  
  580. ΓòÉΓòÉΓòÉ <hidden> PsnsAssociateVolume - Parameters ΓòÉΓòÉΓòÉ
  581.  
  582.  handle (PSNSHANDLE) 
  583.            Handle returned by PsnsInit. 
  584.  
  585.  volumeID (ULONG) 
  586.            ID of the volume to be associated with a backup set. 
  587.  
  588.  backupSet (const char *) 
  589.            Name of the backup set with which to associate the volume. 
  590.  
  591.  
  592. ΓòÉΓòÉΓòÉ <hidden> PsnsAssociateVolume - Returns ΓòÉΓòÉΓòÉ
  593.  
  594.       PSNS_OK 
  595.       PSNS_HANDLE_IN_USE 
  596.       PSNS_COMMUNICATIONS_ERROR 
  597.       PSNS_INVALID_HANDLE 
  598.       PSNS_INVALID_VOLUME 
  599.       PSNS_INVALID_BACKUP_SET 
  600.       PSNS_ALREADY_ASSOCIATED 
  601.       PSNS_INAPPROPRIATE_BACKUP_SET 
  602.       PSNS_IN_USE 
  603.  
  604.  
  605. ΓòÉΓòÉΓòÉ <hidden> PsnsAssociateVolume - Remarks ΓòÉΓòÉΓòÉ
  606.  
  607. Use this function to associate a volume with a backup set.  This means that 
  608. when you perform a backup to the backup set, OS/2 Warp Server Backup/Restore 
  609. will consider the volume when it is looking for a volume with free space to 
  610. store backed-up data.  This can be useful, for example, when scheduling an 
  611. overnight backup to tape:  you can create a new volume in advance and associate 
  612. it with the backup set; then OS/2 Warp Server Backup/Restore can automatically 
  613. use the new volume when it comes to do the backup, rather than prompting for a 
  614. new volume. 
  615.  
  616.  
  617. ΓòÉΓòÉΓòÉ <hidden> PsnsAssociateVolume - Related functions ΓòÉΓòÉΓòÉ
  618.  
  619.      PsnsCreateVolume 
  620.  
  621.      PsnsDeleteVolume 
  622.  
  623.      PsnsVolumeInfo 
  624.  
  625.      PsnsListVolumes 
  626.  
  627.      PsnsListVolumeBackupSets 
  628.  
  629.      PsnsActivateVolume 
  630.  
  631.  
  632. ΓòÉΓòÉΓòÉ 3.7. PsnsBackupFiles ΓòÉΓòÉΓòÉ
  633.  
  634. Select an item 
  635.  
  636.      Syntax 
  637.      Parameters 
  638.      Returns 
  639.      Remarks 
  640.      Example 
  641.      Related functions 
  642.  
  643.  
  644. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupFiles - Syntax ΓòÉΓòÉΓòÉ
  645.  
  646. /****************************************************/
  647. /* This function backs up the list of files created */
  648. /* by calls to PsnsAddFile.                         */
  649. /****************************************************/
  650.  
  651. int PsnsBackupFiles(PSNSHANDLE handle,
  652.                     PBACKUPMETHODINFO pBackupMethodInfo,
  653.                     PSNSSTATSFN psnsStatsFn);
  654.  
  655.  
  656. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupFiles - Parameters ΓòÉΓòÉΓòÉ
  657.  
  658.  handle (PSNSHANDLE) 
  659.            Handle returned by PsnsInit. 
  660.  
  661.  pBackupMethodInfo (PBACKUPMETHODINFO) 
  662.            Pointer to a BACKUPMETHODINFO structure which contains settings 
  663.            which control how the backup method runs.  The only fields in the 
  664.            structure which need to be set are: 
  665.  
  666.                backupSet 
  667.                compression 
  668.                generations 
  669.                changedFilesOnly 
  670.  
  671.            All other fields in the structure are ignored by this function. 
  672.  
  673.  psnsStatsFn (PSNSSTATSFN) 
  674.            Pointer to a statistics callback function.  This can be NULL. 
  675.  
  676.  
  677. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupFiles - Returns ΓòÉΓòÉΓòÉ
  678.  
  679.       PSNS_OK 
  680.       PSNS_HANDLE_IN_USE 
  681.       PSNS_COMMUNICATIONS_ERROR 
  682.       PSNS_INVALID_HANDLE 
  683.       PSNS_INVALID_BACKUP_SET 
  684.       PSNS_INVALID_GENERATIONS 
  685.       PSNS_INVALID_COMPRESSION 
  686.       PSNS_TRANSFERRED_OUT 
  687.       PSNS_IN_USE 
  688.  
  689.  
  690. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupFiles - Remarks ΓòÉΓòÉΓòÉ
  691.  
  692. Use this function to back up a list of files. The callback function, if 
  693. provided, is called whenever the statistics (number of files, folder and bytes 
  694. backed up) have changed, or whenever there is a message which might interest 
  695. the user.  For more information on the statistics callback function, see 
  696. PSNSSTATSFN. 
  697.  
  698.  
  699. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupFiles - Related functions ΓòÉΓòÉΓòÉ
  700.  
  701.      PsnsAddFile 
  702.  
  703.      PsnsDropFiles 
  704.  
  705.      PsnsRestoreFiles 
  706.  
  707.      PsnsPurgeFiles 
  708.  
  709.  
  710. ΓòÉΓòÉΓòÉ 3.8. PsnsBackupMethodInfo ΓòÉΓòÉΓòÉ
  711.  
  712. Select an item 
  713.  
  714.      Syntax 
  715.      Parameters 
  716.      Returns 
  717.      Remarks 
  718.      Example 
  719.      Related functions 
  720.  
  721.  
  722. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupMethodInfo - Syntax ΓòÉΓòÉΓòÉ
  723.  
  724. /****************************************************/
  725. /* This function gets or sets all the information   */
  726. /* about a backup method.                           */
  727. /****************************************************/
  728.  
  729. int PsnsBackupMethodInfo(PSNSHANDLE handle,
  730.                          const char *name,
  731.                          PBACKUPMETHODINFO pBackupMethodInfo,
  732.                          long mask);
  733.  
  734.  
  735. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupMethodInfo - Parameters ΓòÉΓòÉΓòÉ
  736.  
  737.  handle (PSNSHANDLE) 
  738.            Handle returned by PsnsInit. 
  739.  
  740.  name (const char *) 
  741.            Name of the backup method to be inspected or changed. 
  742.  
  743.  pBackupMethodInfo (PBACKUPMETHODINFO) 
  744.            Pointer to a BACKUPMETHODINFO structure which contains the new 
  745.            settings if they are to be changed, and to receive the current 
  746.            settings.  If the corresponding bit in mask is set then the settings 
  747.            will be changed to what is passed in this structure.  The new 
  748.            settings are returned in this structure.  To get the settings 
  749.            without changing them, set mask = BM_NONE. 
  750.  
  751.  mask (long) 
  752.            Possible values: 
  753.  
  754.                 BM_NONE 
  755.                 BM_DESCRIPTION 
  756.                 BM_ALLFILES 
  757.                 BM_DRIVE 
  758.                 BM_DIRECTORY 
  759.                 BM_SUBDIRECTORIES 
  760.                 BM_COMPRESSION 
  761.                 BM_GENERATIONS 
  762.                 BM_USERULEBOOK 
  763.                 BM_RULEBOOK 
  764.                 BM_USEFILEFILTER 
  765.                 BM_FILEFILTER 
  766.                 BM_CHANGEDFILESONLY 
  767.                 BM_PREVIEW 
  768.                 BM_BACKUPSET 
  769.                 BM_ALL 
  770.  
  771.            To set more than one setting, OR the different values together.  To 
  772.            set all the settings, use mask = BM_ALL. 
  773.  
  774.  
  775. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupMethodInfo - Returns ΓòÉΓòÉΓòÉ
  776.  
  777.       PSNS_OK 
  778.       PSNS_HANDLE_IN_USE 
  779.       PSNS_COMMUNICATIONS_ERROR 
  780.       PSNS_INVALID_HANDLE 
  781.       PSNS_INVALID_BACKUP_SET 
  782.       PSNS_INVALID_DRIVE 
  783.       PSNS_INVALID_PATH 
  784.       PSNS_INVALID_MASK 
  785.       PSNS_INVALID_COMPRESSION 
  786.       PSNS_INVALID_GENERATIONS 
  787.       PSNS_INVALID_RULEBOOK 
  788.       PSNS_INVALID_FILE_FILTER 
  789.       PSNS_INVALID_BACKUP_SET 
  790.  
  791.  
  792. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupMethodInfo - Remarks ΓòÉΓòÉΓòÉ
  793.  
  794. Use this function to change a backup method or to inspect the current settings 
  795. for a backup method.  The mask parameter defines which settings are being 
  796. changed.  For more information on the individual fields, see BACKUPMETHODINFO. 
  797.  
  798. It is not possible to change the name of a backup method with this call; to do 
  799. that, use PsnsRenameBackupMethod. 
  800.  
  801.  
  802. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupMethodInfo - Related functions ΓòÉΓòÉΓòÉ
  803.  
  804.      PsnsCreateBackupMethod 
  805.  
  806.      PsnsDeleteBackupMethod 
  807.  
  808.      PsnsRenameBackupMethod 
  809.  
  810.      PsnsCopyBackupMethod 
  811.  
  812.      PsnsListBackupMethods 
  813.  
  814.      PsnsEstimateBackupMethod 
  815.  
  816.      PsnsRunBackupMethod 
  817.  
  818.  
  819. ΓòÉΓòÉΓòÉ 3.9. PsnsBackupSetInfo ΓòÉΓòÉΓòÉ
  820.  
  821. Select an item 
  822.  
  823.      Syntax 
  824.      Parameters 
  825.      Returns 
  826.      Remarks 
  827.      Example 
  828.      Related functions 
  829.  
  830.  
  831. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupSetInfo - Syntax ΓòÉΓòÉΓòÉ
  832.  
  833. /****************************************************/
  834. /* This function gets or sets all the information   */
  835. /* about a backup set.                              */
  836. /****************************************************/
  837.  
  838. int PsnsBackupSetInfo(PSNSHANDLE handle,
  839.                       const char *name,
  840.                       PBACKUPSETINFO pBackupSetInfo,
  841.                       long mask);
  842.  
  843.  
  844. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupSetInfo - Parameters ΓòÉΓòÉΓòÉ
  845.  
  846.  handle (PSNSHANDLE) 
  847.            Handle returned by PsnsInit. 
  848.  
  849.  name (const char *) 
  850.            Name of the backup set to be inspected or changed. 
  851.  
  852.  pBackupSetInfo (PBACKUPSETINFO) 
  853.            Pointer to a BACKUPSETINFO structure which contains the new settings 
  854.            if they are to be changed, and to receive the current settings.  If 
  855.            the corresponding bit in mask is set then the settings will be 
  856.            changed to what is passed in this structure.  The new settings are 
  857.            returned in this structure.  To get the settings without changing 
  858.            them, set mask = BS_NONE. 
  859.  
  860.  mask (long) 
  861.            Possible values: 
  862.  
  863.                 BS_NONE 
  864.                 BS_DESCRIPTION 
  865.                 BS_ALL 
  866.  
  867.  
  868. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupSetInfo - Returns ΓòÉΓòÉΓòÉ
  869.  
  870.       PSNS_OK 
  871.       PSNS_HANDLE_IN_USE 
  872.       PSNS_COMMUNICATIONS_ERROR 
  873.       PSNS_INVALID_HANDLE 
  874.       PSNS_INVALID_BACKUP_SET 
  875.       PSNS_INVALID_MASK 
  876.  
  877.  
  878. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupSetInfo - Remarks ΓòÉΓòÉΓòÉ
  879.  
  880. Use this function to change a backup set or to inspect the current settings for 
  881. a backup set.  The mask parameter defines which settings are being changed. 
  882. For more information on the individual fields, see BACKUPSETINFO. 
  883.  
  884. It is not possible to change which storage device a backup set uses; to do 
  885. that, you must delete the backup set and create a new one. 
  886.  
  887.  
  888. ΓòÉΓòÉΓòÉ <hidden> PsnsBackupSetInfo - Related functions ΓòÉΓòÉΓòÉ
  889.  
  890.      PsnsCreateBackupSet 
  891.  
  892.      PsnsDeleteBackupSet 
  893.  
  894.      PsnsSetBackupSetConfig 
  895.  
  896.      PsnsGetBackupSetConfig 
  897.  
  898.      PsnsListBackupSets 
  899.  
  900.      PsnsTransferBackupSet 
  901.  
  902.      PsnsTransferIn 
  903.  
  904.      PsnsGetLogFile 
  905.  
  906.      PsnsEmptyBackupSet 
  907.  
  908.  
  909. ΓòÉΓòÉΓòÉ 3.10. PsnsCloseList ΓòÉΓòÉΓòÉ
  910.  
  911. Select an item 
  912.  
  913.      Syntax 
  914.      Parameters 
  915.      Returns 
  916.      Remarks 
  917.      Example 
  918.      Related functions 
  919.  
  920.  
  921. ΓòÉΓòÉΓòÉ <hidden> PsnsCloseList - Syntax ΓòÉΓòÉΓòÉ
  922.  
  923. /****************************************************/
  924. /* This function is used to terminate a listing     */
  925. /* operation before it has finished.                */
  926. /****************************************************/
  927.  
  928. int PsnsCloseList(PSNSHANDLE handle,
  929.                   PHPSNSLIST pHPsnsList);
  930.  
  931.  
  932. ΓòÉΓòÉΓòÉ <hidden> PsnsCloseList - Parameters ΓòÉΓòÉΓòÉ
  933.  
  934.  handle (PSNSHANDLE) 
  935.            Handle returned by PsnsInit. 
  936.  
  937.  pHPsnsList (PHPSNSLIST) 
  938.            Pointer to a list handle. 
  939.  
  940.  
  941. ΓòÉΓòÉΓòÉ <hidden> PsnsCloseList - Returns ΓòÉΓòÉΓòÉ
  942.  
  943.       PSNS_OK 
  944.       PSNS_HANDLE_IN_USE 
  945.       PSNS_COMMUNICATIONS_ERROR 
  946.       PSNS_INVALID_HANDLE 
  947.       PSNS_INVALID_LIST_HANDLE 
  948.  
  949.  
  950. ΓòÉΓòÉΓòÉ <hidden> PsnsCloseList - Remarks ΓòÉΓòÉΓòÉ
  951.  
  952. Use this function to terminate a listing operation before it has finished. The 
  953. OS/2 Warp Server Backup/Restore C API listing functions will automatically 
  954. terminate when they have finished listing all of the objects which match the 
  955. specified search criteria. However, sometimes it may be useful to stop listing 
  956. objects before you have reached the last one, so use this function to free the 
  957. list handle when you have finished with it. 
  958.  
  959.  
  960. ΓòÉΓòÉΓòÉ <hidden> PsnsCloseList - Related functions ΓòÉΓòÉΓòÉ
  961.  
  962.      PsnsListRestoreMethods 
  963.  
  964.      PsnsListBackupMethods 
  965.  
  966.      PsnsListBackupSets 
  967.  
  968.      PsnsListStorageDevices 
  969.  
  970.      PsnsListVolumes 
  971.  
  972.      PsnsListVolumeBackupSets 
  973.  
  974.      PsnsListEvents 
  975.  
  976.      PsnsListFileFilters 
  977.  
  978.      PsnsListRulebooks 
  979.  
  980.      PsnsListSourceDrives 
  981.  
  982.  
  983. ΓòÉΓòÉΓòÉ 3.11. PsnsCopyBackupMethod ΓòÉΓòÉΓòÉ
  984.  
  985. Select an item 
  986.  
  987.      Syntax 
  988.      Parameters 
  989.      Returns 
  990.      Remarks 
  991.      Example 
  992.      Related functions 
  993.  
  994.  
  995. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyBackupMethod - Syntax ΓòÉΓòÉΓòÉ
  996.  
  997. /****************************************************/
  998. /* This function creates a new backup method which  */
  999. /* is a copy of an existing backup method.          */
  1000. /****************************************************/
  1001.  
  1002. int PsnsCopyBackupMethod(PSNSHANDLE handle,
  1003.                          const char *name,
  1004.                          const char *newName);
  1005.  
  1006.  
  1007. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyBackupMethod - Parameters ΓòÉΓòÉΓòÉ
  1008.  
  1009.  handle (PSNSHANDLE) 
  1010.            Handle returned by PsnsInit. 
  1011.  
  1012.  name (const char *) 
  1013.            Name of the existing backup method to be copied. 
  1014.  
  1015.  newName (const char *) 
  1016.            Name of the new backup method. 
  1017.  
  1018.  
  1019. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyBackupMethod - Returns ΓòÉΓòÉΓòÉ
  1020.  
  1021.       PSNS_OK 
  1022.       PSNS_HANDLE_IN_USE 
  1023.       PSNS_COMMUNICATIONS_ERROR 
  1024.       PSNS_INVALID_HANDLE 
  1025.       PSNS_INVALID_BACKUP_METHOD 
  1026.       PSNS_INVALID_NAME 
  1027.       PSNS_ALREADY_EXISTS 
  1028.  
  1029.  
  1030. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyBackupMethod - Remarks ΓòÉΓòÉΓòÉ
  1031.  
  1032. Use this function to create a new backup method which is a copy of an existing 
  1033. one.  newName must not be the same as the name of any existing backup method. 
  1034.  
  1035.  
  1036. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyBackupMethod - Related functions ΓòÉΓòÉΓòÉ
  1037.  
  1038.      PsnsCreateBackupMethod 
  1039.  
  1040.      PsnsDeleteBackupMethod 
  1041.  
  1042.      PsnsRenameBackupMethod 
  1043.  
  1044.      PsnsBackupMethodInfo 
  1045.  
  1046.      PsnsListBackupMethods 
  1047.  
  1048.      PsnsEstimateBackupMethod 
  1049.  
  1050.      PsnsRunBackupMethod 
  1051.  
  1052.  
  1053. ΓòÉΓòÉΓòÉ 3.12. PsnsCopyEvent ΓòÉΓòÉΓòÉ
  1054.  
  1055. Select an item 
  1056.  
  1057.      Syntax 
  1058.      Parameters 
  1059.      Returns 
  1060.      Remarks 
  1061.      Example 
  1062.      Related functions 
  1063.  
  1064.  
  1065. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyEvent - Syntax ΓòÉΓòÉΓòÉ
  1066.  
  1067. /****************************************************/
  1068. /* This function creates a new event which is a     */
  1069. /* copy of an existing event.                       */
  1070. /****************************************************/
  1071.  
  1072. int PsnsCopyEvent(PSNSHANDLE handle,
  1073.                   USHORT eventID,
  1074.                   USHORT *newEventID);
  1075.  
  1076.  
  1077. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyEvent - Parameters ΓòÉΓòÉΓòÉ
  1078.  
  1079.  handle (PSNSHANDLE) 
  1080.            Handle returned by PsnsInit. 
  1081.  
  1082.  eventID (USHORT) 
  1083.            ID of the existing event to be copied. 
  1084.  
  1085.  newEventID (USHORT *) 
  1086.            Pointer to where the new event ID will be stored. 
  1087.  
  1088.  
  1089. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyEvent - Returns ΓòÉΓòÉΓòÉ
  1090.  
  1091.       PSNS_OK 
  1092.       PSNS_HANDLE_IN_USE 
  1093.       PSNS_COMMUNICATIONS_ERROR 
  1094.       PSNS_INVALID_HANDLE 
  1095.       PSNS_INVALID_EVENT 
  1096.  
  1097.  
  1098. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyEvent - Remarks ΓòÉΓòÉΓòÉ
  1099.  
  1100. Use this function to create a new event which is a copy of an existing one. 
  1101. The ID of the newly-created event is returned in *newEventID. 
  1102.  
  1103.  
  1104. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyEvent - Related functions ΓòÉΓòÉΓòÉ
  1105.  
  1106.      PsnsCreateEvent 
  1107.  
  1108.      PsnsDeleteEvent 
  1109.  
  1110.      PsnsEventInfo 
  1111.  
  1112.      PsnsListEvents 
  1113.  
  1114.      PsnsGetNextEvent 
  1115.  
  1116.      PsnsActivateEvent 
  1117.  
  1118.  
  1119. ΓòÉΓòÉΓòÉ 3.13. PsnsCopyFileFilter ΓòÉΓòÉΓòÉ
  1120.  
  1121. Select an item 
  1122.  
  1123.      Syntax 
  1124.      Parameters 
  1125.      Returns 
  1126.      Remarks 
  1127.      Example 
  1128.      Related functions 
  1129.  
  1130.  
  1131. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyFileFilter - Syntax ΓòÉΓòÉΓòÉ
  1132.  
  1133. /****************************************************/
  1134. /* This function creates a new file filter which is */
  1135. /* a copy of an existing file filter.               */
  1136. /****************************************************/
  1137.  
  1138. int PsnsCopyFileFilter(PSNSHANDLE handle,
  1139.                        const char *name,
  1140.                        const char *newName);
  1141.  
  1142.  
  1143. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyFileFilter - Parameters ΓòÉΓòÉΓòÉ
  1144.  
  1145.  handle (PSNSHANDLE) 
  1146.            Handle returned by PsnsInit. 
  1147.  
  1148.  name (const char *) 
  1149.            Name of the existing file filter to be copied. 
  1150.  
  1151.  newName (const char *) 
  1152.            Name of the new file filter. 
  1153.  
  1154.  
  1155. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyFileFilter - Returns ΓòÉΓòÉΓòÉ
  1156.  
  1157.       PSNS_OK 
  1158.       PSNS_HANDLE_IN_USE 
  1159.       PSNS_COMMUNICATIONS_ERROR 
  1160.       PSNS_INVALID_HANDLE 
  1161.       PSNS_INVALID_FILE_FILTER 
  1162.       PSNS_ALREADY_EXISTS 
  1163.       PSNS_INVALID_NAME 
  1164.  
  1165.  
  1166. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyFileFilter - Remarks ΓòÉΓòÉΓòÉ
  1167.  
  1168. Use this function to create a new file filter which is a copy of an existing 
  1169. one.  newName must not be the same as the name of any existing file filter. 
  1170.  
  1171.  
  1172. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyFileFilter - Related functions ΓòÉΓòÉΓòÉ
  1173.  
  1174.      PsnsCreateFileFilter 
  1175.  
  1176.      PsnsDeleteFileFilter 
  1177.  
  1178.      PsnsRenameFileFilter 
  1179.  
  1180.      PsnsFileFilterInfo 
  1181.  
  1182.      PsnsListFileFilters 
  1183.  
  1184.  
  1185. ΓòÉΓòÉΓòÉ 3.14. PsnsCopyRestoreMethod ΓòÉΓòÉΓòÉ
  1186.  
  1187. Select an item 
  1188.  
  1189.      Syntax 
  1190.      Parameters 
  1191.      Returns 
  1192.      Remarks 
  1193.      Example 
  1194.      Related functions 
  1195.  
  1196.  
  1197. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyRestoreMethod - Syntax ΓòÉΓòÉΓòÉ
  1198.  
  1199. /****************************************************/
  1200. /* This function creates a new restore method which */
  1201. /* is a copy of an existing restore method.         */
  1202. /****************************************************/
  1203.  
  1204. int PsnsCopyRestoreMethod(PSNSHANDLE handle,
  1205.                           const char *name,
  1206.                           const char *newName);
  1207.  
  1208.  
  1209. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyRestoreMethod - Parameters ΓòÉΓòÉΓòÉ
  1210.  
  1211.  handle (PSNSHANDLE) 
  1212.            Handle returned by PsnsInit. 
  1213.  
  1214.  name (const char *) 
  1215.            Name of the existing restore method to be copied. 
  1216.  
  1217.  newName (const char *) 
  1218.            Name of the new restore method. 
  1219.  
  1220.  
  1221. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyRestoreMethod - Returns ΓòÉΓòÉΓòÉ
  1222.  
  1223.       PSNS_OK 
  1224.       PSNS_HANDLE_IN_USE 
  1225.       PSNS_COMMUNICATIONS_ERROR 
  1226.       PSNS_INVALID_HANDLE 
  1227.       PSNS_INVALID_RESTORE_METHOD 
  1228.       PSNS_ALREADY_EXISTS 
  1229.       PSNS_INVALID_NAME 
  1230.  
  1231.  
  1232. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyRestoreMethod - Remarks ΓòÉΓòÉΓòÉ
  1233.  
  1234. Use this function to create a new restore method which is a copy of an existing 
  1235. one.  newName must not be the same as the name of any existing restore method. 
  1236.  
  1237.  
  1238. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyRestoreMethod - Related functions ΓòÉΓòÉΓòÉ
  1239.  
  1240.      PsnsCreateRestoreMethod 
  1241.  
  1242.      PsnsDeleteRestoreMethod 
  1243.  
  1244.      PsnsRenameRestoreMethod 
  1245.  
  1246.      PsnsRestoreMethodInfo 
  1247.  
  1248.      PsnsListRestoreMethods 
  1249.  
  1250.      PsnsEstimateRestoreMethod 
  1251.  
  1252.      PsnsRunRestoreMethod 
  1253.  
  1254.  
  1255. ΓòÉΓòÉΓòÉ 3.15. PsnsCopyRulebook ΓòÉΓòÉΓòÉ
  1256.  
  1257. Select an item 
  1258.  
  1259.      Syntax 
  1260.      Parameters 
  1261.      Returns 
  1262.      Remarks 
  1263.      Example 
  1264.      Related functions 
  1265.  
  1266.  
  1267. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyRulebook - Syntax ΓòÉΓòÉΓòÉ
  1268.  
  1269. /****************************************************/
  1270. /* This function creates a new rulebook which is a  */
  1271. /* copy of an existing rulebook.                    */
  1272. /****************************************************/
  1273.  
  1274. int PsnsCopyRulebook(PSNSHANDLE handle,
  1275.                      const char *name,
  1276.                      const char *newName);
  1277.  
  1278.  
  1279. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyRulebook - Parameters ΓòÉΓòÉΓòÉ
  1280.  
  1281.  handle (PSNSHANDLE) 
  1282.            Handle returned by PsnsInit. 
  1283.  
  1284.  name (const char *) 
  1285.            Name of the existing rulebook to be copied. 
  1286.  
  1287.  newName (const char *) 
  1288.            Name of the new rulebook. 
  1289.  
  1290.  
  1291. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyRulebook - Returns ΓòÉΓòÉΓòÉ
  1292.  
  1293.       PSNS_OK 
  1294.       PSNS_HANDLE_IN_USE 
  1295.       PSNS_COMMUNICATIONS_ERROR 
  1296.       PSNS_INVALID_HANDLE 
  1297.       PSNS_INVALID_RULEBOOK 
  1298.       PSNS_ALREADY_EXISTS 
  1299.       PSNS_INVALID_NAME 
  1300.  
  1301.  
  1302. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyRulebook - Remarks ΓòÉΓòÉΓòÉ
  1303.  
  1304. Use this function to create a new rulebook which is a copy of an existing one. 
  1305. newName must not be the same as the name of any existing rulebook. 
  1306.  
  1307.  
  1308. ΓòÉΓòÉΓòÉ <hidden> PsnsCopyRulebook - Related functions ΓòÉΓòÉΓòÉ
  1309.  
  1310.      PsnsCreateRulebook 
  1311.  
  1312.      PsnsDeleteRulebook 
  1313.  
  1314.      PsnsRenameRulebook 
  1315.  
  1316.      PsnsRulebookInfo 
  1317.  
  1318.      PsnsListRulebooks 
  1319.  
  1320.      PsnsAddRulebookRule 
  1321.  
  1322.      PsnsDeleteRulebookRule 
  1323.  
  1324.      PsnsRulebookRuleInfo 
  1325.  
  1326.  
  1327. ΓòÉΓòÉΓòÉ 3.16. PsnsCreateBackupMethod ΓòÉΓòÉΓòÉ
  1328.  
  1329. Select an item 
  1330.  
  1331.      Syntax 
  1332.      Parameters 
  1333.      Returns 
  1334.      Remarks 
  1335.      Example 
  1336.      Related functions 
  1337.  
  1338.  
  1339. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateBackupMethod - Syntax ΓòÉΓòÉΓòÉ
  1340.  
  1341. /****************************************************/
  1342. /* This function creates a new backup method.       */
  1343. /****************************************************/
  1344.  
  1345. int PsnsCreateBackupMethod(PSNSHANDLE handle,
  1346.                            const char *name);
  1347.  
  1348.  
  1349. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateBackupMethod - Parameters ΓòÉΓòÉΓòÉ
  1350.  
  1351.  handle (PSNSHANDLE) 
  1352.            Handle returned by PsnsInit. 
  1353.  
  1354.  name (const char *) 
  1355.            Name of the backup method to be created. 
  1356.  
  1357.  
  1358. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateBackupMethod - Returns ΓòÉΓòÉΓòÉ
  1359.  
  1360.       PSNS_OK 
  1361.       PSNS_HANDLE_IN_USE 
  1362.       PSNS_COMMUNICATIONS_ERROR 
  1363.       PSNS_INVALID_HANDLE 
  1364.       PSNS_ALREADY_EXISTS 
  1365.       PSNS_INVALID_NAME 
  1366.  
  1367.  
  1368. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateBackupMethod - Remarks ΓòÉΓòÉΓòÉ
  1369.  
  1370. Use this function to create a new backup method.  name must not be the name of 
  1371. any existing backup method.  The backup method is created with default 
  1372. settings; you can use PsnsBackupMethodInfo to change these. 
  1373.  
  1374.  
  1375. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateBackupMethod - Related functions ΓòÉΓòÉΓòÉ
  1376.  
  1377.      PsnsDeleteBackupMethod 
  1378.  
  1379.      PsnsRenameBackupMethod 
  1380.  
  1381.      PsnsCopyBackupMethod 
  1382.  
  1383.      PsnsBackupMethodInfo 
  1384.  
  1385.      PsnsListBackupMethods 
  1386.  
  1387.      PsnsEstimateBackupMethod 
  1388.  
  1389.      PsnsRunBackupMethod 
  1390.  
  1391.  
  1392. ΓòÉΓòÉΓòÉ 3.17. PsnsCreateBackupSet ΓòÉΓòÉΓòÉ
  1393.  
  1394. Select an item 
  1395.  
  1396.      Syntax 
  1397.      Parameters 
  1398.      Returns 
  1399.      Remarks 
  1400.      Example 
  1401.      Related functions 
  1402.  
  1403.  
  1404. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateBackupSet - Syntax ΓòÉΓòÉΓòÉ
  1405.  
  1406. /****************************************************/
  1407. /* This function creates a new backup set.          */
  1408. /****************************************************/
  1409.  
  1410. int PsnsCreateBackupSet(PSNSHANDLE handle,
  1411.                         const char *name,
  1412.                         const char *StorageDevice,
  1413.                         const char *Config,
  1414.                         const char *incStorageDevice,
  1415.                         const char *incConfig);
  1416.  
  1417.  
  1418. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateBackupSet - Parameters ΓòÉΓòÉΓòÉ
  1419.  
  1420.  handle (PSNSHANDLE) 
  1421.            Handle returned by PsnsInit. 
  1422.  
  1423.  name (const char *) 
  1424.            Name of the backup set to be created. 
  1425.  
  1426.  StorageDevice (const char *) 
  1427.            For a single device backup set this is the storage device the backup 
  1428.            set will use for all backups, you should set the incStorageDevice 
  1429.            and incConfig parameters to be NULL. For a dual device backup set 
  1430.            this is the name of the storage device which this backup set will 
  1431.            use for the base backup, you should also specify an incremental 
  1432.            storage device. 
  1433.  
  1434.  Config (const char *) 
  1435.            Configuration string for the storage device; for more information 
  1436.            see PsnsSetBackupSetConfig. For dual device backup sets this is the 
  1437.            configuration string for the base storage device. 
  1438.  
  1439.  incStorageDevice (const char *) 
  1440.            Name of the storage device which this dual device backup set will 
  1441.            use for incremental backups.  When creating single device backup 
  1442.            sets pass this parameter as NULL. 
  1443.  
  1444.  incConfig (const char *) 
  1445.            Configuration string for the incremental device; for more 
  1446.            information see PsnsSetBackupSetConfig. When creating single device 
  1447.            backup sets pass this parameter as NULL. 
  1448.  
  1449.  
  1450. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateBackupSet - Returns ΓòÉΓòÉΓòÉ
  1451.  
  1452.       PSNS_OK 
  1453.       PSNS_HANDLE_IN_USE 
  1454.       PSNS_COMMUNICATIONS_ERROR 
  1455.       PSNS_INVALID_HANDLE 
  1456.       PSNS_ALREADY_EXISTS 
  1457.       PSNS_INVALID_NAME 
  1458.       PSNS_INVALID_STORAGE_DEVICE 
  1459.       PSNS_CANNOT_CREATE_BACKUP_SET 
  1460.       PSNS_INVALID_KEYWORD 
  1461.       PSNS_INVALID_VALUE 
  1462.       PSNS_SYNTAX_ERROR 
  1463.       PSNS_INCOMPLETE_STRING 
  1464.       PSNS_SEMANTIC_ERROR 
  1465.  
  1466.  
  1467. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateBackupSet - Remarks ΓòÉΓòÉΓòÉ
  1468.  
  1469. Use this function to create a new backup set.  name must not be the name of any 
  1470. existing backup set.  The backup set is created with default settings; you can 
  1471. use PsnsBackupSetInfo to change these. 
  1472.  
  1473. When creating a normal, single storage device backup set just set the last two 
  1474. parameters to be NULL.  When creating a dual storage device backup set specify 
  1475. all the parameters. 
  1476.  
  1477.  
  1478. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateBackupSet - Related functions ΓòÉΓòÉΓòÉ
  1479.  
  1480.      PsnsDeleteBackupSet 
  1481.  
  1482.      PsnsBackupSetInfo 
  1483.  
  1484.      PsnsSetBackupSetConfig 
  1485.  
  1486.      PsnsGetBackupSetConfig 
  1487.  
  1488.      PsnsListBackupSets 
  1489.  
  1490.      PsnsTransferBackupSet 
  1491.  
  1492.      PsnsTransferIn 
  1493.  
  1494.      PsnsGetLogFile 
  1495.  
  1496.      PsnsEmptyBackupSet 
  1497.  
  1498.  
  1499. ΓòÉΓòÉΓòÉ 3.18. PsnsCreateEvent ΓòÉΓòÉΓòÉ
  1500.  
  1501. Select an item 
  1502.  
  1503.      Syntax 
  1504.      Parameters 
  1505.      Returns 
  1506.      Remarks 
  1507.      Example 
  1508.      Related functions 
  1509.  
  1510.  
  1511. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateEvent - Syntax ΓòÉΓòÉΓòÉ
  1512.  
  1513. /****************************************************/
  1514. /* This function creates a new scheduled event.     */
  1515. /****************************************************/
  1516.  
  1517. int PsnsCreateEvent(PSNSHANDLE handle,
  1518.                     EVENTTYPE type,
  1519.                     const char *method,
  1520.                     USHORT *eventID);
  1521.  
  1522.  
  1523. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateEvent - Parameters ΓòÉΓòÉΓòÉ
  1524.  
  1525.  handle (PSNSHANDLE) 
  1526.            Handle returned by PsnsInit. 
  1527.  
  1528.  type (EVENTTYPE) 
  1529.            Type of event to be created. 
  1530.  
  1531.  method (const char *) 
  1532.            Name of the backup method which the event will use.  This can be 
  1533.            changed later but must be specified when you first create an event. 
  1534.  
  1535.  eventID (USHORT *) 
  1536.            Pointer to where the ID of the new event should be stored. 
  1537.  
  1538.  
  1539. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateEvent - Returns ΓòÉΓòÉΓòÉ
  1540.  
  1541.       PSNS_OK 
  1542.       PSNS_HANDLE_IN_USE 
  1543.       PSNS_COMMUNICATIONS_ERROR 
  1544.       PSNS_INVALID_HANDLE 
  1545.       PSNS_INVALID_EVENT_TYPE 
  1546.  
  1547.  
  1548. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateEvent - Remarks ΓòÉΓòÉΓòÉ
  1549.  
  1550. Use this function to create a new scheduled event.  The ID of the event is 
  1551. placed in *eventID. The event is created with default settings; you can use 
  1552. PsnsEventInfo to change these. 
  1553.  
  1554.  
  1555. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateEvent - Related functions ΓòÉΓòÉΓòÉ
  1556.  
  1557.      PsnsDeleteEvent 
  1558.  
  1559.      PsnsCopyEvent 
  1560.  
  1561.      PsnsEventInfo 
  1562.  
  1563.      PsnsListEvents 
  1564.  
  1565.      PsnsGetNextEvent 
  1566.  
  1567.      PsnsActivateEvent 
  1568.  
  1569.  
  1570. ΓòÉΓòÉΓòÉ 3.19. PsnsCreateFileFilter ΓòÉΓòÉΓòÉ
  1571.  
  1572. Select an item 
  1573.  
  1574.      Syntax 
  1575.      Parameters 
  1576.      Returns 
  1577.      Remarks 
  1578.      Example 
  1579.      Related functions 
  1580.  
  1581.  
  1582. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateFileFilter - Syntax ΓòÉΓòÉΓòÉ
  1583.  
  1584. /****************************************************/
  1585. /* This function creates a new file filter.         */
  1586. /****************************************************/
  1587.  
  1588. int PsnsCreateFileFilter(PSNSHANDLE handle,
  1589.                          const char *name,
  1590.                          FILEFILTERTYPE fileFilterType);
  1591.  
  1592.  
  1593. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateFileFilter - Parameters ΓòÉΓòÉΓòÉ
  1594.  
  1595.  handle (PSNSHANDLE) 
  1596.            Handle returned by PsnsInit. 
  1597.  
  1598.  name (const char *) 
  1599.            Name of the file filter to be created. 
  1600.  
  1601.  fileFilterType (FILEFILTERTYPE) 
  1602.            Type of file filter to create. 
  1603.  
  1604.  
  1605. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateFileFilter - Returns ΓòÉΓòÉΓòÉ
  1606.  
  1607.       PSNS_OK 
  1608.       PSNS_HANDLE_IN_USE 
  1609.       PSNS_COMMUNICATIONS_ERROR 
  1610.       PSNS_INVALID_HANDLE 
  1611.       PSNS_ALREADY_EXISTS 
  1612.       PSNS_INVALID_NAME 
  1613.       PSNS_INVALID_FILE_FILTER_TYPE 
  1614.  
  1615.  
  1616. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateFileFilter - Remarks ΓòÉΓòÉΓòÉ
  1617.  
  1618. Use this function to create a new file filter.  name must not be the name of 
  1619. any existing file filter.  The file filter is created empty; you can use 
  1620. PsnsFileFilterInfo to change its settings and PsnsAddFileFilterRule to add new 
  1621. rules to it. 
  1622.  
  1623.  
  1624. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateFileFilter - Related functions ΓòÉΓòÉΓòÉ
  1625.  
  1626.      PsnsDeleteFileFilter 
  1627.  
  1628.      PsnsRenameFileFilter 
  1629.  
  1630.      PsnsCopyFileFilter 
  1631.  
  1632.      PsnsFileFilterInfo 
  1633.  
  1634.      PsnsListFileFilters 
  1635.  
  1636.  
  1637. ΓòÉΓòÉΓòÉ 3.20. PsnsCreateRestoreMethod ΓòÉΓòÉΓòÉ
  1638.  
  1639. Select an item 
  1640.  
  1641.      Syntax 
  1642.      Parameters 
  1643.      Returns 
  1644.      Remarks 
  1645.      Example 
  1646.      Related functions 
  1647.  
  1648.  
  1649. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateRestoreMethod - Syntax ΓòÉΓòÉΓòÉ
  1650.  
  1651. /****************************************************/
  1652. /* This function creates a new restore method       */
  1653. /****************************************************/
  1654.  
  1655. int PsnsCreateRestoreMethod(PSNSHANDLE handle,
  1656.                             const char *name);
  1657.  
  1658.  
  1659. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateRestoreMethod - Parameters ΓòÉΓòÉΓòÉ
  1660.  
  1661.  handle (PSNSHANDLE) 
  1662.            Handle returned by PsnsInit. 
  1663.  
  1664.  name (const char *) 
  1665.            Name of the restore method to be created. 
  1666.  
  1667.  
  1668. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateRestoreMethod - Returns ΓòÉΓòÉΓòÉ
  1669.  
  1670.       PSNS_OK 
  1671.       PSNS_HANDLE_IN_USE 
  1672.       PSNS_COMMUNICATIONS_ERROR 
  1673.       PSNS_INVALID_HANDLE 
  1674.       PSNS_ALREADY_EXISTS 
  1675.       PSNS_INVALID_NAME 
  1676.  
  1677.  
  1678. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateRestoreMethod - Remarks ΓòÉΓòÉΓòÉ
  1679.  
  1680. Use this function to create a new restore method.  name must not be the name of 
  1681. any existing restore method.  The restore method is created with default 
  1682. settings; you can use PsnsRestoreMethodInfo to change these. 
  1683.  
  1684.  
  1685. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateRestoreMethod - Related functions ΓòÉΓòÉΓòÉ
  1686.  
  1687.      PsnsDeleteRestoreMethod 
  1688.  
  1689.      PsnsRenameRestoreMethod 
  1690.  
  1691.      PsnsCopyRestoreMethod 
  1692.  
  1693.      PsnsRestoreMethodInfo 
  1694.  
  1695.      PsnsListRestoreMethods 
  1696.  
  1697.      PsnsEstimateRestoreMethod 
  1698.  
  1699.      PsnsRunRestoreMethod 
  1700.  
  1701.  
  1702. ΓòÉΓòÉΓòÉ 3.21. PsnsCreateRulebook ΓòÉΓòÉΓòÉ
  1703.  
  1704. Select an item 
  1705.  
  1706.      Syntax 
  1707.      Parameters 
  1708.      Returns 
  1709.      Remarks 
  1710.      Example 
  1711.      Related functions 
  1712.  
  1713.  
  1714. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateRulebook - Syntax ΓòÉΓòÉΓòÉ
  1715.  
  1716. /****************************************************/
  1717. /* This function creates a new rulebook.            */
  1718. /****************************************************/
  1719.  
  1720. int PsnsCreateRulebook(PSNSHANDLE handle,
  1721.                        const char *name);
  1722.  
  1723.  
  1724. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateRulebook - Parameters ΓòÉΓòÉΓòÉ
  1725.  
  1726.  handle (PSNSHANDLE) 
  1727.            Handle returned by PsnsInit. 
  1728.  
  1729.  name (const char *) 
  1730.            Name of the rulebook to be created. 
  1731.  
  1732.  
  1733. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateRulebook - Returns ΓòÉΓòÉΓòÉ
  1734.  
  1735.       PSNS_OK 
  1736.       PSNS_HANDLE_IN_USE 
  1737.       PSNS_COMMUNICATIONS_ERROR 
  1738.       PSNS_INVALID_HANDLE 
  1739.       PSNS_ALREADY_EXISTS 
  1740.       PSNS_INVALID_NAME 
  1741.  
  1742.  
  1743. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateRulebook - Remarks ΓòÉΓòÉΓòÉ
  1744.  
  1745. Use this function to create a new rulebook.  name must not be the name of any 
  1746. existing rulebook.  The rulebook is created empty; you can use PsnsRulebookInfo 
  1747. to change its settings and PsnsAddRulebookRule to add new rules to it. 
  1748.  
  1749.  
  1750. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateRulebook - Related functions ΓòÉΓòÉΓòÉ
  1751.  
  1752.      PsnsDeleteRulebook 
  1753.  
  1754.      PsnsRenameRulebook 
  1755.  
  1756.      PsnsCopyRulebook 
  1757.  
  1758.      PsnsRulebookInfo 
  1759.  
  1760.      PsnsListRulebooks 
  1761.  
  1762.      PsnsAddRulebookRule 
  1763.  
  1764.      PsnsDeleteRulebookRule 
  1765.  
  1766.      PsnsRulebookRuleInfo 
  1767.  
  1768.  
  1769. ΓòÉΓòÉΓòÉ 3.22. PsnsCreateStorageDevice ΓòÉΓòÉΓòÉ
  1770.  
  1771. Select an item 
  1772.  
  1773.      Syntax 
  1774.      Parameters 
  1775.      Returns 
  1776.      Remarks 
  1777.      Example 
  1778.      Related functions 
  1779.  
  1780.  
  1781. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateStorageDevice - Syntax ΓòÉΓòÉΓòÉ
  1782.  
  1783. /****************************************************/
  1784. /* This function creates a new storage device.      */
  1785. /****************************************************/
  1786.  
  1787. int PsnsCreateStorageDevice(PSNSHANDLE handle,
  1788.                             const char *type,
  1789.                             const char *config,
  1790.                             char *name);
  1791.  
  1792.  
  1793. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateStorageDevice - Parameters ΓòÉΓòÉΓòÉ
  1794.  
  1795.  handle (PSNSHANDLE) 
  1796.            Handle returned by PsnsInit. 
  1797.  
  1798.  type (const char *) 
  1799.            Name of the storage device type you want to create.  To find out 
  1800.            what to put here, you should use PsnsListStorageDevices with the 
  1801.            SD_CREATABLE mask bit set; this will list all the storage device 
  1802.            types available for creating new storage devices. 
  1803.  
  1804.  config (const char *) 
  1805.            Configuration string for the storage device; for more information 
  1806.            see PsnsSetStorageDeviceConfig. 
  1807.  
  1808.  name (char *) 
  1809.            Pointer to a buffer of length PSNS_NAME_SIZE + 1 to receive the name 
  1810.            of the new storage device. 
  1811.  
  1812.  
  1813. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateStorageDevice - Returns ΓòÉΓòÉΓòÉ
  1814.  
  1815.       PSNS_OK 
  1816.       PSNS_HANDLE_IN_USE 
  1817.       PSNS_COMMUNICATIONS_ERROR 
  1818.       PSNS_INVALID_HANDLE 
  1819.       PSNS_INVALID_STORAGE_DEVICE_TYPE 
  1820.       PSNS_ALREADY_EXISTS 
  1821.       PSNS_INVALID_NAME 
  1822.       PSNS_INVALID_KEYWORD 
  1823.       PSNS_INVALID_VALUE 
  1824.       PSNS_SYNTAX_ERROR 
  1825.       PSNS_INCOMPLETE_STRING 
  1826.       PSNS_SEMANTIC_ERROR 
  1827.  
  1828.  
  1829. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateStorageDevice - Remarks ΓòÉΓòÉΓòÉ
  1830.  
  1831. Use this function to create a new storage device.  You need to specify what 
  1832. type of storage device is being created; to get a list of all the available 
  1833. storage device types for creating a new storage device, you should call 
  1834. PsnsListStorageDevices with the SD_CREATABLE mask bit set.  The storage device 
  1835. is created with the default settings; to change them, use 
  1836. PsnsSetStorageDeviceConfig. 
  1837.  
  1838.  
  1839. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateStorageDevice - Related functions ΓòÉΓòÉΓòÉ
  1840.  
  1841.      PsnsDeleteStorageDevice 
  1842.  
  1843.      PsnsStorageDeviceInfo 
  1844.  
  1845.      PsnsSetStorageDeviceConfig 
  1846.  
  1847.      PsnsGetStorageDeviceConfig 
  1848.  
  1849.      PsnsListStorageDevices 
  1850.  
  1851.      PsnsRefreshStorageDevices 
  1852.  
  1853.  
  1854. ΓòÉΓòÉΓòÉ 3.23. PsnsCreateVolume ΓòÉΓòÉΓòÉ
  1855.  
  1856. Select an item 
  1857.  
  1858.      Syntax 
  1859.      Parameters 
  1860.      Returns 
  1861.      Remarks 
  1862.      Example 
  1863.      Related functions 
  1864.  
  1865.  
  1866. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateVolume - Syntax ΓòÉΓòÉΓòÉ
  1867.  
  1868. /****************************************************/
  1869. /* This function creates a new volume.              */
  1870. /****************************************************/
  1871.  
  1872. int PsnsCreateVolume(PSNSHANDLE handle,
  1873.                      const char *storageDevice,
  1874.                      ULONG *volumeID);
  1875.  
  1876.  
  1877. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateVolume - Parameters ΓòÉΓòÉΓòÉ
  1878.  
  1879.  handle (PSNSHANDLE) 
  1880.            Handle returned by PsnsInit. 
  1881.  
  1882.  storageDevice (const char *) 
  1883.            Name of the storage device with which to create the volume. 
  1884.  
  1885.  volumeID (ULONG *) 
  1886.            Pointer to where the ID of the new volume should be stored. 
  1887.  
  1888.  
  1889. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateVolume - Returns ΓòÉΓòÉΓòÉ
  1890.  
  1891.       PSNS_OK 
  1892.       PSNS_HANDLE_IN_USE 
  1893.       PSNS_COMMUNICATIONS_ERROR 
  1894.       PSNS_INVALID_HANDLE 
  1895.       PSNS_INVALID_STORAGE_DEVICE 
  1896.       PSNS_INVALID_STORAGE_DEVICE_TYPE 
  1897.       PSNS_IN_USE 
  1898.  
  1899.  
  1900. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateVolume - Remarks ΓòÉΓòÉΓòÉ
  1901.  
  1902. Use this function to create a new volume.  The ID of the volume is placed in 
  1903. *volumeID.  The volume will not be associated with any backup set and will not 
  1904. be used until you have called PsnsAssociateVolume to associate it with a backup 
  1905. set. 
  1906.  
  1907.  
  1908. ΓòÉΓòÉΓòÉ <hidden> PsnsCreateVolume - Related functions ΓòÉΓòÉΓòÉ
  1909.  
  1910.      PsnsDeleteVolume 
  1911.  
  1912.      PsnsVolumeInfo 
  1913.  
  1914.      PsnsListVolumes 
  1915.  
  1916.      PsnsListVolumeBackupSets 
  1917.  
  1918.      PsnsActivateVolume 
  1919.  
  1920.      PsnsAssociateVolume 
  1921.  
  1922.  
  1923. ΓòÉΓòÉΓòÉ 3.24. PsnsDefaults ΓòÉΓòÉΓòÉ
  1924.  
  1925. Select an item 
  1926.  
  1927.      Syntax 
  1928.      Parameters 
  1929.      Returns 
  1930.      Remarks 
  1931.      Example 
  1932.      Related functions 
  1933.  
  1934.  
  1935. ΓòÉΓòÉΓòÉ <hidden> PsnsDefaults - Syntax ΓòÉΓòÉΓòÉ
  1936.  
  1937. /****************************************************/
  1938. /* This function gets or sets the default file      */
  1939. /* filter, rulebook, backup set, compression and    */
  1940. /* number of generations.                           */
  1941. /****************************************************/
  1942.  
  1943. int PsnsDefaults(PSNSHANDLE handle,
  1944.                  PPSNSDEFAULTS pPsnsDefaults,
  1945.                  long mask);
  1946.  
  1947.  
  1948. ΓòÉΓòÉΓòÉ <hidden> PsnsDefaults - Parameters ΓòÉΓòÉΓòÉ
  1949.  
  1950.  handle (PSNSHANDLE) 
  1951.            Handle returned by PsnsInit. 
  1952.  
  1953.  pPsnsDefaults (PPSNSDEFAULTS) 
  1954.            Pointer to a PSNSDEFAULTS structure which contains the new defaults 
  1955.            if they are to be changed, and to receive the current defaults.  If 
  1956.            the corresponding bit in mask is set then the defaults will be 
  1957.            changed to what is passed in this structure.  The new defaults are 
  1958.            returned in this structure.  To get the defaults without changing 
  1959.            them, set mask = SET_NONE. 
  1960.  
  1961.  mask (long) 
  1962.            Possible values: 
  1963.  
  1964.                 SET_NONE 
  1965.                 SET_FILEFILTER 
  1966.                 SET_RULEBOOK 
  1967.                 SET_BACKUPSET 
  1968.                 SET_COMPRESSION 
  1969.                 SET_GENERATIONS 
  1970.                 SET_ALL 
  1971.  
  1972.            To set more than one setting, OR the different values together.  To 
  1973.            set all the settings, use mask = SET_ALL. 
  1974.  
  1975.  
  1976. ΓòÉΓòÉΓòÉ <hidden> PsnsDefaults - Returns ΓòÉΓòÉΓòÉ
  1977.  
  1978.       PSNS_OK 
  1979.       PSNS_HANDLE_IN_USE 
  1980.       PSNS_COMMUNICATIONS_ERROR 
  1981.       PSNS_INVALID_HANDLE 
  1982.       PSNS_INVALID_FILE_FILTER 
  1983.       PSNS_INVALID_RULEBOOK 
  1984.       PSNS_INVALID_COMPRESSION 
  1985.       PSNS_INVALID_GENERATIONS 
  1986.  
  1987.  
  1988. ΓòÉΓòÉΓòÉ <hidden> PsnsDefaults - Remarks ΓòÉΓòÉΓòÉ
  1989.  
  1990. Use this function to inspect or change the default file filter, rulebook, 
  1991. backup set, compression and number of generations to be kept.  The mask 
  1992. parameter defines which settings are changed.  For more information on the 
  1993. individual fields, see PSNSDEFAULTS. 
  1994.  
  1995.  
  1996. ΓòÉΓòÉΓòÉ <hidden> PsnsDefaults - Related functions ΓòÉΓòÉΓòÉ
  1997.  
  1998.      PsnsSettings 
  1999.  
  2000.  
  2001. ΓòÉΓòÉΓòÉ 3.25. PsnsDeleteBackupMethod ΓòÉΓòÉΓòÉ
  2002.  
  2003. Select an item 
  2004.  
  2005.      Syntax 
  2006.      Parameters 
  2007.      Returns 
  2008.      Remarks 
  2009.      Example 
  2010.      Related functions 
  2011.  
  2012.  
  2013. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteBackupMethod - Syntax ΓòÉΓòÉΓòÉ
  2014.  
  2015. /****************************************************/
  2016. /* This function deletes a backup method.           */
  2017. /****************************************************/
  2018.  
  2019. int PsnsDeleteBackupMethod(PSNSHANDLE handle,
  2020.                            const char *name);
  2021.  
  2022.  
  2023. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteBackupMethod - Parameters ΓòÉΓòÉΓòÉ
  2024.  
  2025.  handle (PSNSHANDLE) 
  2026.            Handle returned by PsnsInit. 
  2027.  
  2028.  name (const char *) 
  2029.            Name of the backup method to be deleted. 
  2030.  
  2031.  
  2032. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteBackupMethod - Returns ΓòÉΓòÉΓòÉ
  2033.  
  2034.       PSNS_OK 
  2035.       PSNS_HANDLE_IN_USE 
  2036.       PSNS_COMMUNICATIONS_ERROR 
  2037.       PSNS_INVALID_HANDLE 
  2038.       PSNS_INVALID_BACKUP_METHOD 
  2039.       PSNS_IN_USE 
  2040.  
  2041.  
  2042. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteBackupMethod - Remarks ΓòÉΓòÉΓòÉ
  2043.  
  2044. If the named backup method exists, it will be deleted. 
  2045.  
  2046.  
  2047. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteBackupMethod - Related functions ΓòÉΓòÉΓòÉ
  2048.  
  2049.      PsnsCreateBackupMethod 
  2050.  
  2051.      PsnsRenameBackupMethod 
  2052.  
  2053.      PsnsCopyBackupMethod 
  2054.  
  2055.      PsnsBackupMethodInfo 
  2056.  
  2057.      PsnsListBackupMethods 
  2058.  
  2059.      PsnsEstimateBackupMethod 
  2060.  
  2061.      PsnsRunBackupMethod 
  2062.  
  2063.  
  2064. ΓòÉΓòÉΓòÉ 3.26. PsnsDeleteBackupSet ΓòÉΓòÉΓòÉ
  2065.  
  2066. Select an item 
  2067.  
  2068.      Syntax 
  2069.      Parameters 
  2070.      Returns 
  2071.      Remarks 
  2072.      Example 
  2073.      Related functions 
  2074.  
  2075.  
  2076. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteBackupSet - Syntax ΓòÉΓòÉΓòÉ
  2077.  
  2078. /****************************************************/
  2079. /* This function deletes a backup set.              */
  2080. /****************************************************/
  2081.  
  2082. int PsnsDeleteBackupSet(PSNSHANDLE handle,
  2083.                         const char *name);
  2084.  
  2085.  
  2086. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteBackupSet - Parameters ΓòÉΓòÉΓòÉ
  2087.  
  2088.  handle (PSNSHANDLE) 
  2089.            Handle returned by PsnsInit. 
  2090.  
  2091.  name (const char *) 
  2092.            Name of the backup set to be deleted. 
  2093.  
  2094.  
  2095. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteBackupSet - Returns ΓòÉΓòÉΓòÉ
  2096.  
  2097.       PSNS_OK 
  2098.       PSNS_HANDLE_IN_USE 
  2099.       PSNS_COMMUNICATIONS_ERROR 
  2100.       PSNS_INVALID_HANDLE 
  2101.       PSNS_INVALID_BACKUP_SET 
  2102.       PSNS_IN_USE 
  2103.  
  2104.  
  2105. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteBackupSet - Remarks ΓòÉΓòÉΓòÉ
  2106.  
  2107. If the named backup set exists, it will be deleted.  You should take care not 
  2108. to delete a backup set which is referenced by any backup methods or restore 
  2109. methods; if you do then they will become invalid. 
  2110.  
  2111.  
  2112. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteBackupSet - Related functions ΓòÉΓòÉΓòÉ
  2113.  
  2114.      PsnsCreateBackupSet 
  2115.  
  2116.      PsnsBackupSetInfo 
  2117.  
  2118.      PsnsSetBackupSetConfig 
  2119.  
  2120.      PsnsGetBackupSetConfig 
  2121.  
  2122.      PsnsListBackupSets 
  2123.  
  2124.      PsnsTransferBackupSet 
  2125.  
  2126.      PsnsTransferIn 
  2127.  
  2128.      PsnsGetLogFile 
  2129.  
  2130.      PsnsEmptyBackupSet 
  2131.  
  2132.  
  2133. ΓòÉΓòÉΓòÉ 3.27. PsnsDeleteEvent ΓòÉΓòÉΓòÉ
  2134.  
  2135. Select an item 
  2136.  
  2137.      Syntax 
  2138.      Parameters 
  2139.      Returns 
  2140.      Remarks 
  2141.      Example 
  2142.      Related functions 
  2143.  
  2144.  
  2145. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteEvent - Syntax ΓòÉΓòÉΓòÉ
  2146.  
  2147. /****************************************************/
  2148. /* This function deletes a scheduled event.         */
  2149. /****************************************************/
  2150.  
  2151. int PsnsDeleteEvent(PSNSHANDLE handle,
  2152.                     USHORT eventID);
  2153.  
  2154.  
  2155. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteEvent - Parameters ΓòÉΓòÉΓòÉ
  2156.  
  2157.  handle (PSNSHANDLE) 
  2158.            Handle returned by PsnsInit. 
  2159.  
  2160.  eventID (USHORT) 
  2161.            ID of the event to be deleted. 
  2162.  
  2163.  
  2164. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteEvent - Returns ΓòÉΓòÉΓòÉ
  2165.  
  2166.       PSNS_OK 
  2167.       PSNS_HANDLE_IN_USE 
  2168.       PSNS_COMMUNICATIONS_ERROR 
  2169.       PSNS_INVALID_HANDLE 
  2170.       PSNS_INVALID_EVENT 
  2171.       PSNS_IN_USE 
  2172.  
  2173.  
  2174. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteEvent - Remarks ΓòÉΓòÉΓòÉ
  2175.  
  2176. If an event exists with the given ID, it will be deleted. 
  2177.  
  2178.  
  2179. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteEvent - Related functions ΓòÉΓòÉΓòÉ
  2180.  
  2181.      PsnsCreateEvent 
  2182.  
  2183.      PsnsCopyEvent 
  2184.  
  2185.      PsnsEventInfo 
  2186.  
  2187.      PsnsListEvents 
  2188.  
  2189.      PsnsGetNextEvent 
  2190.  
  2191.      PsnsActivateEvent 
  2192.  
  2193.  
  2194. ΓòÉΓòÉΓòÉ 3.28. PsnsDeleteFileFilter ΓòÉΓòÉΓòÉ
  2195.  
  2196. Select an item 
  2197.  
  2198.      Syntax 
  2199.      Parameters 
  2200.      Returns 
  2201.      Remarks 
  2202.      Example 
  2203.      Related functions 
  2204.  
  2205.  
  2206. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteFileFilter - Syntax ΓòÉΓòÉΓòÉ
  2207.  
  2208. /****************************************************/
  2209. /* This function deletes a file filter.             */
  2210. /****************************************************/
  2211.  
  2212. int PsnsDeleteFileFilter(PSNSHANDLE handle,
  2213.                          const char *name);
  2214.  
  2215.  
  2216. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteFileFilter - Parameters ΓòÉΓòÉΓòÉ
  2217.  
  2218.  handle (PSNSHANDLE) 
  2219.            Handle returned by PsnsInit. 
  2220.  
  2221.  name (const char *) 
  2222.            Name of the file filter to be deleted. 
  2223.  
  2224.  
  2225. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteFileFilter - Returns ΓòÉΓòÉΓòÉ
  2226.  
  2227.       PSNS_OK 
  2228.       PSNS_HANDLE_IN_USE 
  2229.       PSNS_COMMUNICATIONS_ERROR 
  2230.       PSNS_INVALID_HANDLE 
  2231.       PSNS_INVALID_FILE_FILTER 
  2232.       PSNS_IN_USE 
  2233.  
  2234.  
  2235. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteFileFilter - Remarks ΓòÉΓòÉΓòÉ
  2236.  
  2237. If the named file filter exists, it will be deleted.  You should take care not 
  2238. to delete a file filter which is referenced by any backup methods; if you do 
  2239. then the backup methods will become invalid. 
  2240.  
  2241.  
  2242. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteFileFilter - Related functions ΓòÉΓòÉΓòÉ
  2243.  
  2244.      PsnsCreateFileFilter 
  2245.  
  2246.      PsnsRenameFileFilter 
  2247.  
  2248.      PsnsCopyFileFilter 
  2249.  
  2250.      PsnsFileFilterInfo 
  2251.  
  2252.      PsnsListFileFilters 
  2253.  
  2254.  
  2255. ΓòÉΓòÉΓòÉ 3.29. PsnsDeleteFileFilterRule ΓòÉΓòÉΓòÉ
  2256.  
  2257. Select an item 
  2258.  
  2259.      Syntax 
  2260.      Parameters 
  2261.      Returns 
  2262.      Remarks 
  2263.      Example 
  2264.      Related functions 
  2265.  
  2266.  
  2267. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteFileFilterRule - Syntax ΓòÉΓòÉΓòÉ
  2268.  
  2269. /****************************************************/
  2270. /* This function deletes a rule from a file filter. */
  2271. /****************************************************/
  2272.  
  2273. int PsnsDeleteFileFilterRule(PSNSHANDLE handle,
  2274.                              const char *fileFilter,
  2275.                              int which);
  2276.  
  2277.  
  2278. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteFileFilterRule - Parameters ΓòÉΓòÉΓòÉ
  2279.  
  2280.  handle (PSNSHANDLE) 
  2281.            Handle returned by PsnsInit. 
  2282.  
  2283.  fileFilter (const char *) 
  2284.            Name of the file filter from which to delete a rule. 
  2285.  
  2286.  which (int) 
  2287.            Number of the rule to be deleted (the first rule is 1). 
  2288.  
  2289.  
  2290. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteFileFilterRule - Returns ΓòÉΓòÉΓòÉ
  2291.  
  2292.       PSNS_OK 
  2293.       PSNS_HANDLE_IN_USE 
  2294.       PSNS_COMMUNICATIONS_ERROR 
  2295.       PSNS_INVALID_HANDLE 
  2296.       PSNS_INVALID_FILE_FILTER 
  2297.       PSNS_INVALID_POSITION 
  2298.       PSNS_IN_USE 
  2299.       PSNS_READONLY 
  2300.  
  2301.  
  2302. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteFileFilterRule - Remarks ΓòÉΓòÉΓòÉ
  2303.  
  2304. Use this function to delete a rule from a file filter. 
  2305.  
  2306.  
  2307. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteFileFilterRule - Related functions ΓòÉΓòÉΓòÉ
  2308.  
  2309.      PsnsAddFileFilterRule 
  2310.  
  2311.      PsnsFileFilterRuleInfo 
  2312.  
  2313.  
  2314. ΓòÉΓòÉΓòÉ 3.30. PsnsDeleteRestoreMethod ΓòÉΓòÉΓòÉ
  2315.  
  2316. Select an item 
  2317.  
  2318.      Syntax 
  2319.      Parameters 
  2320.      Returns 
  2321.      Remarks 
  2322.      Example 
  2323.      Related functions 
  2324.  
  2325.  
  2326. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRestoreMethod - Syntax ΓòÉΓòÉΓòÉ
  2327.  
  2328. /****************************************************/
  2329. /* This function deletes a restore method.          */
  2330. /****************************************************/
  2331.  
  2332. int PsnsDeleteRestoreMethod(PSNSHANDLE handle,
  2333.                             const char *name);
  2334.  
  2335.  
  2336. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRestoreMethod - Parameters ΓòÉΓòÉΓòÉ
  2337.  
  2338.  handle (PSNSHANDLE) 
  2339.            Handle returned by PsnsInit. 
  2340.  
  2341.  name (const char *) 
  2342.            Name of the restore method to be deleted. 
  2343.  
  2344.  
  2345. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRestoreMethod - Returns ΓòÉΓòÉΓòÉ
  2346.  
  2347.       PSNS_OK 
  2348.       PSNS_HANDLE_IN_USE 
  2349.       PSNS_COMMUNICATIONS_ERROR 
  2350.       PSNS_INVALID_HANDLE 
  2351.       PSNS_INVALID_RESTORE_METHOD 
  2352.       PSNS_IN_USE 
  2353.  
  2354.  
  2355. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRestoreMethod - Remarks ΓòÉΓòÉΓòÉ
  2356.  
  2357. If the named restore method exists, it will be deleted. 
  2358.  
  2359.  
  2360. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRestoreMethod - Related functions ΓòÉΓòÉΓòÉ
  2361.  
  2362.      PsnsCreateRestoreMethod 
  2363.  
  2364.      PsnsDeleteRestoreMethod 
  2365.  
  2366.      PsnsRenameRestoreMethod 
  2367.  
  2368.      PsnsCopyRestoreMethod 
  2369.  
  2370.      PsnsRestoreMethodInfo 
  2371.  
  2372.      PsnsListRestoreMethods 
  2373.  
  2374.      PsnsEstimateRestoreMethod 
  2375.  
  2376.      PsnsRunRestoreMethod 
  2377.  
  2378.  
  2379. ΓòÉΓòÉΓòÉ 3.31. PsnsDeleteRulebook ΓòÉΓòÉΓòÉ
  2380.  
  2381. Select an item 
  2382.  
  2383.      Syntax 
  2384.      Parameters 
  2385.      Returns 
  2386.      Remarks 
  2387.      Example 
  2388.      Related functions 
  2389.  
  2390.  
  2391. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRulebook - Syntax ΓòÉΓòÉΓòÉ
  2392.  
  2393. /****************************************************/
  2394. /* This function deletes a rulebook.                */
  2395. /****************************************************/
  2396.  
  2397. int PsnsDeleteRulebook(PSNSHANDLE handle,
  2398.                        const char *name);
  2399.  
  2400.  
  2401. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRulebook - Parameters ΓòÉΓòÉΓòÉ
  2402.  
  2403.  handle (PSNSHANDLE) 
  2404.            Handle returned by PsnsInit. 
  2405.  
  2406.  name (const char *) 
  2407.            Name of the rulebook to be deleted. 
  2408.  
  2409.  
  2410. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRulebook - Returns ΓòÉΓòÉΓòÉ
  2411.  
  2412.       PSNS_OK 
  2413.       PSNS_HANDLE_IN_USE 
  2414.       PSNS_COMMUNICATIONS_ERROR 
  2415.       PSNS_INVALID_HANDLE 
  2416.       PSNS_INVALID_RULEBOOK 
  2417.       PSNS_IN_USE 
  2418.  
  2419.  
  2420. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRulebook - Remarks ΓòÉΓòÉΓòÉ
  2421.  
  2422. If the named rulebook exists, it will be deleted.  You should take care not to 
  2423. delete a rulebook which is referenced by any backup methods; if you do then the 
  2424. backup methods will become invalid. 
  2425.  
  2426.  
  2427. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRulebook - Related functions ΓòÉΓòÉΓòÉ
  2428.  
  2429.      PsnsCreateRulebook 
  2430.  
  2431.      PsnsRenameRulebook 
  2432.  
  2433.      PsnsCopyRulebook 
  2434.  
  2435.      PsnsRulebookInfo 
  2436.  
  2437.      PsnsListRulebooks 
  2438.  
  2439.  
  2440. ΓòÉΓòÉΓòÉ 3.32. PsnsDeleteRulebookRule ΓòÉΓòÉΓòÉ
  2441.  
  2442. Select an item 
  2443.  
  2444.      Syntax 
  2445.      Parameters 
  2446.      Returns 
  2447.      Remarks 
  2448.      Example 
  2449.      Related functions 
  2450.  
  2451.  
  2452. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRulebookRule - Syntax ΓòÉΓòÉΓòÉ
  2453.  
  2454. /****************************************************/
  2455. /* This function deletes a rule from a rulebook.    */
  2456. /****************************************************/
  2457.  
  2458. int PsnsDeleteRulebookRule(PSNSHANDLE handle,
  2459.                            const char *rulebook,
  2460.                            int which);
  2461.  
  2462.  
  2463. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRulebookRule - Parameters ΓòÉΓòÉΓòÉ
  2464.  
  2465.  handle (PSNSHANDLE) 
  2466.            Handle returned by PsnsInit. 
  2467.  
  2468.  rulebook (const char *) 
  2469.            Name of the rulebook from which to delete a rule. 
  2470.  
  2471.  which (int) 
  2472.            Number of the rule to be deleted, (the first rule is 1). 
  2473.  
  2474.  
  2475. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRulebookRule - Returns ΓòÉΓòÉΓòÉ
  2476.  
  2477.       PSNS_OK 
  2478.       PSNS_HANDLE_IN_USE 
  2479.       PSNS_COMMUNICATIONS_ERROR 
  2480.       PSNS_INVALID_HANDLE 
  2481.       PSNS_INVALID_RULEBOOK 
  2482.       PSNS_INVALID_POSITION 
  2483.       PSNS_IN_USE 
  2484.  
  2485.  
  2486. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRulebookRule - Remarks ΓòÉΓòÉΓòÉ
  2487.  
  2488. Use this function to delete a rule from a rulebook. 
  2489.  
  2490.  
  2491. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteRulebookRule - Related functions ΓòÉΓòÉΓòÉ
  2492.  
  2493.      PsnsAddRulebookRule 
  2494.  
  2495.      PsnsRulebookRuleInfo 
  2496.  
  2497.  
  2498. ΓòÉΓòÉΓòÉ 3.33. PsnsDeleteStorageDevice ΓòÉΓòÉΓòÉ
  2499.  
  2500. Select an item 
  2501.  
  2502.      Syntax 
  2503.      Parameters 
  2504.      Returns 
  2505.      Remarks 
  2506.      Example 
  2507.      Related functions 
  2508.  
  2509.  
  2510. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteStorageDevice - Syntax ΓòÉΓòÉΓòÉ
  2511.  
  2512. /****************************************************/
  2513. /* This function deletes a storage device.          */
  2514. /****************************************************/
  2515.  
  2516. int PsnsDeleteStorageDevice(PSNSHANDLE handle,
  2517.                             const char *name);
  2518.  
  2519.  
  2520. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteStorageDevice - Parameters ΓòÉΓòÉΓòÉ
  2521.  
  2522.  handle (PSNSHANDLE) 
  2523.            Handle returned by PsnsInit. 
  2524.  
  2525.  name (const char *) 
  2526.            Name of the storage device to be deleted. 
  2527.  
  2528.  
  2529. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteStorageDevice - Returns ΓòÉΓòÉΓòÉ
  2530.  
  2531.       PSNS_OK 
  2532.       PSNS_HANDLE_IN_USE 
  2533.       PSNS_COMMUNICATIONS_ERROR 
  2534.       PSNS_INVALID_HANDLE 
  2535.       PSNS_INVALID_STORAGE_DEVICE 
  2536.       PSNS_IN_USE 
  2537.       PSNS_CANNOT_DELETE 
  2538.  
  2539.  
  2540. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteStorageDevice - Remarks ΓòÉΓòÉΓòÉ
  2541.  
  2542. Use this function to delete a storage device.  Some storage devices cannot be 
  2543. deleted; you also cannot delete a storage device which has any backup sets 
  2544. associated with it. 
  2545.  
  2546.  
  2547. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteStorageDevice - Related functions ΓòÉΓòÉΓòÉ
  2548.  
  2549.      PsnsCreateStorageDevice 
  2550.  
  2551.      PsnsStorageDeviceInfo 
  2552.  
  2553.      PsnsSetStorageDeviceConfig 
  2554.  
  2555.      PsnsGetStorageDeviceConfig 
  2556.  
  2557.      PsnsListStorageDevices 
  2558.  
  2559.      PsnsRefreshStorageDevices 
  2560.  
  2561.  
  2562. ΓòÉΓòÉΓòÉ 3.34. PsnsDeleteVolume ΓòÉΓòÉΓòÉ
  2563.  
  2564. Select an item 
  2565.  
  2566.      Syntax 
  2567.      Parameters 
  2568.      Returns 
  2569.      Remarks 
  2570.      Example 
  2571.      Related functions 
  2572.  
  2573.  
  2574. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteVolume - Syntax ΓòÉΓòÉΓòÉ
  2575.  
  2576. /****************************************************/
  2577. /* This function deletes a volume.                  */
  2578. /****************************************************/
  2579.  
  2580. int PsnsDeleteVolume(PSNSHANDLE handle,
  2581.                      ULONG volumeID);
  2582.  
  2583.  
  2584. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteVolume - Parameters ΓòÉΓòÉΓòÉ
  2585.  
  2586.  handle (PSNSHANDLE) 
  2587.            Handle returned by PsnsInit. 
  2588.  
  2589.  volumeID (ULONG) 
  2590.            ID of the volume to be deleted. 
  2591.  
  2592.  
  2593. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteVolume - Returns ΓòÉΓòÉΓòÉ
  2594.  
  2595.       PSNS_OK 
  2596.       PSNS_HANDLE_IN_USE 
  2597.       PSNS_COMMUNICATIONS_ERROR 
  2598.       PSNS_INVALID_HANDLE 
  2599.       PSNS_INVALID_VOLUME 
  2600.       PSNS_IN_USE 
  2601.       PSNS_CANNOT_DELETE 
  2602.       PSNS_FIXED_VOLUME 
  2603.  
  2604.  
  2605. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteVolume - Remarks ΓòÉΓòÉΓòÉ
  2606.  
  2607. Use this function to delete a volume.  Any data backed up to the volume will be 
  2608. lost.  Fixed volumes (such as local fixed disks) cannot be deleted. 
  2609.  
  2610.  
  2611. ΓòÉΓòÉΓòÉ <hidden> PsnsDeleteVolume - Related functions ΓòÉΓòÉΓòÉ
  2612.  
  2613.      PsnsCreateVolume 
  2614.  
  2615.      PsnsVolumeInfo 
  2616.  
  2617.      PsnsListVolumes 
  2618.  
  2619.      PsnsListVolumeBackupSets 
  2620.  
  2621.      PsnsActivateVolume 
  2622.  
  2623.      PsnsAssociateVolume 
  2624.  
  2625.  
  2626. ΓòÉΓòÉΓòÉ 3.35. PsnsDropFiles ΓòÉΓòÉΓòÉ
  2627.  
  2628. Select an item 
  2629.  
  2630.      Syntax 
  2631.      Parameters 
  2632.      Returns 
  2633.      Remarks 
  2634.      Example 
  2635.      Related functions 
  2636.  
  2637.  
  2638. ΓòÉΓòÉΓòÉ <hidden> PsnsDropFiles - Syntax ΓòÉΓòÉΓòÉ
  2639.  
  2640. /****************************************************/
  2641. /* This function removes backed-up data for a list  */
  2642. /* of files from a backup set.                      */
  2643. /****************************************************/
  2644.  
  2645. int PsnsDropFiles(PSNSHANDLE handle,
  2646.                   const char *backupSet
  2647.                   PSNSSTATSFN psnsStatsFn);
  2648.  
  2649.  
  2650. ΓòÉΓòÉΓòÉ <hidden> PsnsDropFiles - Parameters ΓòÉΓòÉΓòÉ
  2651.  
  2652.  handle (PSNSHANDLE) 
  2653.            Handle returned by PsnsInit. 
  2654.  
  2655.  backupSet (const char *) 
  2656.            Name of the backup set from which to drop file(s). 
  2657.  
  2658.  psnsStatsFn (PSNSSTATSFN) 
  2659.            Pointer to a statistics callback function.  This can be NULL. 
  2660.  
  2661.  
  2662. ΓòÉΓòÉΓòÉ <hidden> PsnsDropFiles - Returns ΓòÉΓòÉΓòÉ
  2663.  
  2664.       PSNS_OK 
  2665.       PSNS_HANDLE_IN_USE 
  2666.       PSNS_COMMUNICATIONS_ERROR 
  2667.       PSNS_INVALID_HANDLE 
  2668.       PSNS_INVALID_BACKUP_SET 
  2669.       PSNS_FILE_NOT_FOUND 
  2670.       PSNS_ARCHIVE_ERROR 
  2671.       PSNS_TRANSFERRED_OUT 
  2672.  
  2673.  
  2674. ΓòÉΓòÉΓòÉ <hidden> PsnsDropFiles - Remarks ΓòÉΓòÉΓòÉ
  2675.  
  2676. Use this function to remove information about a list of files from a backup 
  2677. set.  After this, you will no longer be able to restore the generation(s) of 
  2678. the file(s) you have dropped.  OS/2 Warp Server Backup/Restore will be able to 
  2679. reuse the space on the volume(s) taken up by these files. 
  2680.  
  2681. Before calling this function, you should list the files and generations you 
  2682. want to drop by calling PsnsAddFile. 
  2683.  
  2684.  
  2685. ΓòÉΓòÉΓòÉ <hidden> PsnsDropFiles - Related functions ΓòÉΓòÉΓòÉ
  2686.  
  2687.      PsnsListFiles 
  2688.  
  2689.      PsnsAddFile 
  2690.  
  2691.      PsnsPurgeFiles 
  2692.  
  2693.  
  2694. ΓòÉΓòÉΓòÉ 3.36. PsnsEmptyBackupSet ΓòÉΓòÉΓòÉ
  2695.  
  2696. Select an item 
  2697.  
  2698.      Syntax 
  2699.      Parameters 
  2700.      Returns 
  2701.      Remarks 
  2702.      Example 
  2703.      Related functions 
  2704.  
  2705.  
  2706. ΓòÉΓòÉΓòÉ <hidden> PsnsEmptyBackupSet - Syntax ΓòÉΓòÉΓòÉ
  2707.  
  2708. /****************************************************/
  2709. /* This function destroys all backed-up data in a   */
  2710. /* backup set.                                      */
  2711. /****************************************************/
  2712.  
  2713. int PsnsEmptyBackupSet(PSNSHANDLE handle,
  2714.                        const char *name);
  2715.  
  2716.  
  2717. ΓòÉΓòÉΓòÉ <hidden> PsnsEmptyBackupSet - Parameters ΓòÉΓòÉΓòÉ
  2718.  
  2719.  handle (PSNSHANDLE) 
  2720.            Handle returned by PsnsInit. 
  2721.  
  2722.  name (const char *) 
  2723.            Name of the backup set to be emptied. 
  2724.  
  2725.  
  2726. ΓòÉΓòÉΓòÉ <hidden> PsnsEmptyBackupSet - Returns ΓòÉΓòÉΓòÉ
  2727.  
  2728.       PSNS_OK 
  2729.       PSNS_HANDLE_IN_USE 
  2730.       PSNS_COMMUNICATIONS_ERROR 
  2731.       PSNS_INVALID_HANDLE 
  2732.       PSNS_INVALID_BACKUP_SET 
  2733.       PSNS_IN_USE 
  2734.       PSNS_ARCHIVE_ERROR 
  2735.       PSNS_TRANSFERRED_OUT 
  2736.  
  2737.  
  2738. ΓòÉΓòÉΓòÉ <hidden> PsnsEmptyBackupSet - Remarks ΓòÉΓòÉΓòÉ
  2739.  
  2740. Use this function to destroy all backed-up data in a backup set.  You will no 
  2741. longer be able to restore any of the files backed up to this backup set and 
  2742. OS/2 Warp Server Backup/Restore will be able to reuse the volumes which the 
  2743. backup set uses.  The backup set itself is not deleted. 
  2744.  
  2745.  
  2746. ΓòÉΓòÉΓòÉ <hidden> PsnsEmptyBackupSet - Related functions ΓòÉΓòÉΓòÉ
  2747.  
  2748.      PsnsCreateBackupSet 
  2749.  
  2750.      PsnsDeleteBackupSet 
  2751.  
  2752.      PsnsBackupSetInfo 
  2753.  
  2754.      PsnsSetBackupSetConfig 
  2755.  
  2756.      PsnsGetBackupSetConfig 
  2757.  
  2758.      PsnsListBackupSets 
  2759.  
  2760.      PsnsTransferBackupSet 
  2761.  
  2762.      PsnsTransferIn 
  2763.  
  2764.      PsnsGetLogFile 
  2765.  
  2766.      PsnsDeleteVolume 
  2767.  
  2768.  
  2769. ΓòÉΓòÉΓòÉ 3.37. PsnsEstimateBackupMethod ΓòÉΓòÉΓòÉ
  2770.  
  2771. Select an item 
  2772.  
  2773.      Syntax 
  2774.      Parameters 
  2775.      Returns 
  2776.      Remarks 
  2777.      Example 
  2778.      Related functions 
  2779.  
  2780.  
  2781. ΓòÉΓòÉΓòÉ <hidden> PsnsEstimateBackupMethod - Syntax ΓòÉΓòÉΓòÉ
  2782.  
  2783. /****************************************************/
  2784. /* This function counts the files and folders which */
  2785. /* would be backed up by a given backup method and  */
  2786. /* calculates the estimated time for the backup.    */
  2787. /****************************************************/
  2788.  
  2789. int PsnsEstimateBackupMethod(PSNSHANDLE handle,
  2790.                              const char *name,
  2791.                              PESTIMATE pEstimate);
  2792.  
  2793.  
  2794. ΓòÉΓòÉΓòÉ <hidden> PsnsEstimateBackupMethod - Parameters ΓòÉΓòÉΓòÉ
  2795.  
  2796.  handle (PSNSHANDLE) 
  2797.            Handle returned by PsnsInit. 
  2798.  
  2799.  name (const char *) 
  2800.            Name of the backup method to be estimated. 
  2801.  
  2802.  pEstimate (PESTIMATE) 
  2803.            Pointer to an ESTIMATE structure to receive the information. 
  2804.  
  2805.  
  2806. ΓòÉΓòÉΓòÉ <hidden> PsnsEstimateBackupMethod - Returns ΓòÉΓòÉΓòÉ
  2807.  
  2808.       PSNS_OK 
  2809.       PSNS_HANDLE_IN_USE 
  2810.       PSNS_COMMUNICATIONS_ERROR 
  2811.       PSNS_INVALID_HANDLE 
  2812.       PSNS_INVALID_BACKUP_METHOD 
  2813.  
  2814.  
  2815. ΓòÉΓòÉΓòÉ <hidden> PsnsEstimateBackupMethod - Remarks ΓòÉΓòÉΓòÉ
  2816.  
  2817. Use this function to scan for files and folders which would be backed up by a 
  2818. backup method, and estimate how long the backup would take.  OS/2 Warp Server 
  2819. Backup/Restore calculates the estimated time based on past backups to the same 
  2820. storage device. 
  2821.  
  2822.  
  2823. ΓòÉΓòÉΓòÉ <hidden> PsnsEstimateBackupMethod - Related functions ΓòÉΓòÉΓòÉ
  2824.  
  2825.      PsnsRunBackupMethod 
  2826.  
  2827.  
  2828. ΓòÉΓòÉΓòÉ 3.38. PsnsEstimateRestoreMethod ΓòÉΓòÉΓòÉ
  2829.  
  2830. Select an item 
  2831.  
  2832.      Syntax 
  2833.      Parameters 
  2834.      Returns 
  2835.      Remarks 
  2836.      Example 
  2837.      Related functions 
  2838.  
  2839.  
  2840. ΓòÉΓòÉΓòÉ <hidden> PsnsEstimateRestoreMethod - Syntax ΓòÉΓòÉΓòÉ
  2841.  
  2842. /****************************************************/
  2843. /* This function counts the files and folders which */
  2844. /* would be restored by a given restore method.     */
  2845. /****************************************************/
  2846.  
  2847. int PsnsEstimateRestoreMethod(PSNSHANDLE handle,
  2848.                               const char *name,
  2849.                               PESTIMATE pEstimate);
  2850.  
  2851.  
  2852. ΓòÉΓòÉΓòÉ <hidden> PsnsEstimateRestoreMethod - Parameters ΓòÉΓòÉΓòÉ
  2853.  
  2854.  handle (PSNSHANDLE) 
  2855.            Handle returned by PsnsInit. 
  2856.  
  2857.  name (const char *) 
  2858.            Name of the restore method to be estimated. 
  2859.  
  2860.  pEstimate (PESTIMATE) 
  2861.            Pointer to an ESTIMATE structure to receive the information. 
  2862.  
  2863.  
  2864. ΓòÉΓòÉΓòÉ <hidden> PsnsEstimateRestoreMethod - Returns ΓòÉΓòÉΓòÉ
  2865.  
  2866.       PSNS_OK 
  2867.       PSNS_HANDLE_IN_USE 
  2868.       PSNS_COMMUNICATIONS_ERROR 
  2869.       PSNS_INVALID_HANDLE 
  2870.       PSNS_INVALID_RESTORE_METHOD 
  2871.       PSNS_ARCHIVE_ERROR 
  2872.  
  2873.  
  2874. ΓòÉΓòÉΓòÉ <hidden> PsnsEstimateRestoreMethod - Remarks ΓòÉΓòÉΓòÉ
  2875.  
  2876. Use this function to scan for files and folders which would be restored by a 
  2877. restore method. 
  2878.  
  2879.  
  2880. ΓòÉΓòÉΓòÉ <hidden> PsnsEstimateRestoreMethod - Related functions ΓòÉΓòÉΓòÉ
  2881.  
  2882.      PsnsRunRestoreMethod 
  2883.  
  2884.  
  2885. ΓòÉΓòÉΓòÉ 3.39. PsnsEventInfo ΓòÉΓòÉΓòÉ
  2886.  
  2887. Select an item 
  2888.  
  2889.      Syntax 
  2890.      Parameters 
  2891.      Returns 
  2892.      Remarks 
  2893.      Example 
  2894.      Related functions 
  2895.  
  2896.  
  2897. ΓòÉΓòÉΓòÉ <hidden> PsnsEventInfo - Syntax ΓòÉΓòÉΓòÉ
  2898.  
  2899. /****************************************************/
  2900. /* This function gets or sets all the information   */
  2901. /* about a scheduled event.                         */
  2902. /****************************************************/
  2903.  
  2904. int PsnsEventInfo(PSNSHANDLE handle,
  2905.                   USHORT eventID,
  2906.                   PEVENTINFO pEventInfo,
  2907.                   long mask);
  2908.  
  2909.  
  2910. ΓòÉΓòÉΓòÉ <hidden> PsnsEventInfo - Parameters ΓòÉΓòÉΓòÉ
  2911.  
  2912.  handle (PSNSHANDLE) 
  2913.            Handle returned by PsnsInit. 
  2914.  
  2915.  eventID (USHORT) 
  2916.            ID of the event to be inspected or changed. 
  2917.  
  2918.  pEventInfo (PEVENTINFO) 
  2919.            Pointer to an EVENTINFO structure which contains the new settings if 
  2920.            they are to be changed, and to receive the current settings.  If the 
  2921.            corresponding bit in mask is set then the settings will be changed 
  2922.            to what is passed in this structure.  The new settings are returned 
  2923.            in this structure.  To get the settings without changing them, set 
  2924.            mask = EV_NONE. 
  2925.  
  2926.  mask (long) 
  2927.            Possible values: 
  2928.  
  2929.                 EV_NONE 
  2930.                 EV_BACKUPMETHOD 
  2931.                 EV_HOURS 
  2932.                 EV_MINUTES 
  2933.                 EV_DAY 
  2934.                 EV_DAYS 
  2935.                 EV_WEEKS 
  2936.                 EV_CHANGEDFILESONLY 
  2937.                 EV_SHOWPREVIEW 
  2938.                 EV_ACTIVE 
  2939.                 EV_ALL 
  2940.  
  2941.            To set more than one setting, OR the different values together.  To 
  2942.            set all the settings, use mask = EV_ALL. 
  2943.  
  2944.  
  2945. ΓòÉΓòÉΓòÉ <hidden> PsnsEventInfo - Returns ΓòÉΓòÉΓòÉ
  2946.  
  2947.       PSNS_OK 
  2948.       PSNS_HANDLE_IN_USE 
  2949.       PSNS_COMMUNICATIONS_ERROR 
  2950.       PSNS_INVALID_HANDLE 
  2951.       PSNS_INVALID_EVENT 
  2952.       PSNS_IN_USE 
  2953.       PSNS_INVALID_BACKUP_METHOD 
  2954.       PSNS_INVALID_TIME 
  2955.       PSNS_INVALID_MASK 
  2956.  
  2957.  
  2958. ΓòÉΓòÉΓòÉ <hidden> PsnsEventInfo - Remarks ΓòÉΓòÉΓòÉ
  2959.  
  2960. Use this function to change an event or to inspect the current settings for an 
  2961. event.  The mask parameter defines which settings are being changed.  For more 
  2962. information on the individual fields, see EVENTINFO. 
  2963.  
  2964. It is not possible to change the type of an event with this call; you must 
  2965. delete the event and create a new one. 
  2966.  
  2967.  
  2968. ΓòÉΓòÉΓòÉ <hidden> PsnsEventInfo - Related functions ΓòÉΓòÉΓòÉ
  2969.  
  2970.      PsnsCreateEvent 
  2971.  
  2972.      PsnsDeleteEvent 
  2973.  
  2974.      PsnsCopyEvent 
  2975.  
  2976.      PsnsListEvents 
  2977.  
  2978.      PsnsGetNextEvent 
  2979.  
  2980.      PsnsActivateEvent 
  2981.  
  2982.  
  2983. ΓòÉΓòÉΓòÉ 3.40. PsnsFileFilterInfo ΓòÉΓòÉΓòÉ
  2984.  
  2985. Select an item 
  2986.  
  2987.      Syntax 
  2988.      Parameters 
  2989.      Returns 
  2990.      Remarks 
  2991.      Example 
  2992.      Related functions 
  2993.  
  2994.  
  2995. ΓòÉΓòÉΓòÉ <hidden> PsnsFileFilterInfo - Syntax ΓòÉΓòÉΓòÉ
  2996.  
  2997. /****************************************************/
  2998. /* This function gets or sets all the information   */
  2999. /* about a file filter.                             */
  3000. /****************************************************/
  3001.  
  3002. int PsnsFileFilterInfo(PSNSHANDLE handle,
  3003.                        const char *name,
  3004.                        PFILEFILTERINFO pFileFilterInfo,
  3005.                        long mask);
  3006.  
  3007.  
  3008. ΓòÉΓòÉΓòÉ <hidden> PsnsFileFilterInfo - Parameters ΓòÉΓòÉΓòÉ
  3009.  
  3010.  handle (PSNSHANDLE) 
  3011.            Handle returned by PsnsInit. 
  3012.  
  3013.  name (const char *) 
  3014.            Name of the file filter to be inspected or changed. 
  3015.  
  3016.  pFileFilterInfo (PFILEFILTERINFO) 
  3017.            Pointer to a FILEFILTERINFO structure which contains the new 
  3018.            settings if they are to be changed, and to receive the current 
  3019.            settings.  If the corresponding bit in mask is set then the settings 
  3020.            will be changed to what is passed in this structure.  The new 
  3021.            settings are returned in this structure.  To get the settings 
  3022.            without changing them, set mask = FF_NONE. 
  3023.  
  3024.  mask (long) 
  3025.            Possible values: 
  3026.  
  3027.                 FF_NONE 
  3028.                 FF_TYPE 
  3029.                 FF_DESCRIPTION 
  3030.                 FF_ALL 
  3031.  
  3032.            To set more than one setting, OR the different values together.  To 
  3033.            set all the settings, use mask = FF_ALL. 
  3034.  
  3035.  
  3036. ΓòÉΓòÉΓòÉ <hidden> PsnsFileFilterInfo - Returns ΓòÉΓòÉΓòÉ
  3037.  
  3038.       PSNS_OK 
  3039.       PSNS_HANDLE_IN_USE 
  3040.       PSNS_COMMUNICATIONS_ERROR 
  3041.       PSNS_INVALID_HANDLE 
  3042.       PSNS_INVALID_FILE_FILTER 
  3043.       PSNS_IN_USE 
  3044.       PSNS_INVALID_FILE_FILTER_TYPE 
  3045.       PSNS_INVALID_MASK 
  3046.  
  3047.  
  3048. ΓòÉΓòÉΓòÉ <hidden> PsnsFileFilterInfo - Remarks ΓòÉΓòÉΓòÉ
  3049.  
  3050. Use this function to change a file filter or to inspect the current settings 
  3051. for a file filter.  The mask parameter defines which settings are being 
  3052. changed.  For more information on the individual fields, see FILEFILTERINFO. 
  3053.  
  3054. It is not possible to change the name of a file filter with this call; to do 
  3055. that, use PsnsRenameFileFilter. 
  3056.  
  3057.  
  3058. ΓòÉΓòÉΓòÉ <hidden> PsnsFileFilterInfo - Related functions ΓòÉΓòÉΓòÉ
  3059.  
  3060.      PsnsCreateFileFilter 
  3061.  
  3062.      PsnsDeleteFileFilter 
  3063.  
  3064.      PsnsRenameFileFilter 
  3065.  
  3066.      PsnsCopyFileFilter 
  3067.  
  3068.      PsnsListFileFilters 
  3069.  
  3070.      PsnsAddFileFilterRule 
  3071.  
  3072.      PsnsDeleteFileFilterRule 
  3073.  
  3074.      PsnsFileFilterRuleInfo 
  3075.  
  3076.  
  3077. ΓòÉΓòÉΓòÉ 3.41. PsnsFileFilterRuleInfo ΓòÉΓòÉΓòÉ
  3078.  
  3079. Select an item 
  3080.  
  3081.      Syntax 
  3082.      Parameters 
  3083.      Returns 
  3084.      Remarks 
  3085.      Example 
  3086.      Related functions 
  3087.  
  3088.  
  3089. ΓòÉΓòÉΓòÉ <hidden> PsnsFileFilterRuleInfo - Syntax ΓòÉΓòÉΓòÉ
  3090.  
  3091. /****************************************************/
  3092. /* This function gets or sets all the information   */
  3093. /* about a rule in a file filter.                   */
  3094. /****************************************************/
  3095.  
  3096. int PsnsFileFilterRuleInfo(PSNSHANDLE handle,
  3097.                            const char *fileFilter,
  3098.                            int which,
  3099.                            PFILEFILTERRULE pFileFilterRule,
  3100.                            long mask);
  3101.  
  3102.  
  3103. ΓòÉΓòÉΓòÉ <hidden> PsnsFileFilterRuleInfo - Parameters ΓòÉΓòÉΓòÉ
  3104.  
  3105.  handle (PSNSHANDLE) 
  3106.            Handle returned by PsnsInit. 
  3107.  
  3108.  fileFilter (const char *) 
  3109.            Name of the file filter to be inspected or changed. 
  3110.  
  3111.  which (int) 
  3112.            Number of the rule to be inspected or changed (the first rule is 1). 
  3113.  
  3114.  pFileFilterRule (FILEFILTERRULE) 
  3115.            Pointer to a FILEFILTERRULE structure which contains the new 
  3116.            settings if they are to be changed, and to receive the current 
  3117.            settings.  If the corresponding bit in mask is set then the settings 
  3118.            will be changed to what is passed in this structure.  The new 
  3119.            settings are returned in this structure.  To get the settings 
  3120.            without changing them, set mask = FF_NONE. 
  3121.  
  3122.  mask (long) 
  3123.            Possible values: 
  3124.  
  3125.                 FF_NONE 
  3126.                 FF_DRIVE 
  3127.                 FF_DIRECTORY 
  3128.                 FF_PATTERN 
  3129.                 FF_INCLUDE 
  3130.                 FF_SUBDIRECTORIES 
  3131.                 FF_ALL 
  3132.  
  3133.            To set more than one setting, OR the different values together.  To 
  3134.            set all the settings, use mask = FF_ALL. 
  3135.  
  3136.  
  3137. ΓòÉΓòÉΓòÉ <hidden> PsnsFileFilterRuleInfo - Returns ΓòÉΓòÉΓòÉ
  3138.  
  3139.       PSNS_OK 
  3140.       PSNS_HANDLE_IN_USE 
  3141.       PSNS_COMMUNICATIONS_ERROR 
  3142.       PSNS_INVALID_HANDLE 
  3143.       PSNS_INVALID_FILE_FILTER 
  3144.       PSNS_IN_USE 
  3145.       PSNS_INVALID_POSITION 
  3146.       PSNS_INVALID_DRIVE 
  3147.       PSNS_INVALID_PATH 
  3148.       PSNS_INVALID_FILENAME 
  3149.       PSNS_READONLY 
  3150.       PSNS_INVALID_MASK 
  3151.  
  3152.  
  3153. ΓòÉΓòÉΓòÉ <hidden> PsnsFileFilterRuleInfo - Remarks ΓòÉΓòÉΓòÉ
  3154.  
  3155. Use this function to change a file filter rule or to inspect the current 
  3156. settings for a file filter rule.  The mask parameter defines which settings are 
  3157. being changed.  For more information on the individual fields, see 
  3158. FILEFILTERRULE. 
  3159.  
  3160.  
  3161. ΓòÉΓòÉΓòÉ <hidden> PsnsFileFilterRuleInfo - Related functions ΓòÉΓòÉΓòÉ
  3162.  
  3163.      PsnsFileFilterInfo 
  3164.  
  3165.      PsnsAddFileFilterRule 
  3166.  
  3167.      PsnsDeleteFileFilterRule 
  3168.  
  3169.  
  3170. ΓòÉΓòÉΓòÉ 3.42. PsnsGetBackupSetConfig ΓòÉΓòÉΓòÉ
  3171.  
  3172. Select an item 
  3173.  
  3174.      Syntax 
  3175.      Parameters 
  3176.      Returns 
  3177.      Remarks 
  3178.      Example 
  3179.      Related functions 
  3180.  
  3181.  
  3182. ΓòÉΓòÉΓòÉ <hidden> PsnsGetBackupSetConfig - Syntax ΓòÉΓòÉΓòÉ
  3183.  
  3184. /****************************************************/
  3185. /* This function gets the configuration information */
  3186. /* for a backup set.                                */
  3187. /****************************************************/
  3188.  
  3189. int PsnsGetBackupSetConfig(PSNSHANDLE handle,
  3190.                            const char *name,
  3191.                            char *config,
  3192.                            PULONG length,
  3193.                            char *incConfig,
  3194.                            PULONG incLength);
  3195.  
  3196.  
  3197. ΓòÉΓòÉΓòÉ <hidden> PsnsGetBackupSetConfig - Parameters ΓòÉΓòÉΓòÉ
  3198.  
  3199.  handle (PSNSHANDLE) 
  3200.            Handle returned by PsnsInit. 
  3201.  
  3202.  name (const char *) 
  3203.            Name of the backup set to be inspected. 
  3204.  
  3205.  config (char *) 
  3206.            Pointer to a buffer to receive the configuration information, may be 
  3207.            NULL.  For dual device backup sets this is the configuration string 
  3208.            for the base storage device. 
  3209.  
  3210.  length (PULONG) 
  3211.            If the config parameter is NULL this parameter may also be passed as 
  3212.            NULL. 
  3213.  
  3214.            Input          Size of the buffer pointed to by config. 
  3215.            Output         Size of the buffer needed to contain the complete 
  3216.                           configuration string including the terminating NULL. 
  3217.  
  3218.  incConfig (char *) 
  3219.            For dual device backup sets this is a pointer to a buffer to receive 
  3220.            the configuration information for the incremental storage device, 
  3221.            may be NULL.  For single device backup sets this parameter should be 
  3222.            passed as NULL. 
  3223.  
  3224.  incLength (PULONG) 
  3225.            If the incConfig parameter is NULL this parameter may also be passed 
  3226.            as NULL. 
  3227.  
  3228.            Input          Size of the buffer pointed to by incConfig. 
  3229.            Output         Size of the buffer needed to contain the complete 
  3230.                           configuration string including the terminating NULL. 
  3231.  
  3232.  
  3233. ΓòÉΓòÉΓòÉ <hidden> PsnsGetBackupSetConfig - Returns ΓòÉΓòÉΓòÉ
  3234.  
  3235.       PSNS_OK 
  3236.       PSNS_HANDLE_IN_USE 
  3237.       PSNS_COMMUNICATIONS_ERROR 
  3238.       PSNS_INVALID_HANDLE 
  3239.       PSNS_INVALID_BACKUP_SET 
  3240.       PSNS_TOO_MUCH_DATA 
  3241.       PSNS_TRANSFERRED_OUT 
  3242.  
  3243.  
  3244. ΓòÉΓòÉΓòÉ <hidden> PsnsGetBackupSetConfig - Remarks ΓòÉΓòÉΓòÉ
  3245.  
  3246. Use this function to get the current configuration information for a backup 
  3247. set, or find out how large a buffer is needed to hold that information. The 
  3248. format of this information depends on the storage device which the backup set 
  3249. uses; to find out how all the standard OS/2 Warp Server Backup/Restore storage 
  3250. devices handle this, see Storage Device Configuration. 
  3251.  
  3252.  
  3253. ΓòÉΓòÉΓòÉ <hidden> PsnsGetBackupSetConfig - Related functions ΓòÉΓòÉΓòÉ
  3254.  
  3255.      PsnsSetBackupSetConfig 
  3256.  
  3257.      PsnsSetStorageDeviceConfig 
  3258.  
  3259.      PsnsGetStorageDeviceConfig 
  3260.  
  3261.      PsnsTransferIn 
  3262.  
  3263.  
  3264. ΓòÉΓòÉΓòÉ <hidden> PsnsGetFileGeneration ΓòÉΓòÉΓòÉ
  3265.  
  3266. Select an item 
  3267.  
  3268.      Syntax 
  3269.      Parameters 
  3270.      Returns 
  3271.      Remarks 
  3272.      Related functions 
  3273.  
  3274.  
  3275. ΓòÉΓòÉΓòÉ <hidden> PsnsGetFileGeneration - Syntax ΓòÉΓòÉΓòÉ
  3276.  
  3277. /****************************************************/
  3278. /* This function gets information about one         */
  3279. /* generation of a backed-up file.                  */
  3280. /****************************************************/
  3281.  
  3282. int PsnsGetFileGeneration(PSNSHANDLE handle,
  3283.                           PPSNSFILEINFO pPsnsFileInfo);
  3284.  
  3285.  
  3286. ΓòÉΓòÉΓòÉ <hidden> PsnsGetFileGeneration - Parameters ΓòÉΓòÉΓòÉ
  3287.  
  3288.  handle (PSNSHANDLE) 
  3289.            Handle returned by PsnsInit. 
  3290.  
  3291.  pPsnsFileInfo (PPSNSFILEINFO) 
  3292.            Pointer to a PSNSFILEINFO structure into which the information will 
  3293.            be put.  The fields backupSet, filename and thisGeneration should be 
  3294.            initialised to show which file, backup set and generation to get. 
  3295.  
  3296.  
  3297. ΓòÉΓòÉΓòÉ <hidden> PsnsGetFileGeneration - Returns ΓòÉΓòÉΓòÉ
  3298.  
  3299.       PSNS_OK 
  3300.       PSNS_HANDLE_IN_USE 
  3301.       PSNS_COMMUNICATIONS_ERROR 
  3302.       PSNS_INVALID_HANDLE 
  3303.       PSNS_INVALID_BACKUP_SET 
  3304.       PSNS_FILE_NOT_FOUND 
  3305.       PSNS_INVALID_GENERATION 
  3306.       PSNS_ARCHIVE_ERROR 
  3307.       PSNS_TRANSFERRED_OUT 
  3308.  
  3309.  
  3310. ΓòÉΓòÉΓòÉ <hidden> PsnsGetFileGeneration - Remarks ΓòÉΓòÉΓòÉ
  3311.  
  3312. Use this function to get information about a specific generation of a backed-up 
  3313. file.  This includes the date and time of backup, which volume the generation 
  3314. is stored on, and file system information about the file at the time it was 
  3315. backed up.  You must first fill in the backupSet, filename and thisGeneration 
  3316. fields in the PSNSFILEINFO structure you pass to tell OS/2 Warp Server 
  3317. Backup/Restore which file and generation to retrieve information on. 
  3318.  
  3319.  
  3320. ΓòÉΓòÉΓòÉ <hidden> PsnsGetFileGeneration - Related functions ΓòÉΓòÉΓòÉ
  3321.  
  3322.      PsnsListFiles 
  3323.  
  3324.  
  3325. ΓòÉΓòÉΓòÉ 3.43. PsnsGetLastError ΓòÉΓòÉΓòÉ
  3326.  
  3327. Select an item 
  3328.  
  3329.      Syntax 
  3330.      Parameters 
  3331.      Returns 
  3332.      Remarks 
  3333.      Example 
  3334.      Related functions 
  3335.  
  3336.  
  3337. ΓòÉΓòÉΓòÉ <hidden> PsnsGetLastError - Syntax ΓòÉΓòÉΓòÉ
  3338.  
  3339. /****************************************************/
  3340. /* This function returns a text message associated  */
  3341. /* with the last API function call.                 */
  3342. /****************************************************/
  3343.  
  3344. int PsnsGetLastError(PSNSHANDLE handle,
  3345.                      char *message,
  3346.                      PULONG length);
  3347.  
  3348.  
  3349. ΓòÉΓòÉΓòÉ <hidden> PsnsGetLastError - Parameters ΓòÉΓòÉΓòÉ
  3350.  
  3351.  handle (PSNSHANDLE) 
  3352.            Handle returned by PsnsInit. 
  3353.  
  3354.  message (char *) 
  3355.            Buffer into which to put the message, may be NULL. 
  3356.  
  3357.  length (PULONG) 
  3358.  
  3359.            Input          Size of the buffer pointed to by message. 
  3360.            Output         Size of the buffer needed to hold the entire message 
  3361.                           string, including the terminating NULL. 
  3362.  
  3363.  
  3364. ΓòÉΓòÉΓòÉ <hidden> PsnsGetLastError - Returns ΓòÉΓòÉΓòÉ
  3365.  
  3366.       PSNS_OK 
  3367.       PSNS_HANDLE_IN_USE 
  3368.       PSNS_COMMUNICATIONS_ERROR 
  3369.       PSNS_INVALID_HANDLE 
  3370.       PSNS_TOO_MUCH_DATA 
  3371.  
  3372.  
  3373. ΓòÉΓòÉΓòÉ <hidden> PsnsGetLastError - Remarks ΓòÉΓòÉΓòÉ
  3374.  
  3375. Use this function to get a text message which describes the result of the last 
  3376. API function call, or the size of the buffer needed to hold the message. When 
  3377. an API call fails and returns a non-zero return code, use this function to get 
  3378. the error message which that function call produced. 
  3379.  
  3380.  
  3381. ΓòÉΓòÉΓòÉ <hidden> PsnsGetLastError - Related functions ΓòÉΓòÉΓòÉ
  3382.  
  3383.      PsnsGetMessageText 
  3384.  
  3385.  
  3386. ΓòÉΓòÉΓòÉ 3.44. PsnsGetLogFile ΓòÉΓòÉΓòÉ
  3387.  
  3388. Select an item 
  3389.  
  3390.      Syntax 
  3391.      Parameters 
  3392.      Returns 
  3393.      Remarks 
  3394.      Example 
  3395.      Related functions 
  3396.  
  3397.  
  3398. ΓòÉΓòÉΓòÉ <hidden> PsnsGetLogFile - Syntax ΓòÉΓòÉΓòÉ
  3399.  
  3400. /****************************************************/
  3401. /* This function returns the name of the log file   */
  3402. /* for a backup set.                                */
  3403. /****************************************************/
  3404.  
  3405. int PsnsGetLogFile(PSNSHANDLE handle,
  3406.                    const char *backupSet,
  3407.                    char *buffer);
  3408.  
  3409.  
  3410. ΓòÉΓòÉΓòÉ <hidden> PsnsGetLogFile - Parameters ΓòÉΓòÉΓòÉ
  3411.  
  3412.  handle (PSNSHANDLE) 
  3413.            Handle returned by PsnsInit. 
  3414.  
  3415.  backupSet (const char *) 
  3416.            Name of the backup set for which you want to get the log file. 
  3417.  
  3418.  buffer (char *) 
  3419.            Pointer to a buffer of length at least CCHMAXPATH to receive the 
  3420.            filename of the log file for this backup set. 
  3421.  
  3422.  
  3423. ΓòÉΓòÉΓòÉ <hidden> PsnsGetLogFile - Returns ΓòÉΓòÉΓòÉ
  3424.  
  3425.       PSNS_OK 
  3426.       PSNS_HANDLE_IN_USE 
  3427.       PSNS_COMMUNICATIONS_ERROR 
  3428.       PSNS_INVALID_HANDLE 
  3429.       PSNS_INVALID_BACKUP_SET 
  3430.  
  3431.  
  3432. ΓòÉΓòÉΓòÉ <hidden> PsnsGetLogFile - Remarks ΓòÉΓòÉΓòÉ
  3433.  
  3434. Use this function to get the name of the log file for a backup set.  If OS/2 
  3435. Warp Server Backup/Restore is running locally, you will then be able to view, 
  3436. edit or delete the log file. 
  3437.  
  3438.  
  3439. ΓòÉΓòÉΓòÉ <hidden> PsnsGetLogFile - Related functions ΓòÉΓòÉΓòÉ
  3440.  
  3441.      PsnsRunBackupMethod 
  3442.  
  3443.      PsnsRunRestoreMethod 
  3444.  
  3445.      PsnsTransferIn 
  3446.  
  3447.  
  3448. ΓòÉΓòÉΓòÉ 3.45. PsnsGetMessageText ΓòÉΓòÉΓòÉ
  3449.  
  3450. Select an item 
  3451.  
  3452.      Syntax 
  3453.      Parameters 
  3454.      Returns 
  3455.      Remarks 
  3456.      Example 
  3457.      Related functions 
  3458.  
  3459.  
  3460. ΓòÉΓòÉΓòÉ <hidden> PsnsGetMessageText - Syntax ΓòÉΓòÉΓòÉ
  3461.  
  3462. /****************************************************/
  3463. /* This function returns a text message associated  */
  3464. /* with an API return code.                         */
  3465. /****************************************************/
  3466.  
  3467. int PsnsGetMessageText(PSNSHANDLE handle,
  3468.                        int rc,
  3469.                        char *message,
  3470.                        PULONG length);
  3471.  
  3472.  
  3473. ΓòÉΓòÉΓòÉ <hidden> PsnsGetMessageText - Parameters ΓòÉΓòÉΓòÉ
  3474.  
  3475.  handle (PSNSHANDLE) 
  3476.            Handle returned by PsnsInit. 
  3477.  
  3478.  rc (int) 
  3479.            Return code for which you want to get a message. 
  3480.  
  3481.  message (char *) 
  3482.            Buffer into which to put the message, may by NULL. 
  3483.  
  3484.  length (PULONG) 
  3485.  
  3486.            Input          Size of the buffer pointed to by message. 
  3487.            Output         Size of the buffer needed to hold the entire message 
  3488.                           string, including the terminating NULL. 
  3489.  
  3490.  
  3491. ΓòÉΓòÉΓòÉ <hidden> PsnsGetMessageText - Returns ΓòÉΓòÉΓòÉ
  3492.  
  3493.       PSNS_OK 
  3494.       PSNS_HANDLE_IN_USE 
  3495.       PSNS_COMMUNICATIONS_ERROR 
  3496.       PSNS_INVALID_HANDLE 
  3497.       PSNS_INVALID_RC 
  3498.       PSNS_TOO_MUCH_DATA 
  3499.  
  3500.  
  3501. ΓòÉΓòÉΓòÉ <hidden> PsnsGetMessageText - Remarks ΓòÉΓòÉΓòÉ
  3502.  
  3503. Use this function to retrieve a message which contains a textual description of 
  3504. an OS/2 Warp Server Backup/Restore API return code, or the size of the buffer 
  3505. needed to hold that description. 
  3506.  
  3507.  
  3508. ΓòÉΓòÉΓòÉ <hidden> PsnsGetMessageText - Related functions ΓòÉΓòÉΓòÉ
  3509.  
  3510.      PsnsGetLastError 
  3511.  
  3512.  
  3513. ΓòÉΓòÉΓòÉ 3.46. PsnsGetNextEvent ΓòÉΓòÉΓòÉ
  3514.  
  3515. Select an item 
  3516.  
  3517.      Syntax 
  3518.      Parameters 
  3519.      Returns 
  3520.      Remarks 
  3521.      Example 
  3522.      Related functions 
  3523.  
  3524.  
  3525. ΓòÉΓòÉΓòÉ <hidden> PsnsGetNextEvent - Syntax ΓòÉΓòÉΓòÉ
  3526.  
  3527. /****************************************************/
  3528. /* This function calculates which scheduled event   */
  3529. /* is due to happen next, and returns information   */
  3530. /* about it.                                        */
  3531. /****************************************************/
  3532.  
  3533. int PsnsGetNextEvent(PSNSHANDLE handle,
  3534.                      PEVENTINFO pEventInfo);
  3535.  
  3536.  
  3537. ΓòÉΓòÉΓòÉ <hidden> PsnsGetNextEvent - Parameters ΓòÉΓòÉΓòÉ
  3538.  
  3539.  handle (PSNSHANDLE) 
  3540.            Handle returned by PsnsInit. 
  3541.  
  3542.  pEventInfo (PEVENTINFO) 
  3543.            Pointer to an EVENTINFO structure to receive the event information. 
  3544.  
  3545.  
  3546. ΓòÉΓòÉΓòÉ <hidden> PsnsGetNextEvent - Returns ΓòÉΓòÉΓòÉ
  3547.  
  3548.       PSNS_OK 
  3549.       PSNS_HANDLE_IN_USE 
  3550.       PSNS_COMMUNICATIONS_ERROR 
  3551.       PSNS_INVALID_HANDLE 
  3552.       PSNS_NO_EVENTS 
  3553.  
  3554.  
  3555. ΓòÉΓòÉΓòÉ <hidden> PsnsGetNextEvent - Remarks ΓòÉΓòÉΓòÉ
  3556.  
  3557. Use this function to find out which scheduled event is due to happen next.  It 
  3558. is possible that no events are currently scheduled to happen; in that case, 
  3559. PSNS_NO_EVENTS will be returned. 
  3560.  
  3561.  
  3562. ΓòÉΓòÉΓòÉ <hidden> PsnsGetNextEvent - Related functions ΓòÉΓòÉΓòÉ
  3563.  
  3564.      PsnsCreateEvent 
  3565.  
  3566.      PsnsDeleteEvent 
  3567.  
  3568.      PsnsCopyEvent 
  3569.  
  3570.      PsnsEventInfo 
  3571.  
  3572.      PsnsListEvents 
  3573.  
  3574.      PsnsActivateEvent 
  3575.  
  3576.  
  3577. ΓòÉΓòÉΓòÉ 3.47. PsnsGetStorageDeviceConfig ΓòÉΓòÉΓòÉ
  3578.  
  3579. Select an item 
  3580.  
  3581.      Syntax 
  3582.      Parameters 
  3583.      Returns 
  3584.      Remarks 
  3585.      Example 
  3586.      Related functions 
  3587.  
  3588.  
  3589. ΓòÉΓòÉΓòÉ <hidden> PsnsGetStorageDeviceConfig - Syntax ΓòÉΓòÉΓòÉ
  3590.  
  3591. /****************************************************/
  3592. /* This function gets configuration information for */
  3593. /* a storage device.                                */
  3594. /****************************************************/
  3595.  
  3596. int PsnsGetStorageDeviceConfig(PSNSHANDLE handle,
  3597.                                const char *name,
  3598.                                char *config,
  3599.                                PULONG length);
  3600.  
  3601.  
  3602. ΓòÉΓòÉΓòÉ <hidden> PsnsGetStorageDeviceConfig - Parameters ΓòÉΓòÉΓòÉ
  3603.  
  3604.  handle (PSNSHANDLE) 
  3605.            Handle returned by PsnsInit. 
  3606.  
  3607.  name (const char *) 
  3608.            Name of the storage device to be inspected. 
  3609.  
  3610.  config (char *) 
  3611.            Pointer to a buffer to receive the configuration information, may be 
  3612.            NULL. 
  3613.  
  3614.  length (PULONG) 
  3615.  
  3616.            Input          Size of the buffer pointer to by config. 
  3617.            Output         Size of the buffer needed to contain the entire 
  3618.                           configuration string including a terminating NULL. 
  3619.  
  3620.  
  3621. ΓòÉΓòÉΓòÉ <hidden> PsnsGetStorageDeviceConfig - Returns ΓòÉΓòÉΓòÉ
  3622.  
  3623.       PSNS_OK 
  3624.       PSNS_HANDLE_IN_USE 
  3625.       PSNS_COMMUNICATIONS_ERROR 
  3626.       PSNS_INVALID_HANDLE 
  3627.       PSNS_INVALID_STORAGE_DEVICE 
  3628.       PSNS_TOO_MUCH_DATA 
  3629.  
  3630.  
  3631. ΓòÉΓòÉΓòÉ <hidden> PsnsGetStorageDeviceConfig - Remarks ΓòÉΓòÉΓòÉ
  3632.  
  3633. Use this function to get the current configuration information for a storage 
  3634. device, or find out how large a buffer is needed to hold this information. The 
  3635. format of this information depends on the storage device; to find out how all 
  3636. the standard OS/2 Warp Server Backup/Restore storage devices handle this, see 
  3637. Storage Device Configuration. 
  3638.  
  3639.  
  3640. ΓòÉΓòÉΓòÉ <hidden> PsnsGetStorageDeviceConfig - Related functions ΓòÉΓòÉΓòÉ
  3641.  
  3642.      PsnsSetStorageDeviceConfig 
  3643.  
  3644.      PsnsSetBackupSetConfig 
  3645.  
  3646.      PsnsGetBackupSetConfig 
  3647.  
  3648.  
  3649. ΓòÉΓòÉΓòÉ 3.48. PsnsInit ΓòÉΓòÉΓòÉ
  3650.  
  3651. Select an item 
  3652.  
  3653.      Syntax 
  3654.      Parameters 
  3655.      Returns 
  3656.      Remarks 
  3657.      Example 
  3658.      Related functions 
  3659.  
  3660.  
  3661. ΓòÉΓòÉΓòÉ <hidden> PsnsInit - Syntax ΓòÉΓòÉΓòÉ
  3662.  
  3663. /****************************************************/
  3664. /* This function opens a connection to the API      */
  3665. /* server for use with subsequent API functions.    */
  3666. /****************************************************/
  3667.  
  3668. int PsnsInit(PSNSHANDLE *handle,
  3669.              PSNSCONNECTION psnsConnection,
  3670.              PVOID data);
  3671.  
  3672.  
  3673. ΓòÉΓòÉΓòÉ <hidden> PsnsInit - Parameters ΓòÉΓòÉΓòÉ
  3674.  
  3675.  handle (PSNSHANDLE *) 
  3676.            Pointer to where the new handle should be stored. 
  3677.  
  3678.  psnsConnection (PSNSCONNECTION) 
  3679.            Possible values: 
  3680.  
  3681.            PSNS_PIPE      Connect using named pipes. 
  3682.            PSNS_TCPIP     Connect using TCP/IP sockets. 
  3683.  
  3684.  data (PVOID) 
  3685.            Pointer to data about the connection.  To use named pipes, this 
  3686.            should point to a PSNSPIPEINFO structure; if this structure is 
  3687.            empty, a default pipe name will be used. To use TCP/IP, it should 
  3688.            point to a string of the form "hostname:port" or "hostname:service" 
  3689.            specifying either a port number or a service to be looked up in the 
  3690.            TCP/IP services file; if the string is empty or NULL, the port will 
  3691.            be decided by looking up psnsapi in the TCP/IP services file. 
  3692.  
  3693.  
  3694. ΓòÉΓòÉΓòÉ <hidden> PsnsInit - Returns ΓòÉΓòÉΓòÉ
  3695.  
  3696.       PSNS_OK 
  3697.       PSNS_COMMUNICATIONS_ERROR 
  3698.       PSNS_NO_MORE_HANDLES 
  3699.       PSNS_CANNOT_CONNECT 
  3700.  
  3701.  
  3702. ΓòÉΓòÉΓòÉ <hidden> PsnsInit - Remarks ΓòÉΓòÉΓòÉ
  3703.  
  3704. You must call this function before you can use any of the other OS/2 Warp 
  3705. Server Backup/Restore C API functions.  This function opens a connection to the 
  3706. API server, which can be either local or remote. 
  3707.  
  3708. With one handle, you may only call one API function at a time.  If you wish to 
  3709. have multiple threads which all use API functions, you must call PsnsInit again 
  3710. from each thread to get a new handle. 
  3711.  
  3712. When you have finished making API calls with the handle, call PsnsTerm. 
  3713.  
  3714.  
  3715. ΓòÉΓòÉΓòÉ <hidden> PsnsInit - Related functions ΓòÉΓòÉΓòÉ
  3716.  
  3717.      PsnsTerm 
  3718.  
  3719.  
  3720. ΓòÉΓòÉΓòÉ 3.49. PsnsListBackupMethods ΓòÉΓòÉΓòÉ
  3721.  
  3722. Select an item 
  3723.  
  3724.      Syntax 
  3725.      Parameters 
  3726.      Returns 
  3727.      Remarks 
  3728.      Example 
  3729.      Related functions 
  3730.  
  3731.  
  3732. ΓòÉΓòÉΓòÉ <hidden> PsnsListBackupMethods - Syntax ΓòÉΓòÉΓòÉ
  3733.  
  3734. /****************************************************/
  3735. /* This function lists backup methods which match   */
  3736. /* certain criteria.                                */
  3737. /****************************************************/
  3738.  
  3739. int PsnsListBackupMethods(PSNSHANDLE handle,
  3740.                           PHPSNSLIST pHPsnsList,
  3741.                           PBACKUPMETHODINFO pBackupMethodInfo,
  3742.                           long mask);
  3743.  
  3744.  
  3745. ΓòÉΓòÉΓòÉ <hidden> PsnsListBackupMethods - Parameters ΓòÉΓòÉΓòÉ
  3746.  
  3747.  handle (PSNSHANDLE) 
  3748.            Handle returned by PsnsInit. 
  3749.  
  3750.  pHPsnsList (PHPSNSLIST) 
  3751.            Pointer to a list handle. 
  3752.  
  3753.  pBackupMethodInfo (PBACKUPMETHODINFO) 
  3754.            Pointer to a BACKUPMETHODINFO structure where the backup methods 
  3755.            found will be returned.  On the first call, this contains the 
  3756.            criteria to search against. 
  3757.  
  3758.  mask (long) 
  3759.            Possible values: 
  3760.  
  3761.                 BM_NONE 
  3762.                 BM_NAME 
  3763.                 BM_DESCRIPTION 
  3764.                 BM_ALLFILES 
  3765.                 BM_DRIVE 
  3766.                 BM_DIRECTORY 
  3767.                 BM_PATTERN 
  3768.                 BM_SUBDIRECTORIES 
  3769.                 BM_COMPRESSION 
  3770.                 BM_GENERATIONS 
  3771.                 BM_USERULEBOOK 
  3772.                 BM_RULEBOOK 
  3773.                 BM_USEFILEFILTER 
  3774.                 BM_FILEFILTER 
  3775.                 BM_CHANGEDFILESONLY 
  3776.                 BM_PREVIEW 
  3777.                 BM_BACKUPSET 
  3778.                 BM_ALL 
  3779.  
  3780.            To search on more than one field, OR the different values together. 
  3781.            To list all backup methods, use mask = BM_NONE. 
  3782.  
  3783.  
  3784. ΓòÉΓòÉΓòÉ <hidden> PsnsListBackupMethods - Returns ΓòÉΓòÉΓòÉ
  3785.  
  3786.       PSNS_OK 
  3787.       PSNS_HANDLE_IN_USE 
  3788.       PSNS_COMMUNICATIONS_ERROR 
  3789.       PSNS_INVALID_HANDLE 
  3790.       PSNS_INVALID_LIST_HANDLE 
  3791.       PSNS_NO_MORE_HANDLES 
  3792.  
  3793.  
  3794. ΓòÉΓòÉΓòÉ <hidden> PsnsListBackupMethods - Remarks ΓòÉΓòÉΓòÉ
  3795.  
  3796. On the first call to PsnsListBackupMethods, pHPsnsList should point to an 
  3797. HPSNSLIST which has been initialised to 0.  You should pass the search criteria 
  3798. in pBackupMethodInfo and set the mask according to which fields you want to 
  3799. search on.  On return from this call, the handle pointed to will have been set 
  3800. to a new list handle number, and the first backup method which matches the 
  3801. search criteria is copied into the structure pointed to by pBackupMethodInfo. 
  3802. The name, description, fileFilter, rulebook and backupSet fields may all 
  3803. contain wildcards. 
  3804.  
  3805. On subsequent calls, the handle pointed to is non-zero and both the initial 
  3806. contents of the structure and the mask are ignored; the next backup method 
  3807. which matches the criteria is returned in the structure.  When there are no 
  3808. more backup methods to list, the handle is set back to 0 to indicate that the 
  3809. list has finished. 
  3810.  
  3811. If you want to interrupt the listing operation before getting to the last item, 
  3812. you should call PsnsCloseList to free the list handle. 
  3813.  
  3814.  
  3815. ΓòÉΓòÉΓòÉ <hidden> PsnsListBackupMethods - Related functions ΓòÉΓòÉΓòÉ
  3816.  
  3817.      PsnsCreateBackupMethod 
  3818.  
  3819.      PsnsDeleteBackupMethod 
  3820.  
  3821.      PsnsRenameBackupMethod 
  3822.  
  3823.      PsnsCopyBackupMethod 
  3824.  
  3825.      PsnsBackupMethodInfo 
  3826.  
  3827.      PsnsEstimateBackupMethod 
  3828.  
  3829.      PsnsRunBackupMethod 
  3830.  
  3831.  
  3832. ΓòÉΓòÉΓòÉ 3.50. PsnsListBackupSets ΓòÉΓòÉΓòÉ
  3833.  
  3834. Select an item 
  3835.  
  3836.      Syntax 
  3837.      Parameters 
  3838.      Returns 
  3839.      Remarks 
  3840.      Example 
  3841.      Related functions 
  3842.  
  3843.  
  3844. ΓòÉΓòÉΓòÉ <hidden> PsnsListBackupSets - Syntax ΓòÉΓòÉΓòÉ
  3845.  
  3846. /****************************************************/
  3847. /* This function lists backup sets which match      */
  3848. /* certain criteria.                                */
  3849. /****************************************************/
  3850.  
  3851. int PsnsListBackupSets(PSNSHANDLE handle,
  3852.                        PHPSNSLIST pHPsnsList,
  3853.                        PBACKUPSETINFO pBackupSetInfo,
  3854.                        long mask);
  3855.  
  3856.  
  3857. ΓòÉΓòÉΓòÉ <hidden> PsnsListBackupSets - Parameters ΓòÉΓòÉΓòÉ
  3858.  
  3859.  handle (PSNSHANDLE) 
  3860.            Handle returned by PsnsInit. 
  3861.  
  3862.  pHPsnsList (PHPSNSLIST) 
  3863.            Pointer to a list handle. 
  3864.  
  3865.  pBackupSetInfo (PBACKUPSETINFO) 
  3866.            Pointer to a BACKUPSETINFO structure where the backup sets found 
  3867.            will be returned.  On the first call, this contains the criteria to 
  3868.            search against. 
  3869.  
  3870.  mask (long) 
  3871.            Possible values: 
  3872.  
  3873.                 BS_NONE 
  3874.                 BS_NAME 
  3875.                 BS_DESCRIPTION 
  3876.                 BS_STORAGEDEVICE 
  3877.                 BS_INCSTORAGEDEVICE 
  3878.                 BS_TRANSFERREDIN 
  3879.                 BS_ALL 
  3880.  
  3881.            To search on more than one field, OR the different values together. 
  3882.            To list all backup methods, use mask = BS_NONE. 
  3883.  
  3884.  
  3885. ΓòÉΓòÉΓòÉ <hidden> PsnsListBackupSets - Returns ΓòÉΓòÉΓòÉ
  3886.  
  3887.       PSNS_OK 
  3888.       PSNS_HANDLE_IN_USE 
  3889.       PSNS_COMMUNICATIONS_ERROR 
  3890.       PSNS_INVALID_HANDLE 
  3891.       PSNS_INVALID_LIST_HANDLE 
  3892.       PSNS_NO_MORE_HANDLES 
  3893.       PSNS_INVALID_MASK 
  3894.  
  3895.  
  3896. ΓòÉΓòÉΓòÉ <hidden> PsnsListBackupSets - Remarks ΓòÉΓòÉΓòÉ
  3897.  
  3898. On the first call to PsnsListBackupSets, pHPsnsList should point to an 
  3899. HPSNSLIST which has been initialised to 0.  You should pass the search criteria 
  3900. in pBackupSetInfo and set the mask according to which fields you want to search 
  3901. on.  On return from this call, the handle pointed to will have been set to a 
  3902. new list handle number, and the first backup set which matches the search 
  3903. criteria is copied into the structure pointed to by pBackupSetInfo. The name 
  3904. and description fields may contain wildcards. 
  3905.  
  3906. On subsequent calls, the handle pointed to is non-zero and both the initial 
  3907. contents of the structure and the mask are ignored; the next backup set which 
  3908. matches the criteria is returned in the structure.  When there are no more 
  3909. backup sets to list, the handle is set back to 0 to indicate that the list has 
  3910. finished. 
  3911.  
  3912. If you want to interrupt the listing operation before getting to the last item, 
  3913. you should call PsnsCloseList to free the list handle. 
  3914.  
  3915.  
  3916. ΓòÉΓòÉΓòÉ <hidden> PsnsListBackupSets - Related functions ΓòÉΓòÉΓòÉ
  3917.  
  3918.      PsnsCreateBackupSet 
  3919.  
  3920.      PsnsDeleteBackupSet 
  3921.  
  3922.      PsnsBackupSetInfo 
  3923.  
  3924.      PsnsSetBackupSetConfig 
  3925.  
  3926.      PsnsGetBackupSetConfig 
  3927.  
  3928.      PsnsTransferBackupSet 
  3929.  
  3930.      PsnsTransferIn 
  3931.  
  3932.      PsnsGetLogFile 
  3933.  
  3934.      PsnsEmptyBackupSet 
  3935.  
  3936.  
  3937. ΓòÉΓòÉΓòÉ 3.51. PsnsListEvents ΓòÉΓòÉΓòÉ
  3938.  
  3939. Select an item 
  3940.  
  3941.      Syntax 
  3942.      Parameters 
  3943.      Returns 
  3944.      Remarks 
  3945.      Example 
  3946.      Related functions 
  3947.  
  3948.  
  3949. ΓòÉΓòÉΓòÉ <hidden> PsnsListEvents - Syntax ΓòÉΓòÉΓòÉ
  3950.  
  3951. /****************************************************/
  3952. /* This function lists scheduled events which match */
  3953. /* certain criteria.                                */
  3954. /****************************************************/
  3955.  
  3956. int PsnsListEvents(PSNSHANDLE handle,
  3957.                    PHPSNSLIST pHPsnsList,
  3958.                    PEVENTINFO pEventInfo,
  3959.                    long mask);
  3960.  
  3961.  
  3962. ΓòÉΓòÉΓòÉ <hidden> PsnsListEvents - Parameters ΓòÉΓòÉΓòÉ
  3963.  
  3964.  handle (PSNSHANDLE) 
  3965.            Handle returned by PsnsInit. 
  3966.  
  3967.  pHPsnsList (PHPSNSLIST) 
  3968.            Pointer to a list handle. 
  3969.  
  3970.  pEventInfo (PEVENTINFO) 
  3971.            Pointer to an EVENTINFO structure where the events found will be 
  3972.            returned.  On the first call, this contains the criteria to search 
  3973.            against. 
  3974.  
  3975.  mask (long) 
  3976.            Possible values: 
  3977.  
  3978.                 EV_NONE 
  3979.                 EV_TYPE 
  3980.                 EV_BACKUPMETHOD 
  3981.                 EV_HOURS 
  3982.                 EV_MINUTES 
  3983.                 EV_DAY 
  3984.                 EV_DAYS 
  3985.                 EV_WEEKS 
  3986.                 EV_CHANGEDFILESONLY 
  3987.                 EV_SHOWPREVIEW 
  3988.                 EV_ACTIVE 
  3989.                 EV_LASTRUN_BEFORE 
  3990.                 EV_LASTRUN_AFTER 
  3991.                 EV_NEXTRUN_BEFORE 
  3992.                 EV_NEXTRUN_AFTER 
  3993.                 EV_ALL 
  3994.  
  3995.            To search on more than one field, OR the different values together. 
  3996.            To list all events, use mask = EV_NONE. 
  3997.  
  3998.  
  3999. ΓòÉΓòÉΓòÉ <hidden> PsnsListEvents - Returns ΓòÉΓòÉΓòÉ
  4000.  
  4001.       PSNS_OK 
  4002.       PSNS_HANDLE_IN_USE 
  4003.       PSNS_COMMUNICATIONS_ERROR 
  4004.       PSNS_INVALID_HANDLE 
  4005.       PSNS_INVALID_LIST_HANDLE 
  4006.       PSNS_NO_MORE_HANDLES 
  4007.       PSNS_INVALID_MASK 
  4008.  
  4009.  
  4010. ΓòÉΓòÉΓòÉ <hidden> PsnsListEvents - Remarks ΓòÉΓòÉΓòÉ
  4011.  
  4012. On the first call to PsnsListEvents, pHPsnsList should point to an HPSNSLIST 
  4013. which has been initialised to 0.  You should pass the search criteria in 
  4014. pEventInfo and set the mask according to which fields you want to search on. 
  4015. On return from this call, the handle pointed to will have been set to a new 
  4016. list handle number, and the first event which matches the search criteria is 
  4017. copied into the structure pointed to by pEventInfo. The backupMethod field may 
  4018. contain wildcards.  When searching for events based on the time of the last or 
  4019. next occurrence, you can search for times either before or after the specified 
  4020. time, by setting the appropriate bit in the mask (EV_LASTRUN_BEFORE or 
  4021. EV_LASTRUN_AFTER etc.). 
  4022.  
  4023. On subsequent calls, the handle pointed to is non-zero and both the initial 
  4024. contents of the structure and the mask are ignored; the next event which 
  4025. matches the criteria is returned in the structure.  When there are no more 
  4026. events to list, the handle is set back to 0 to indicate that the list has 
  4027. finished. 
  4028.  
  4029. If you want to interrupt the listing operation before getting to the last item, 
  4030. you should call PsnsCloseList to free the list handle. 
  4031.  
  4032.  
  4033. ΓòÉΓòÉΓòÉ <hidden> PsnsListEvents - Related functions ΓòÉΓòÉΓòÉ
  4034.  
  4035.      PsnsCreateEvent 
  4036.  
  4037.      PsnsDeleteEvent 
  4038.  
  4039.      PsnsCopyEvent 
  4040.  
  4041.      PsnsEventInfo 
  4042.  
  4043.      PsnsGetNextEvent 
  4044.  
  4045.      PsnsActivateEvent 
  4046.  
  4047.  
  4048. ΓòÉΓòÉΓòÉ 3.52. PsnsListFileFilters ΓòÉΓòÉΓòÉ
  4049.  
  4050. Select an item 
  4051.  
  4052.      Syntax 
  4053.      Parameters 
  4054.      Returns 
  4055.      Remarks 
  4056.      Example 
  4057.      Related functions 
  4058.  
  4059.  
  4060. ΓòÉΓòÉΓòÉ <hidden> PsnsListFileFilters - Syntax ΓòÉΓòÉΓòÉ
  4061.  
  4062. /****************************************************/
  4063. /* This function lists file filters which match     */
  4064. /* certain criteria.                                */
  4065. /****************************************************/
  4066.  
  4067. int PsnsListFileFilters(PSNSHANDLE handle,
  4068.                         PHPSNSLIST pHPsnsList,
  4069.                         PFILEFILTERINFO pFileFilterInfo,
  4070.                         long mask);
  4071.  
  4072.  
  4073. ΓòÉΓòÉΓòÉ <hidden> PsnsListFileFilters - Parameters ΓòÉΓòÉΓòÉ
  4074.  
  4075.  handle (PSNSHANDLE) 
  4076.            Handle returned by PsnsInit. 
  4077.  
  4078.  pHPsnsList (PHPSNSLIST) 
  4079.            Pointer to a list handle. 
  4080.  
  4081.  pFileFilterInfo (PFILEFILTERINFO) 
  4082.            Pointer to a FILEFILTERINFO structure where the file filters found 
  4083.            will be returned.  On the first call, this contains the criteria to 
  4084.            search against. 
  4085.  
  4086.  mask (long) 
  4087.            Possible values: 
  4088.  
  4089.                 FF_NONE 
  4090.                 FF_NAME 
  4091.                 FF_DESCRIPTION 
  4092.                 FF_SEARCHFILE 
  4093.                 FF_ALL 
  4094.  
  4095.            To search on more than one field, OR the different values together. 
  4096.            To list all file filters, use mask = FF_NONE. 
  4097.  
  4098.  
  4099. ΓòÉΓòÉΓòÉ <hidden> PsnsListFileFilters - Returns ΓòÉΓòÉΓòÉ
  4100.  
  4101.       PSNS_OK 
  4102.       PSNS_HANDLE_IN_USE 
  4103.       PSNS_COMMUNICATIONS_ERROR 
  4104.       PSNS_INVALID_HANDLE 
  4105.       PSNS_INVALID_LIST_HANDLE 
  4106.       PSNS_NO_MORE_HANDLES 
  4107.       PSNS_INVALID_MASK 
  4108.  
  4109.  
  4110. ΓòÉΓòÉΓòÉ <hidden> PsnsListFileFilters - Remarks ΓòÉΓòÉΓòÉ
  4111.  
  4112. On the first call to PsnsListFileFilters, pHPsnsList should point to an 
  4113. HPSNSLIST which has been initialised to 0.  You should pass the search criteria 
  4114. in pFileFilterInfo and set the mask according to which fields you want to 
  4115. search on.  On return from this call, the handle pointed to will have been set 
  4116. to a new list handle number, and the first file filter which matches the search 
  4117. criteria is copied into the structure pointed to by pFileFilterInfo. 
  4118.  
  4119. The name and description fields may both contain wildcards. You can also search 
  4120. for all file filters which match a particular file; put the name of the file in 
  4121. the searchFile field and set the FF_SEARCHFILE bit in the mask. 
  4122.  
  4123. On subsequent calls, the handle pointed to is non-zero and both the initial 
  4124. contents of the structure and the mask are ignored; the next file filter which 
  4125. matches the criteria is returned in the structure.  When there are no more file 
  4126. filters to list, the handle is set back to 0 to indicate that the list has 
  4127. finished. 
  4128.  
  4129. If you want to interrupt the listing operation before getting to the last item, 
  4130. you should call PsnsCloseList to free the list handle. 
  4131.  
  4132.  
  4133. ΓòÉΓòÉΓòÉ <hidden> PsnsListFileFilters - Related functions ΓòÉΓòÉΓòÉ
  4134.  
  4135.      PsnsCreateFileFilter 
  4136.  
  4137.      PsnsDeleteFileFilter 
  4138.  
  4139.      PsnsRenameFileFilter 
  4140.  
  4141.      PsnsCopyFileFilter 
  4142.  
  4143.      PsnsFileFilterInfo 
  4144.  
  4145.  
  4146. ΓòÉΓòÉΓòÉ 3.53. PsnsListFiles ΓòÉΓòÉΓòÉ
  4147.  
  4148. Select an item 
  4149.  
  4150.      Syntax 
  4151.      Parameters 
  4152.      Returns 
  4153.      Remarks 
  4154.      Example 
  4155.      Related functions 
  4156.  
  4157.  
  4158. ΓòÉΓòÉΓòÉ <hidden> PsnsListFiles - Syntax ΓòÉΓòÉΓòÉ
  4159.  
  4160. /****************************************************/
  4161. /* This function lists files which have been backed */
  4162. /* up into a backup set, and which match certain    */
  4163. /* criteria.                                        */
  4164. /****************************************************/
  4165.  
  4166. int PsnsListFiles(PSNSHANDLE handle,
  4167.                   PHPSNSLIST pHPsnsList,
  4168.                   PPSNSFILEINFO pPsnsFileInfo,
  4169.                   long mask);
  4170.  
  4171.  
  4172. ΓòÉΓòÉΓòÉ <hidden> PsnsListFiles - Parameters ΓòÉΓòÉΓòÉ
  4173.  
  4174.  handle (PSNSHANDLE) 
  4175.            Handle returned by PsnsInit. 
  4176.  
  4177.  pHPsnsList (PHPSNSLIST) 
  4178.            Pointer to a list handle. 
  4179.  
  4180.  pPsnsFileInfo (PPSNSFILEINFO) 
  4181.            Pointer to a PSNSFILEINFO structure where the files and generations 
  4182.            found will be returned.  On the first call, this contains the 
  4183.            criteria to search against. 
  4184.  
  4185.  mask (long) 
  4186.            Possible values: 
  4187.  
  4188.                 FILE_NONE 
  4189.                 FILE_FILENAME 
  4190.                 FILE_GENERATIONS_LESS 
  4191.                 FILE_GENERATIONS_MORE 
  4192.                 FILE_CREATIONDATE_BEFORE 
  4193.                 FILE_CREATIONDATE_ON 
  4194.                 FILE_CREATIONDATE_AFTER 
  4195.                 FILE_CREATIONTIME_BEFORE 
  4196.                 FILE_CREATIONTIME_AFTER 
  4197.                 FILE_WRITEDATE_BEFORE 
  4198.                 FILE_WRITEDATE_ON 
  4199.                 FILE_WRITEDATE_AFTER 
  4200.                 FILE_WRITETIME_BEFORE 
  4201.                 FILE_WRITETIME_AFTER 
  4202.                 FILE_BACKUPDATE_BEFORE 
  4203.                 FILE_BACKUPDATE_ON 
  4204.                 FILE_BACKUPDATE_AFTER 
  4205.                 FILE_BACKUPTIME_BEFORE 
  4206.                 FILE_BACKUPTIME_AFTER 
  4207.                 FILE_SIZE_LESS 
  4208.                 FILE_SIZE_MORE 
  4209.                 FILE_ATTRIBS_EXACT 
  4210.                 FILE_ATTRIBS_ALLOF 
  4211.                 FILE_ATTRIBS_SOMEOF 
  4212.                 FILE_ATTRIBS_NOTSOMEOF 
  4213.                 FILE_ATTRIBS_NONEOF 
  4214.                 FILE_VOLUMEID 
  4215.                 FILE_ALL 
  4216.                 FILE_ALLGENERATIONS 
  4217.  
  4218.            To search on more than one field, OR the different values together. 
  4219.            To list all files, use mask = FILE_NONE. 
  4220.  
  4221.  
  4222. ΓòÉΓòÉΓòÉ <hidden> PsnsListFiles - Returns ΓòÉΓòÉΓòÉ
  4223.  
  4224.       PSNS_OK 
  4225.       PSNS_HANDLE_IN_USE 
  4226.       PSNS_COMMUNICATIONS_ERROR 
  4227.       PSNS_INVALID_HANDLE 
  4228.       PSNS_INVALID_LIST_HANDLE 
  4229.       PSNS_NO_MORE_HANDLES 
  4230.       PSNS_INVALID_MASK 
  4231.       PSNS_INVALID_BACKUP_SET 
  4232.       PSNS_ARCHIVE_ERROR 
  4233.       PSNS_TRANSFERRED_OUT 
  4234.  
  4235.  
  4236. ΓòÉΓòÉΓòÉ <hidden> PsnsListFiles - Remarks ΓòÉΓòÉΓòÉ
  4237.  
  4238. Use this function to list files which have been backed up to a backup set. 
  4239.  
  4240. On the first call to PsnsListFiles, pHPsnsList should point to an HPSNSLIST 
  4241. which has been initialised to 0.  You should pass the search criteria in pFiles 
  4242. and set the mask according to which fields you want to search on.  The 
  4243. backupSet field must be set to the backup set you want to search in. On return 
  4244. from this call, the handle pointed to will have been set to a new list handle 
  4245. number, and the first file which matches the search criteria is copied into the 
  4246. structure pointed to by pPsnsFileInfo. 
  4247.  
  4248. The filename field may contain wildcards.  When searching for files by date, 
  4249. you can search for dates before, on or after the specified date; when searching 
  4250. by time, you can search for times before or after the specified time.  When 
  4251. searching by generations or file size, you can search for values greater or 
  4252. less than the specified value.  When searching by attributes, you can search 
  4253. either for an exact match (FILE_ATTRIBS_EXACT), for files which have all of the 
  4254. specified attributes (FILE_ATTRIBS_ALLOF), for those which have some of the 
  4255. specified attributes (FILE_ATTRIBS_SOMEOF), for files which do not have some of 
  4256. the specified attributes (FILE_ATTRIBS_NOTSOMEOF, for example searching for 
  4257. files which are either not hidden or not read-only), or for files which have 
  4258. none of the specified attributes (FILE_ATTTRIBS_NONEOF). 
  4259.  
  4260. On subsequent calls, the handle pointed to is non-zero and both the initial 
  4261. contents of the structure and the mask are ignored; the next file which matches 
  4262. the criteria is returned in the structure.  When there are no more files to 
  4263. list, the handle is set back to 0 to indicate that the list has finished. 
  4264.  
  4265. Since any one file may have multiple generations backed up, this function will 
  4266. normally return information about the generation most relevant to your query. 
  4267. For simple matching queries, the most recent generation of the file which fits 
  4268. the criteria is returned.  For queries of the 'less than', 'more than', 
  4269. 'before', 'after' types, the generation returned is the one which comes closest 
  4270. to the specified value while still fitting the criteria.  For example, if you 
  4271. choose to list all files backed up before a certain date, then all files will 
  4272. be listed which have at least one generation backed up before that date, and 
  4273. the generation returned will be the one which was backed up most recently 
  4274. before that date. 
  4275.  
  4276. To list all generations of backed-up files which match your search criteria, 
  4277. set the FILE_ALLGENERATIONS bit in the mask.  This will mean that all 
  4278. generations of files are returned, rather than just one generation of each file 
  4279. which matches. 
  4280.  
  4281. If you want to interrupt the listing operation before getting to the last item, 
  4282. you should call PsnsCloseList to free the list handle. 
  4283.  
  4284.  
  4285. ΓòÉΓòÉΓòÉ <hidden> PsnsListFiles - Related functions ΓòÉΓòÉΓòÉ
  4286.  
  4287.      PsnsDropFiles 
  4288.  
  4289.  
  4290. ΓòÉΓòÉΓòÉ 3.54. PsnsListRestoreMethods ΓòÉΓòÉΓòÉ
  4291.  
  4292. Select an item 
  4293.  
  4294.      Syntax 
  4295.      Parameters 
  4296.      Returns 
  4297.      Remarks 
  4298.      Example 
  4299.      Related functions 
  4300.  
  4301.  
  4302. ΓòÉΓòÉΓòÉ <hidden> PsnsListRestoreMethods - Syntax ΓòÉΓòÉΓòÉ
  4303.  
  4304. /****************************************************/
  4305. /* This function lists restore methods which match  */
  4306. /* certain criteria.                                */
  4307. /****************************************************/
  4308.  
  4309. int PsnsListRestoreMethods(PSNSHANDLE handle,
  4310.                            PHPSNSLIST pHPsnsList,
  4311.                            PRESTOREMETHODINFO pRestoreMethodInfo,
  4312.                            long mask);
  4313.  
  4314.  
  4315. ΓòÉΓòÉΓòÉ <hidden> PsnsListRestoreMethods - Parameters ΓòÉΓòÉΓòÉ
  4316.  
  4317.  handle (PSNSHANDLE) 
  4318.            Handle returned by PsnsInit. 
  4319.  
  4320.  pHPsnsList (PHPSNSLIST) 
  4321.            Pointer to a list handle. 
  4322.  
  4323.  pRestoreMethodInfo (PRESTOREMETHODINFO) 
  4324.            Pointer to a RESTOREMETHODINFO structure where the restore methods 
  4325.            found will be returned.  On the first call, this contains the 
  4326.            criteria to search against. 
  4327.  
  4328.  mask (long) 
  4329.            Possible values: 
  4330.  
  4331.                 RM_NONE 
  4332.                 RM_NAME 
  4333.                 RM_DESCRIPTION 
  4334.                 RM_BACKUPSET 
  4335.                 RM_ALLFILES 
  4336.                 RM_DRIVE 
  4337.                 RM_DIRECTORY 
  4338.                 RM_PATTERN 
  4339.                 RM_SUBDIRECTORIES 
  4340.                 RM_BYDATE 
  4341.                 RM_PREVIEW 
  4342.                 RM_PROMPT 
  4343.                 RM_ORIGINALLOCATION 
  4344.                 RM_DESTINATIONDRIVE 
  4345.                 RM_DESTINATIONPATH 
  4346.  
  4347.            To search on more than one field, OR the different values together. 
  4348.            To list all backup methods, use mask = RM_NONE. 
  4349.  
  4350.  
  4351. ΓòÉΓòÉΓòÉ <hidden> PsnsListRestoreMethods - Returns ΓòÉΓòÉΓòÉ
  4352.  
  4353.       PSNS_OK 
  4354.       PSNS_HANDLE_IN_USE 
  4355.       PSNS_COMMUNICATIONS_ERROR 
  4356.       PSNS_INVALID_HANDLE 
  4357.       PSNS_INVALID_LIST_HANDLE 
  4358.       PSNS_NO_MORE_HANDLES 
  4359.       PSNS_INVALID_MASK 
  4360.  
  4361.  
  4362. ΓòÉΓòÉΓòÉ <hidden> PsnsListRestoreMethods - Remarks ΓòÉΓòÉΓòÉ
  4363.  
  4364. On the first call to PsnsListRestoreMethods, pHPsnsList should point to an 
  4365. HPSNSLIST which has been initialised to 0.  You should pass the search criteria 
  4366. in pRestoreMethodInfo and set the mask according to which fields you want to 
  4367. search on.  On return from this call, the handle pointed to will have been set 
  4368. to a new list handle number, and the first restore method which matches the 
  4369. search criteria is copied into the structure pointed to by pRestoreMethodInfo. 
  4370. The name, description and backupSet fields may all contain wildcards. 
  4371.  
  4372. On subsequent calls, the handle pointed to is non-zero and both the initial 
  4373. contents of the structure and the mask are ignored; the next restore method 
  4374. which matches the criteria is returned in the structure.  When there are no 
  4375. more restore methods to list, the handle is set back to 0 to indicate that the 
  4376. list has finished. 
  4377.  
  4378. If you want to interrupt the listing operation before getting to the last item, 
  4379. you should call PsnsCloseList to free the list handle. 
  4380.  
  4381.  
  4382. ΓòÉΓòÉΓòÉ <hidden> PsnsListRestoreMethods - Related functions ΓòÉΓòÉΓòÉ
  4383.  
  4384.      PsnsCreateRestoreMethod 
  4385.  
  4386.      PsnsDeleteRestoreMethod 
  4387.  
  4388.      PsnsRenameRestoreMethod 
  4389.  
  4390.      PsnsCopyRestoreMethod 
  4391.  
  4392.      PsnsRestoreMethodInfo 
  4393.  
  4394.      PsnsEstimateRestoreMethod 
  4395.  
  4396.      PsnsRunRestoreMethod 
  4397.  
  4398.  
  4399. ΓòÉΓòÉΓòÉ 3.55. PsnsListRulebooks ΓòÉΓòÉΓòÉ
  4400.  
  4401. Select an item 
  4402.  
  4403.      Syntax 
  4404.      Parameters 
  4405.      Returns 
  4406.      Remarks 
  4407.      Example 
  4408.      Related functions 
  4409.  
  4410.  
  4411. ΓòÉΓòÉΓòÉ <hidden> PsnsListRulebooks - Syntax ΓòÉΓòÉΓòÉ
  4412.  
  4413. /****************************************************/
  4414. /* This function lists rulebooks which match        */
  4415. /* certain criteria.                                */
  4416. /****************************************************/
  4417.  
  4418. int PsnsListRulebooks(PSNSHANDLE handle,
  4419.                       PHPSNSLIST pHPsnsList,
  4420.                       PRULEBOOKINFO pRulebookInfo,
  4421.                       long mask);
  4422.  
  4423.  
  4424. ΓòÉΓòÉΓòÉ <hidden> PsnsListRulebooks - Parameters ΓòÉΓòÉΓòÉ
  4425.  
  4426.  handle (PSNSHANDLE) 
  4427.            Handle returned by PsnsInit. 
  4428.  
  4429.  pHPsnsList (PHPSNSLIST) 
  4430.            Pointer to a list handle. 
  4431.  
  4432.  pRulebookInfo (PRULEBOOKINFO) 
  4433.            Pointer to a RULEBOOKINFO structure where the rulebooks found will 
  4434.            be returned.  On the first call, this contains the criteria to 
  4435.            search against. 
  4436.  
  4437.  mask (long) 
  4438.            Possible values: 
  4439.  
  4440.                 RB_NONE 
  4441.                 RB_NAME 
  4442.                 RB_DESCRIPTION 
  4443.                 RB_ALL 
  4444.  
  4445.            To search on more than one field, OR the different values together. 
  4446.            To list all backup methods, use mask = RB_NONE. 
  4447.  
  4448.  
  4449. ΓòÉΓòÉΓòÉ <hidden> PsnsListRulebooks - Returns ΓòÉΓòÉΓòÉ
  4450.  
  4451.       PSNS_OK 
  4452.       PSNS_HANDLE_IN_USE 
  4453.       PSNS_COMMUNICATIONS_ERROR 
  4454.       PSNS_INVALID_HANDLE 
  4455.       PSNS_INVALID_LIST_HANDLE 
  4456.       PSNS_NO_MORE_HANDLES 
  4457.       PSNS_INVALID_MASK 
  4458.  
  4459.  
  4460. ΓòÉΓòÉΓòÉ <hidden> PsnsListRulebooks - Remarks ΓòÉΓòÉΓòÉ
  4461.  
  4462. On the first call to PsnsListRulebooks, pHPsnsList should point to an HPSNSLIST 
  4463. which has been initialised to 0.  You should pass the search criteria in 
  4464. pRulebookInfo and set the mask according to which fields you want to search on. 
  4465. On return from this call, the handle pointed to will have been set to a new 
  4466. list handle number, and the first rulebook which matches the search criteria is 
  4467. copied into the structure pointed to by pRulebookInfo. 
  4468.  
  4469. The name and description fields may both contain wildcards. 
  4470.  
  4471. On subsequent calls, the handle pointed to is non-zero and both the initial 
  4472. contents of the structure and the mask are ignored; the next rulebook which 
  4473. matches the criteria is returned in the structure.  When there are no more file 
  4474. filters to list, the handle is set back to 0 to indicate that the list has 
  4475. finished. 
  4476.  
  4477. If you want to interrupt the listing operation before getting to the last item, 
  4478. you should call PsnsCloseList to free the list handle. 
  4479.  
  4480.  
  4481. ΓòÉΓòÉΓòÉ <hidden> PsnsListRulebooks - Related functions ΓòÉΓòÉΓòÉ
  4482.  
  4483.      PsnsCreateRulebook 
  4484.  
  4485.      PsnsDeleteRulebook 
  4486.  
  4487.      PsnsRenameRulebook 
  4488.  
  4489.      PsnsCopyRulebook 
  4490.  
  4491.      PsnsRulebookInfo 
  4492.  
  4493.  
  4494. ΓòÉΓòÉΓòÉ 3.56. PsnsListSourceDrives ΓòÉΓòÉΓòÉ
  4495.  
  4496. Select an item 
  4497.  
  4498.      Syntax 
  4499.      Parameters 
  4500.      Returns 
  4501.      Remarks 
  4502.      Example 
  4503.      Related functions 
  4504.  
  4505.  
  4506. ΓòÉΓòÉΓòÉ <hidden> PsnsListSourceDrives - Syntax ΓòÉΓòÉΓòÉ
  4507.  
  4508. /****************************************************/
  4509. /* This function lists source drives which match    */
  4510. /* certain criteria.                                */
  4511. /****************************************************/
  4512.  
  4513. int PsnsListSourceDrives(PSNSHANDLE handle,
  4514.                          PHPSNSLIST pHPsnsList,
  4515.                          PSOURCEDRIVEINFO pSourceDriveInfo,
  4516.                          long mask);
  4517.  
  4518.  
  4519. ΓòÉΓòÉΓòÉ <hidden> PsnsListSourceDrives - Parameters ΓòÉΓòÉΓòÉ
  4520.  
  4521.  handle (PSNSHANDLE) 
  4522.            Handle returned by PsnsInit. 
  4523.  
  4524.  pHPsnsList (PHPSNSLIST) 
  4525.            Pointer to a list handle. 
  4526.  
  4527.  pSourceDriveInfo (PSOURCEDRIVEINFO) 
  4528.            Pointer to a SOURCEDRIVEINFO structure where the source drives found 
  4529.            will be returned.  On the first call, this contains the criteria to 
  4530.            search against. 
  4531.  
  4532.  mask (long) 
  4533.            Possible values: 
  4534.  
  4535.                 DR_NONE 
  4536.                 DR_LETTER 
  4537.                 DR_TYPE 
  4538.                 DR_SELECTED 
  4539.                 DR_ALL 
  4540.  
  4541.            To search on more than one field, OR the different values together. 
  4542.            To list all source drives, use mask = DR_NONE. 
  4543.  
  4544.  
  4545. ΓòÉΓòÉΓòÉ <hidden> PsnsListSourceDrives - Returns ΓòÉΓòÉΓòÉ
  4546.  
  4547.       PSNS_OK 
  4548.       PSNS_HANDLE_IN_USE 
  4549.       PSNS_COMMUNICATIONS_ERROR 
  4550.       PSNS_INVALID_HANDLE 
  4551.       PSNS_INVALID_LIST_HANDLE 
  4552.       PSNS_NO_MORE_HANDLES 
  4553.       PSNS_INVALID_MASK 
  4554.  
  4555.  
  4556. ΓòÉΓòÉΓòÉ <hidden> PsnsListSourceDrives - Remarks ΓòÉΓòÉΓòÉ
  4557.  
  4558. On the first call to PsnsListSourceDrives, pHPsnsList should point to an 
  4559. HPSNSLIST which has been initialised to 0.  You should pass the search criteria 
  4560. in pSourceDriveInfo and set the mask according to which fields you want to 
  4561. search on.  On return from this call, the handle pointed to will have been set 
  4562. to a new list handle number, and the first source drive which matches the 
  4563. search criteria is copied into the structure pointed to by pSourceDriveInfo. 
  4564.  
  4565. On subsequent calls, the handle pointed to is non-zero and both the initial 
  4566. contents of the structure and the mask are ignored; the next source drive which 
  4567. matches the criteria is returned in the structure.  When there are no more 
  4568. source drives to list, the handle is set back to 0 to indicate that the list 
  4569. has finished. 
  4570.  
  4571. If you want to interrupt the listing operation before getting to the last item, 
  4572. you should call PsnsCloseList to free the list handle. 
  4573.  
  4574.  
  4575. ΓòÉΓòÉΓòÉ <hidden> PsnsListSourceDrives - Related functions ΓòÉΓòÉΓòÉ
  4576.  
  4577.      PsnsSelectSourceDrive 
  4578.  
  4579.      PsnsRefreshSourceDrives 
  4580.  
  4581.      PsnsSourceDriveType 
  4582.  
  4583.  
  4584. ΓòÉΓòÉΓòÉ 3.57. PsnsListStorageDevices ΓòÉΓòÉΓòÉ
  4585.  
  4586. Select an item 
  4587.  
  4588.      Syntax 
  4589.      Parameters 
  4590.      Returns 
  4591.      Remarks 
  4592.      Example 
  4593.      Related functions 
  4594.  
  4595.  
  4596. ΓòÉΓòÉΓòÉ <hidden> PsnsListStorageDevices - Syntax ΓòÉΓòÉΓòÉ
  4597.  
  4598. /****************************************************/
  4599. /* This function lists storage devices which match  */
  4600. /* certain criteria.                                */
  4601. /****************************************************/
  4602.  
  4603. int PsnsListStorageDevices(PSNSHANDLE handle,
  4604.                            PHPSNSLIST pHPsnsList,
  4605.                            PSTORAGEDEVICEINFO pStorageDeviceInfo,
  4606.                            long mask);
  4607.  
  4608.  
  4609. ΓòÉΓòÉΓòÉ <hidden> PsnsListStorageDevices - Parameters ΓòÉΓòÉΓòÉ
  4610.  
  4611.  handle (PSNSHANDLE) 
  4612.            Handle returned by PsnsInit. 
  4613.  
  4614.  pHPsnsList (PHPSNSLIST) 
  4615.            Pointer to a list handle. 
  4616.  
  4617.  pStorageDeviceInfo (PSTORAGEDEVICEINFO) 
  4618.            Pointer to a STORAGEDEVICEINFO structure where the storage devices 
  4619.            found will be returned.  On the first call, this contains the 
  4620.            criteria to search against. 
  4621.  
  4622.  mask (long) 
  4623.            Possible values: 
  4624.  
  4625.                 SD_NONE 
  4626.                 SD_NAME 
  4627.                 SD_DLLNAME 
  4628.                 SD_CREATABLE 
  4629.                 SD_ALL 
  4630.  
  4631.            To search on more than one field, OR the different values together. 
  4632.            To list all backup methods, use mask = SD_NONE. 
  4633.  
  4634.  
  4635. ΓòÉΓòÉΓòÉ <hidden> PsnsListStorageDevices - Returns ΓòÉΓòÉΓòÉ
  4636.  
  4637.       PSNS_OK 
  4638.       PSNS_HANDLE_IN_USE 
  4639.       PSNS_COMMUNICATIONS_ERROR 
  4640.       PSNS_INVALID_HANDLE 
  4641.       PSNS_INVALID_LIST_HANDLE 
  4642.       PSNS_NO_MORE_HANDLES 
  4643.       PSNS_INVALID_MASK 
  4644.  
  4645.  
  4646. ΓòÉΓòÉΓòÉ <hidden> PsnsListStorageDevices - Remarks ΓòÉΓòÉΓòÉ
  4647.  
  4648. On the first call to PsnsListStorageDevices, pHPsnsList should point to an 
  4649. HPSNSLIST which has been initialised to 0.  You should pass the search criteria 
  4650. in pStorageDeviceInfo and set the mask according to which fields you want to 
  4651. search on.  On return from this call, the handle pointed to will have been set 
  4652. to a new list handle number, and the first storage device which matches the 
  4653. search criteria is copied into the structure pointed to by pStorageDeviceInfo. 
  4654.  
  4655. On subsequent calls, the handle pointed to is non-zero and both the initial 
  4656. contents of the structure and the mask are ignored; the next storage device 
  4657. which matches the criteria is returned in the structure.  When there are no 
  4658. more storage devices to list, the handle is set back to 0 to indicate that the 
  4659. list has finished. 
  4660.  
  4661. If you want to interrupt the listing operation before getting to the last item, 
  4662. you should call PsnsCloseList to free the list handle. 
  4663.  
  4664.  
  4665. ΓòÉΓòÉΓòÉ <hidden> PsnsListStorageDevices - Related functions ΓòÉΓòÉΓòÉ
  4666.  
  4667.      PsnsCreateStorageDevice 
  4668.  
  4669.      PsnsDeleteStorageDevice 
  4670.  
  4671.      PsnsStorageDeviceInfo 
  4672.  
  4673.      PsnsSetStorageDeviceConfig 
  4674.  
  4675.      PsnsGetStorageDeviceConfig 
  4676.  
  4677.      PsnsRefreshStorageDevices 
  4678.  
  4679.  
  4680. ΓòÉΓòÉΓòÉ 3.58. PsnsListVolumeBackupSets ΓòÉΓòÉΓòÉ
  4681.  
  4682. Select an item 
  4683.  
  4684.      Syntax 
  4685.      Parameters 
  4686.      Returns 
  4687.      Remarks 
  4688.      Example 
  4689.      Related functions 
  4690.  
  4691.  
  4692. ΓòÉΓòÉΓòÉ <hidden> PsnsListVolumeBackupSets - Syntax ΓòÉΓòÉΓòÉ
  4693.  
  4694. /****************************************************/
  4695. /* This function lists backup sets on a given       */
  4696. /* volume.                                          */
  4697. /****************************************************/
  4698.  
  4699. int PsnsListVolumeBackupSets(PSNSHANDLE handle,
  4700.                              PHPSNSLIST pHPsnsList,
  4701.                              const char *storageDevice,
  4702.                              PBACKUPSETVOLUME pBackupSetVolume);
  4703.  
  4704.  
  4705. ΓòÉΓòÉΓòÉ <hidden> PsnsListVolumeBackupSets - Parameters ΓòÉΓòÉΓòÉ
  4706.  
  4707.  handle (PSNSHANDLE) 
  4708.            Handle returned by PsnsInit. 
  4709.  
  4710.  pHPsnsList (PHPSNSLIST) 
  4711.            Pointer to a list handle. 
  4712.  
  4713.  storageDevice (const char *) 
  4714.            (Optional) Name of the storage device on which to find the volume. 
  4715.  
  4716.  pBackupSetVolume (PBACKUPSETVOLUME) 
  4717.            Pointer to a BACKUPSETVOLUMEINFO structure where the backup sets 
  4718.            found will be returned. 
  4719.  
  4720.  
  4721. ΓòÉΓòÉΓòÉ <hidden> PsnsListVolumeBackupSets - Returns ΓòÉΓòÉΓòÉ
  4722.  
  4723.       PSNS_OK 
  4724.       PSNS_HANDLE_IN_USE 
  4725.       PSNS_COMMUNICATIONS_ERROR 
  4726.       PSNS_INVALID_HANDLE 
  4727.       PSNS_INVALID_LIST_HANDLE 
  4728.       PSNS_NO_MORE_HANDLES 
  4729.       PSNS_INVALID_MASK 
  4730.       PSNS_INVALID_VOLUME 
  4731.  
  4732.  
  4733. ΓòÉΓòÉΓòÉ <hidden> PsnsListVolumeBackupSets - Remarks ΓòÉΓòÉΓòÉ
  4734.  
  4735. On the first call to PsnsListVolumeBackupSets, pHPsnsList should point to an 
  4736. HPSNSLIST which has been initialised to 0. You should set the id field in 
  4737. *pBackupSetVolume to the ID of the volume for which you want to list backup 
  4738. sets. On return from this call, the handle pointed to will have been set to a 
  4739. new list handle number, and the first backup set on the volume is copied into 
  4740. the structure pointed to by pBackupSetVolume. 
  4741.  
  4742. On subsequent calls, the handle pointed to is non-zero and both the initial 
  4743. contents of the structure and the mask are ignored; the next backup set on the 
  4744. volume is returned in the structure. When there are no more backup sets to 
  4745. list, the handle is set back to 0 to indicate that the list has finished. 
  4746.  
  4747. If you want to interrupt the listing operation before getting to the last item, 
  4748. you should call PsnsCloseList to free the list handle. 
  4749.  
  4750. If the optional storageDevice parameter is filled in, then OS/2 Warp Server 
  4751. Backup/Restore will look at the volume in the storage device and generate a 
  4752. list of backup sets on the storage device. 
  4753.  
  4754.  
  4755. ΓòÉΓòÉΓòÉ <hidden> PsnsListVolumeBackupSets - Related functions ΓòÉΓòÉΓòÉ
  4756.  
  4757.      PsnsVolumeInfo 
  4758.  
  4759.      PsnsListVolumes 
  4760.  
  4761.  
  4762. ΓòÉΓòÉΓòÉ 3.59. PsnsListVolumes ΓòÉΓòÉΓòÉ
  4763.  
  4764. Select an item 
  4765.  
  4766.      Syntax 
  4767.      Parameters 
  4768.      Returns 
  4769.      Remarks 
  4770.      Example 
  4771.      Related functions 
  4772.  
  4773.  
  4774. ΓòÉΓòÉΓòÉ <hidden> PsnsListVolumes - Syntax ΓòÉΓòÉΓòÉ
  4775.  
  4776. /****************************************************/
  4777. /* This function lists volumes which match certain  */
  4778. /* criteria.                                        */
  4779. /****************************************************/
  4780.  
  4781. int PsnsListVolumes(PSNSHANDLE handle,
  4782.                     PHPSNSLIST pHPsnsList,
  4783.                     PVOLUMEINFO pVolumeInfo,
  4784.                     long mask);
  4785.  
  4786.  
  4787. ΓòÉΓòÉΓòÉ <hidden> PsnsListVolumes - Parameters ΓòÉΓòÉΓòÉ
  4788.  
  4789.  handle (PSNSHANDLE) 
  4790.            Handle returned by PsnsInit. 
  4791.  
  4792.  pHPsnsList (PHPSNSLIST) 
  4793.            Pointer to a list handle. 
  4794.  
  4795.  pVolumeInfo (PVOLUMEINFO) 
  4796.            Pointer to a VOLUMEINFO structure where the volumes found will be 
  4797.            returned.  On the first call, this contains the criteria to search 
  4798.            against. 
  4799.  
  4800.  mask (long) 
  4801.            Possible values: 
  4802.  
  4803.                 VOL_NONE 
  4804.                 VOL_NAME 
  4805.                 VOL_STORAGEDEVICE 
  4806.                 VOL_TRANSFERREDOUT 
  4807.                 VOL_AVAILABLE 
  4808.                 VOL_BACKUPSETS 
  4809.                 VOL_TOTALCAPACITY_LESS 
  4810.                 VOL_TOTALCAPACITY_MORE 
  4811.                 VOL_PSNSCAPACITY_LESS 
  4812.                 VOL_PSNSCAPACITY_MORE 
  4813.                 VOL_PSNSUSED_LESS 
  4814.                 VOL_PSNSUSED_MORE 
  4815.                 VOL_PSNSFREE_LESS 
  4816.                 VOL_PSNSFREE_MORE 
  4817.                 VOL_OTHERFREE_LESS 
  4818.                 VOL_OTHERFREE_MORE 
  4819.                 VOL_OTHERUSED_LESS 
  4820.                 VOL_OTHERUSED_MORE 
  4821.                 VOL_TOTALBAD_LESS 
  4822.                 VOL_TOTALBAD_MORE 
  4823.                 VOL_BACKUPSET 
  4824.                 VOL_INDEXNO 
  4825.                 VOL_ALL 
  4826.  
  4827.            To search on more than one field, OR the different values together. 
  4828.            To list all volumes, use mask = VOL_NONE. 
  4829.  
  4830.  
  4831. ΓòÉΓòÉΓòÉ <hidden> PsnsListVolumes - Returns ΓòÉΓòÉΓòÉ
  4832.  
  4833.       PSNS_OK 
  4834.       PSNS_HANDLE_IN_USE 
  4835.       PSNS_COMMUNICATIONS_ERROR 
  4836.       PSNS_INVALID_HANDLE 
  4837.       PSNS_INVALID_LIST_HANDLE 
  4838.       PSNS_NO_MORE_HANDLES 
  4839.       PSNS_INVALID_MASK 
  4840.  
  4841.  
  4842. ΓòÉΓòÉΓòÉ <hidden> PsnsListVolumes - Remarks ΓòÉΓòÉΓòÉ
  4843.  
  4844. On the first call to PsnsListVolumes, pHPsnsList should point to an HPSNSLIST 
  4845. which has been initialised to 0.  You should pass the search criteria in 
  4846. pVolumeInfo and set the mask according to which fields you want to search on. 
  4847. On return from this call, the handle pointed to will have been set to a new 
  4848. list handle number, and the first volume which matches the search criteria is 
  4849. copied into the structure pointed to by pVolumeInfo. The name, storageDevice 
  4850. and backupSet fields may all contain wildcards. 
  4851.  
  4852. On subsequent calls, the handle pointed to is non-zero and both the initial 
  4853. contents of the structure and the mask are ignored; the next volume which 
  4854. matches the criteria is returned in the structure.  When there are no more 
  4855. volumes to list, the handle is set back to 0 to indicate that the list has 
  4856. finished. 
  4857.  
  4858. If you want to interrupt the listing operation before getting to the last item, 
  4859. you should call PsnsCloseList to free the list handle. 
  4860.  
  4861.  
  4862. ΓòÉΓòÉΓòÉ <hidden> PsnsListVolumes - Related functions ΓòÉΓòÉΓòÉ
  4863.  
  4864.      PsnsCreateVolume 
  4865.  
  4866.      PsnsDeleteVolume 
  4867.  
  4868.      PsnsVolumeInfo 
  4869.  
  4870.      PsnsListVolumeBackupSets 
  4871.  
  4872.      PsnsActivateVolume 
  4873.  
  4874.      PsnsAssociateVolume 
  4875.  
  4876.  
  4877. ΓòÉΓòÉΓòÉ 3.60. PsnsMessageCallback ΓòÉΓòÉΓòÉ
  4878.  
  4879. Select an item 
  4880.  
  4881.      Syntax 
  4882.      Parameters 
  4883.      Returns 
  4884.      Remarks 
  4885.      Example 
  4886.      Related functions 
  4887.  
  4888.  
  4889. ΓòÉΓòÉΓòÉ <hidden> PsnsMessageCallback - Syntax ΓòÉΓòÉΓòÉ
  4890.  
  4891. /****************************************************/
  4892. /* This function registers a callback function for  */
  4893. /* user messages.                                   */
  4894. /****************************************************/
  4895.  
  4896. int PsnsMessageCallback(PSNSHANDLE handle,
  4897.                         PSNSMESSAGEFN function,
  4898.                         void *privates);
  4899.  
  4900.  
  4901. ΓòÉΓòÉΓòÉ <hidden> PsnsMessageCallback - Parameters ΓòÉΓòÉΓòÉ
  4902.  
  4903.  handle (PSNSHANDLE) 
  4904.            Handle returned by PsnsInit. 
  4905.  
  4906.  function (PSNSMESSAGEFN) 
  4907.            Pointer to a callback function. 
  4908.  
  4909.  privates (void *) 
  4910.            This pointer will be passed to the callback function whenever it is 
  4911.            called, so can be used to provide some sort of context information. 
  4912.  
  4913.  
  4914. ΓòÉΓòÉΓòÉ <hidden> PsnsMessageCallback - Returns ΓòÉΓòÉΓòÉ
  4915.  
  4916.       PSNS_OK 
  4917.       PSNS_HANDLE_IN_USE 
  4918.       PSNS_COMMUNICATIONS_ERROR 
  4919.       PSNS_INVALID_HANDLE 
  4920.  
  4921.  
  4922. ΓòÉΓòÉΓòÉ <hidden> PsnsMessageCallback - Remarks ΓòÉΓòÉΓòÉ
  4923.  
  4924. Use this function to register a callback function for user messages.  This will 
  4925. be called whenever there is a message which should be shown to the user or 
  4926. might require a response from the user.  This function is called whenever a 
  4927. message box would appear if OS/2 Warp Server Backup/Restore were running in a 
  4928. graphical environment.  For more information on the callback function, see 
  4929. PSNSMESSAGEFN. 
  4930.  
  4931. Note that the function does not necessarily have to involve the user; for 
  4932. example, when running unattended it might be more useful to simply log the 
  4933. message and return PSNSM_DEFAULT to take the default action. 
  4934.  
  4935.  
  4936. ΓòÉΓòÉΓòÉ <hidden> PsnsMessageCallback - Related functions ΓòÉΓòÉΓòÉ
  4937.  
  4938.  
  4939. ΓòÉΓòÉΓòÉ 3.61. PsnsPurgeFiles ΓòÉΓòÉΓòÉ
  4940.  
  4941. Select an item 
  4942.  
  4943.      Syntax 
  4944.      Parameters 
  4945.      Returns 
  4946.      Remarks 
  4947.      Example 
  4948.      Related functions 
  4949.  
  4950.  
  4951. ΓòÉΓòÉΓòÉ <hidden> PsnsPurgeFiles - Syntax ΓòÉΓòÉΓòÉ
  4952.  
  4953. /****************************************************/
  4954. /* This function empties the list of files to be    */
  4955. /* backed up or restored                            */
  4956. /****************************************************/
  4957.  
  4958. int PsnsPurgeFiles(PSNSHANDLE handle);
  4959.  
  4960.  
  4961. ΓòÉΓòÉΓòÉ <hidden> PsnsPurgeFiles - Parameters ΓòÉΓòÉΓòÉ
  4962.  
  4963.  handle (PSNSHANDLE) 
  4964.            Handle returned by PsnsInit. 
  4965.  
  4966.  
  4967. ΓòÉΓòÉΓòÉ <hidden> PsnsPurgeFiles - Returns ΓòÉΓòÉΓòÉ
  4968.  
  4969.       PSNS_OK 
  4970.       PSNS_HANDLE_IN_USE 
  4971.       PSNS_COMMUNICATIONS_ERROR 
  4972.       PSNS_INVALID_HANDLE 
  4973.  
  4974.  
  4975. ΓòÉΓòÉΓòÉ <hidden> PsnsPurgeFiles - Remarks ΓòÉΓòÉΓòÉ
  4976.  
  4977. Use this function to empty the list of files which you have created using 
  4978. PsnsAddFile.  This means that you can start creating a new list of files to be 
  4979. backed up or restored.  Note that this function does nothing to the files you 
  4980. have added to the list, it simply empties the list. 
  4981.  
  4982.  
  4983. ΓòÉΓòÉΓòÉ <hidden> PsnsPurgeFiles - Related functions ΓòÉΓòÉΓòÉ
  4984.  
  4985.      PsnsAddFile 
  4986.  
  4987.      PsnsBackupFiles 
  4988.  
  4989.      PsnsRestoreFiles 
  4990.  
  4991.  
  4992. ΓòÉΓòÉΓòÉ 3.62. PsnsRefreshSourceDrives ΓòÉΓòÉΓòÉ
  4993.  
  4994. Select an item 
  4995.  
  4996.      Syntax 
  4997.      Parameters 
  4998.      Returns 
  4999.      Remarks 
  5000.      Example 
  5001.      Related functions 
  5002.  
  5003.  
  5004. ΓòÉΓòÉΓòÉ <hidden> PsnsRefreshSourceDrives - Syntax ΓòÉΓòÉΓòÉ
  5005.  
  5006. /****************************************************/
  5007. /* This function looks for drives on the system and */
  5008. /* refreshes the list of source drives.             */
  5009. /****************************************************/
  5010.  
  5011. int PsnsRefreshSourceDrives(PSNSHANDLE handle);
  5012.  
  5013.  
  5014. ΓòÉΓòÉΓòÉ <hidden> PsnsRefreshSourceDrives - Parameters ΓòÉΓòÉΓòÉ
  5015.  
  5016.  handle (PSNSHANDLE) 
  5017.            Handle returned by PsnsInit. 
  5018.  
  5019.  
  5020. ΓòÉΓòÉΓòÉ <hidden> PsnsRefreshSourceDrives - Returns ΓòÉΓòÉΓòÉ
  5021.  
  5022.       PSNS_OK 
  5023.       PSNS_HANDLE_IN_USE 
  5024.       PSNS_COMMUNICATIONS_ERROR 
  5025.       PSNS_INVALID_HANDLE 
  5026.  
  5027.  
  5028. ΓòÉΓòÉΓòÉ <hidden> PsnsRefreshSourceDrives - Remarks ΓòÉΓòÉΓòÉ
  5029.  
  5030. Use this function to make OS/2 Warp Server Backup/Restore scan for drives and 
  5031. automatically refresh the list of source drives.  This is automatically done 
  5032. every time OS/2 Warp Server Backup/Restore starts up. 
  5033.  
  5034.  
  5035. ΓòÉΓòÉΓòÉ <hidden> PsnsRefreshSourceDrives - Related functions ΓòÉΓòÉΓòÉ
  5036.  
  5037.      PsnsListSourceDrives 
  5038.  
  5039.      PsnsSelectSourceDrive 
  5040.  
  5041.      PsnsSourceDriveType 
  5042.  
  5043.  
  5044. ΓòÉΓòÉΓòÉ 3.63. PsnsRefreshStorageDevices ΓòÉΓòÉΓòÉ
  5045.  
  5046. Select an item 
  5047.  
  5048.      Syntax 
  5049.      Parameters 
  5050.      Returns 
  5051.      Remarks 
  5052.      Example 
  5053.      Related functions 
  5054.  
  5055.  
  5056. ΓòÉΓòÉΓòÉ <hidden> PsnsRefreshStorageDevices - Syntax ΓòÉΓòÉΓòÉ
  5057.  
  5058. /****************************************************/
  5059. /* This function looks for locally attached storage */
  5060. /* devices and automatically adds them to the list  */
  5061. /* of storage devices.                              */
  5062. /****************************************************/
  5063.  
  5064. int PsnsRefreshStorageDevices(PSNSHANDLE handle);
  5065.  
  5066.  
  5067. ΓòÉΓòÉΓòÉ <hidden> PsnsRefreshStorageDevices - Parameters ΓòÉΓòÉΓòÉ
  5068.  
  5069.  handle (PSNSHANDLE) 
  5070.            Handle returned by PsnsInit. 
  5071.  
  5072.  
  5073. ΓòÉΓòÉΓòÉ <hidden> PsnsRefreshStorageDevices - Returns ΓòÉΓòÉΓòÉ
  5074.  
  5075.       PSNS_OK 
  5076.       PSNS_HANDLE_IN_USE 
  5077.       PSNS_COMMUNICATIONS_ERROR 
  5078.       PSNS_INVALID_HANDLE 
  5079.  
  5080.  
  5081. ΓòÉΓòÉΓòÉ <hidden> PsnsRefreshStorageDevices - Remarks ΓòÉΓòÉΓòÉ
  5082.  
  5083. Use this function to make OS/2 Warp Server Backup/Restore scan for locally 
  5084. attached storage devices and add them to the list of storage devices.  This 
  5085. happens automatically every time OS/2 Warp Server Backup/Restore starts up. 
  5086.  
  5087.  
  5088. ΓòÉΓòÉΓòÉ <hidden> PsnsRefreshStorageDevices - Related functions ΓòÉΓòÉΓòÉ
  5089.  
  5090.      PsnsCreateStorageDevice 
  5091.  
  5092.      PsnsDeleteStorageDevice 
  5093.  
  5094.      PsnsStorageDeviceInfo 
  5095.  
  5096.      PsnsSetStorageDeviceConfig 
  5097.  
  5098.      PsnsGetStorageDeviceConfig 
  5099.  
  5100.      PsnsListStorageDevices 
  5101.  
  5102.  
  5103. ΓòÉΓòÉΓòÉ 3.64. PsnsRenameBackupMethod ΓòÉΓòÉΓòÉ
  5104.  
  5105. Select an item 
  5106.  
  5107.      Syntax 
  5108.      Parameters 
  5109.      Returns 
  5110.      Remarks 
  5111.      Example 
  5112.      Related functions 
  5113.  
  5114.  
  5115. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameBackupMethod - Syntax ΓòÉΓòÉΓòÉ
  5116.  
  5117. /****************************************************/
  5118. /* This function renames an existing backup method. */
  5119. /****************************************************/
  5120.  
  5121. int PsnsRenameBackupMethod(PSNSHANDLE handle,
  5122.                            const char *name,
  5123.                            const char *newName);
  5124.  
  5125.  
  5126. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameBackupMethod - Parameters ΓòÉΓòÉΓòÉ
  5127.  
  5128.  handle (PSNSHANDLE) 
  5129.            Handle returned by PsnsInit. 
  5130.  
  5131.  name (const char *) 
  5132.            Name of the backup method to be renamed. 
  5133.  
  5134.  newName (const char *) 
  5135.            New name for the backup method. 
  5136.  
  5137.  
  5138. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameBackupMethod - Returns ΓòÉΓòÉΓòÉ
  5139.  
  5140.       PSNS_OK 
  5141.       PSNS_HANDLE_IN_USE 
  5142.       PSNS_COMMUNICATIONS_ERROR 
  5143.       PSNS_INVALID_HANDLE 
  5144.       PSNS_INVALID_BACKUP_METHOD 
  5145.       PSNS_ALREADY_EXISTS 
  5146.       PSNS_INVALID_NAME 
  5147.       PSNS_IN_USE 
  5148.  
  5149.  
  5150. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameBackupMethod - Remarks ΓòÉΓòÉΓòÉ
  5151.  
  5152. Use this function to rename a backup method.  newName must not be the name of 
  5153. any existing backup method. 
  5154.  
  5155.  
  5156. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameBackupMethod - Related functions ΓòÉΓòÉΓòÉ
  5157.  
  5158.      PsnsCreateBackupMethod 
  5159.  
  5160.      PsnsDeleteBackupMethod 
  5161.  
  5162.      PsnsCopyBackupMethod 
  5163.  
  5164.      PsnsBackupMethodInfo 
  5165.  
  5166.      PsnsListBackupMethods 
  5167.  
  5168.      PsnsEstimateBackupMethod 
  5169.  
  5170.      PsnsRunBackupMethod 
  5171.  
  5172.  
  5173. ΓòÉΓòÉΓòÉ 3.65. PsnsRenameFileFilter ΓòÉΓòÉΓòÉ
  5174.  
  5175. Select an item 
  5176.  
  5177.      Syntax 
  5178.      Parameters 
  5179.      Returns 
  5180.      Remarks 
  5181.      Example 
  5182.      Related functions 
  5183.  
  5184.  
  5185. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameFileFilter - Syntax ΓòÉΓòÉΓòÉ
  5186.  
  5187. /****************************************************/
  5188. /* This function renames an existing file filter.   */
  5189. /****************************************************/
  5190.  
  5191. int PsnsRenameFileFilter(PSNSHANDLE handle,
  5192.                          const char *name,
  5193.                          const char *newName);
  5194.  
  5195.  
  5196. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameFileFilter - Parameters ΓòÉΓòÉΓòÉ
  5197.  
  5198.  handle (PSNSHANDLE) 
  5199.            Handle returned by PsnsInit. 
  5200.  
  5201.  name (const char *) 
  5202.            Name of the file filter to be renamed. 
  5203.  
  5204.  newName (const char *) 
  5205.            New name for the file filter. 
  5206.  
  5207.  
  5208. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameFileFilter - Returns ΓòÉΓòÉΓòÉ
  5209.  
  5210.       PSNS_OK 
  5211.       PSNS_HANDLE_IN_USE 
  5212.       PSNS_COMMUNICATIONS_ERROR 
  5213.       PSNS_INVALID_HANDLE 
  5214.       PSNS_INVALID_FILE_FILTER 
  5215.       PSNS_ALREADY_EXISTS 
  5216.       PSNS_INVALID_NAME 
  5217.       PSNS_IN_USE 
  5218.  
  5219.  
  5220. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameFileFilter - Remarks ΓòÉΓòÉΓòÉ
  5221.  
  5222. Use this function to rename a file filter.  newName must not be the name of any 
  5223. existing file filter. 
  5224.  
  5225.  
  5226. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameFileFilter - Related functions ΓòÉΓòÉΓòÉ
  5227.  
  5228.      PsnsCreateFileFilter 
  5229.  
  5230.      PsnsDeleteFileFilter 
  5231.  
  5232.      PsnsCopyFileFilter 
  5233.  
  5234.      PsnsFileFilterInfo 
  5235.  
  5236.      PsnsListFileFilters 
  5237.  
  5238.  
  5239. ΓòÉΓòÉΓòÉ 3.66. PsnsRenameRestoreMethod ΓòÉΓòÉΓòÉ
  5240.  
  5241. Select an item 
  5242.  
  5243.      Syntax 
  5244.      Parameters 
  5245.      Returns 
  5246.      Remarks 
  5247.      Example 
  5248.      Related functions 
  5249.  
  5250.  
  5251. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameRestoreMethod - Syntax ΓòÉΓòÉΓòÉ
  5252.  
  5253. /****************************************************/
  5254. /* This function renames an existing restore method */
  5255. /****************************************************/
  5256.  
  5257. int PsnsRenameRestoreMethod(PSNSHANDLE handle,
  5258.                             const char *name,
  5259.                             const char *newName);
  5260.  
  5261.  
  5262. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameRestoreMethod - Parameters ΓòÉΓòÉΓòÉ
  5263.  
  5264.  handle (PSNSHANDLE) 
  5265.            Handle returned by PsnsInit. 
  5266.  
  5267.  name (const char *) 
  5268.            Name of the restore method to be renamed. 
  5269.  
  5270.  newName (const char *) 
  5271.            New name for the restore method. 
  5272.  
  5273.  
  5274. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameRestoreMethod - Returns ΓòÉΓòÉΓòÉ
  5275.  
  5276.       PSNS_OK 
  5277.       PSNS_HANDLE_IN_USE 
  5278.       PSNS_COMMUNICATIONS_ERROR 
  5279.       PSNS_INVALID_HANDLE 
  5280.       PSNS_INVALID_RESTORE_METHOD 
  5281.       PSNS_ALREADY_EXISTS 
  5282.       PSNS_INVALID_NAME 
  5283.       PSNS_IN_USE 
  5284.  
  5285.  
  5286. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameRestoreMethod - Remarks ΓòÉΓòÉΓòÉ
  5287.  
  5288. Use this function to rename a restore method.  newName must not be the name of 
  5289. any existing restore method. 
  5290.  
  5291.  
  5292. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameRestoreMethod - Related functions ΓòÉΓòÉΓòÉ
  5293.  
  5294.      PsnsCreateRestoreMethod 
  5295.  
  5296.      PsnsDeleteRestoreMethod 
  5297.  
  5298.      PsnsCopyRestoreMethod 
  5299.  
  5300.      PsnsRestoreMethodInfo 
  5301.  
  5302.      PsnsListRestoreMethods 
  5303.  
  5304.      PsnsEstimateRestoreMethod 
  5305.  
  5306.      PsnsRunRestoreMethod 
  5307.  
  5308.  
  5309. ΓòÉΓòÉΓòÉ 3.67. PsnsRenameRulebook ΓòÉΓòÉΓòÉ
  5310.  
  5311. Select an item 
  5312.  
  5313.      Syntax 
  5314.      Parameters 
  5315.      Returns 
  5316.      Remarks 
  5317.      Example 
  5318.      Related functions 
  5319.  
  5320.  
  5321. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameRulebook - Syntax ΓòÉΓòÉΓòÉ
  5322.  
  5323. /****************************************************/
  5324. /* This function renames an existing rulebook.      */
  5325. /****************************************************/
  5326.  
  5327. int PsnsRenameRulebook(PSNSHANDLE handle,
  5328.                        const char *name,
  5329.                        const char *newName);
  5330.  
  5331.  
  5332. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameRulebook - Parameters ΓòÉΓòÉΓòÉ
  5333.  
  5334.  handle (PSNSHANDLE) 
  5335.            Handle returned by PsnsInit. 
  5336.  
  5337.  name (const char *) 
  5338.            Name of the rulebook to be renamed. 
  5339.  
  5340.  newName (const char *) 
  5341.            New name for the rulebook. 
  5342.  
  5343.  
  5344. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameRulebook - Returns ΓòÉΓòÉΓòÉ
  5345.  
  5346.       PSNS_OK 
  5347.       PSNS_HANDLE_IN_USE 
  5348.       PSNS_COMMUNICATIONS_ERROR 
  5349.       PSNS_INVALID_HANDLE 
  5350.       PSNS_INVALID_RULEBOOK 
  5351.       PSNS_ALREADY_EXISTS 
  5352.       PSNS_INVALID_NAME 
  5353.       PSNS_IN_USE 
  5354.  
  5355.  
  5356. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameRulebook - Remarks ΓòÉΓòÉΓòÉ
  5357.  
  5358. Use this function to rename a rulebook.  newName must not be the name of any 
  5359. existing rulebook. 
  5360.  
  5361.  
  5362. ΓòÉΓòÉΓòÉ <hidden> PsnsRenameRulebook - Related functions ΓòÉΓòÉΓòÉ
  5363.  
  5364.      PsnsCreateRulebook 
  5365.  
  5366.      PsnsDeleteRulebook 
  5367.  
  5368.      PsnsCopyRulebook 
  5369.  
  5370.      PsnsRulebookInfo 
  5371.  
  5372.      PsnsListRulebooks 
  5373.  
  5374.  
  5375. ΓòÉΓòÉΓòÉ 3.68. PsnsRestoreFiles ΓòÉΓòÉΓòÉ
  5376.  
  5377. Select an item 
  5378.  
  5379.      Syntax 
  5380.      Parameters 
  5381.      Returns 
  5382.      Remarks 
  5383.      Example 
  5384.      Related functions 
  5385.  
  5386.  
  5387. ΓòÉΓòÉΓòÉ <hidden> PsnsRestoreFiles - Syntax ΓòÉΓòÉΓòÉ
  5388.  
  5389. /****************************************************/
  5390. /* This function restores a list of files created   */
  5391. /* by calls to PsnsAddFile.                         */
  5392. /****************************************************/
  5393.  
  5394. int PsnsRestoreFiles(PSNSHANDLE handle,
  5395.                      PRESTOREMETHODINFO pRestoreMethodInfo,
  5396.                      PSNSSTATSFN psnsStatsFn);
  5397.  
  5398.  
  5399. ΓòÉΓòÉΓòÉ <hidden> PsnsRestoreFiles - Parameters ΓòÉΓòÉΓòÉ
  5400.  
  5401.  handle (PSNSHANDLE) 
  5402.            Handle returned by PsnsInit. 
  5403.  
  5404.  pRestoreMethodInfo (RESTOREMETHODINFO) 
  5405.            Pointer to a RESTOREMETHODINFO structure that contains settings 
  5406.            which control how the restore method runs.  The only fields in the 
  5407.            structure which need to be set are: 
  5408.  
  5409.                backupSet 
  5410.  
  5411.            All other fields are ignored by this function. 
  5412.  
  5413.  psnsStatsFn (PSNSSTATSFN) 
  5414.            Pointer to a statistics callback function.  This can be NULL. 
  5415.  
  5416.  
  5417. ΓòÉΓòÉΓòÉ <hidden> PsnsRestoreFiles - Returns ΓòÉΓòÉΓòÉ
  5418.  
  5419.       PSNS_OK 
  5420.       PSNS_HANDLE_IN_USE 
  5421.       PSNS_COMMUNICATIONS_ERROR 
  5422.       PSNS_INVALID_HANDLE 
  5423.       PSNS_INVALID_BACKUP_SET 
  5424.       PSNS_TRANSFERRED_OUT 
  5425.       PSNS_IN_USE 
  5426.  
  5427.  
  5428. ΓòÉΓòÉΓòÉ <hidden> PsnsRestoreFiles - Remarks ΓòÉΓòÉΓòÉ
  5429.  
  5430. Use this function to restore a list of files.  The callback function, if 
  5431. provided, is called whenever the statistics (number of files, folder and bytes 
  5432. restored) have changed, or whenever there is a message which might interest the 
  5433. user.  For more information on the statistics callback function, see 
  5434. PSNSSTATSFN. 
  5435.  
  5436.  
  5437. ΓòÉΓòÉΓòÉ <hidden> PsnsRestoreFiles - Related functions ΓòÉΓòÉΓòÉ
  5438.  
  5439.      PsnsAddFile 
  5440.  
  5441.      PsnsRestoreFiles 
  5442.  
  5443.      PsnsDropFiles 
  5444.  
  5445.      PsnsPurgeFiles 
  5446.  
  5447.  
  5448. ΓòÉΓòÉΓòÉ 3.69. PsnsRestoreMethodInfo ΓòÉΓòÉΓòÉ
  5449.  
  5450. Select an item 
  5451.  
  5452.      Syntax 
  5453.      Parameters 
  5454.      Returns 
  5455.      Remarks 
  5456.      Example 
  5457.      Related functions 
  5458.  
  5459.  
  5460. ΓòÉΓòÉΓòÉ <hidden> PsnsRestoreMethodInfo - Syntax ΓòÉΓòÉΓòÉ
  5461.  
  5462. /****************************************************/
  5463. /* This function gets or sets all the information   */
  5464. /* about a restore method.                          */
  5465. /****************************************************/
  5466.  
  5467. int PsnsRestoreMethodInfo(PSNSHANDLE handle,
  5468.                           const char *name,
  5469.                           PRESTOREMETHODINFO pRestoreMethodInfo,
  5470.                           long mask);
  5471.  
  5472.  
  5473. ΓòÉΓòÉΓòÉ <hidden> PsnsRestoreMethodInfo - Parameters ΓòÉΓòÉΓòÉ
  5474.  
  5475.  handle (PSNSHANDLE) 
  5476.            Handle returned by PsnsInit. 
  5477.  
  5478.  name (const char *) 
  5479.            Name of the restore method to be inspected or changed. 
  5480.  
  5481.  pRestoreMethodInfo (PRESTOREMETHODINFO) 
  5482.            Pointer to a RESTOREMETHODINFO structure which contains the new 
  5483.            settings if they are to be changed, and to receive the current 
  5484.            settings.  If the corresponding bit in mask is set then the settings 
  5485.            will be changed to what is passed in this structure.  The new 
  5486.            settings are returned in this structure.  To get the settings 
  5487.            without changing them, set mask = RM_NONE. 
  5488.  
  5489.  mask (long) 
  5490.            Possible values: 
  5491.  
  5492.                 RM_NONE 
  5493.                 RM_NAME 
  5494.                 RM_DESCRIPTION 
  5495.                 RM_BACKUPSET 
  5496.                 RM_ALLFILES 
  5497.                 RM_DRIVE 
  5498.                 RM_DIRECTORY 
  5499.                 RM_PATTERN 
  5500.                 RM_SUBDIRECTORIES 
  5501.                 RM_BYDATE 
  5502.                 RM_PREVIEW 
  5503.                 RM_PROMPT 
  5504.                 RM_ORIGINALLOCATION 
  5505.                 RM_DESTINATIONDRIVE 
  5506.                 RM_DESTINATIONPATH 
  5507.  
  5508.            To set more than one setting, OR the different values together.  To 
  5509.            set all the settings, use mask = RM_ALL. 
  5510.  
  5511.  
  5512. ΓòÉΓòÉΓòÉ <hidden> PsnsRestoreMethodInfo - Returns ΓòÉΓòÉΓòÉ
  5513.  
  5514.       PSNS_OK 
  5515.       PSNS_HANDLE_IN_USE 
  5516.       PSNS_COMMUNICATIONS_ERROR 
  5517.       PSNS_INVALID_HANDLE 
  5518.       PSNS_INVALID_RESTORE_METHOD 
  5519.       PSNS_INVALID_BACKUP_SET 
  5520.       PSNS_INVALID_DRIVE 
  5521.       PSNS_INVALID_PATH 
  5522.       PSNS_INVALID_FILENAME 
  5523.       PSNS_INVALID_MASK 
  5524.       PSNS_IN_USE 
  5525.  
  5526.  
  5527. ΓòÉΓòÉΓòÉ <hidden> PsnsRestoreMethodInfo - Remarks ΓòÉΓòÉΓòÉ
  5528.  
  5529. Use this function to change a restore method or to inspect the current settings 
  5530. for a restore method.  The mask parameter defines which settings are being 
  5531. changed.  For more information on the individual fields, see RESTOREMETHODINFO. 
  5532.  
  5533. It is not possible to change the name of a restore method with this call; to do 
  5534. that, use PsnsRenameRestoreMethod. 
  5535.  
  5536.  
  5537. ΓòÉΓòÉΓòÉ <hidden> PsnsRestoreMethodInfo - Related functions ΓòÉΓòÉΓòÉ
  5538.  
  5539.      PsnsCreateRestoreMethod 
  5540.  
  5541.      PsnsDeleteRestoreMethod 
  5542.  
  5543.      PsnsRenameRestoreMethod 
  5544.  
  5545.      PsnsCopyRestoreMethod 
  5546.  
  5547.      PsnsListRestoreMethods 
  5548.  
  5549.      PsnsEstimateRestoreMethod 
  5550.  
  5551.      PsnsRunRestoreMethod 
  5552.  
  5553.  
  5554. ΓòÉΓòÉΓòÉ 3.70. PsnsRulebookInfo ΓòÉΓòÉΓòÉ
  5555.  
  5556. Select an item 
  5557.  
  5558.      Syntax 
  5559.      Parameters 
  5560.      Returns 
  5561.      Remarks 
  5562.      Example 
  5563.      Related functions 
  5564.  
  5565.  
  5566. ΓòÉΓòÉΓòÉ <hidden> PsnsRulebookInfo - Syntax ΓòÉΓòÉΓòÉ
  5567.  
  5568. /****************************************************/
  5569. /* This function gets or sets all the information   */
  5570. /* about a rulebook.                                */
  5571. /****************************************************/
  5572.  
  5573. int PsnsRulebookInfo(PSNSHANDLE handle,
  5574.                      const char *name,
  5575.                      PRULEBOOKINFO pRulebookInfo,
  5576.                      long mask);
  5577.  
  5578.  
  5579. ΓòÉΓòÉΓòÉ <hidden> PsnsRulebookInfo - Parameters ΓòÉΓòÉΓòÉ
  5580.  
  5581.  handle (PSNSHANDLE) 
  5582.            Handle returned by PsnsInit. 
  5583.  
  5584.  name (const char *) 
  5585.            Name of the rulebook to be inspected or changed. 
  5586.  
  5587.  pRulebookInfo (PRULEBOOKINFO) 
  5588.            Pointer to a RULEBOOKINFO structure which contains the new settings 
  5589.            if they are to be changed, and to receive the current settings.  If 
  5590.            the corresponding bit in mask is set then the settings will be 
  5591.            changed to what is passed in this structure.  The new settings are 
  5592.            returned in this structure.  To get the settings without changing 
  5593.            them, set mask = RB_NONE. 
  5594.  
  5595.  mask (long) 
  5596.            Possible values: 
  5597.  
  5598.                 RB_NONE 
  5599.                 RB_DESCRIPTION 
  5600.                 RB_ALL 
  5601.  
  5602.            To set more than one setting, OR the different values together.  To 
  5603.            set all the settings, use mask = RB_ALL. 
  5604.  
  5605.  
  5606. ΓòÉΓòÉΓòÉ <hidden> PsnsRulebookInfo - Returns ΓòÉΓòÉΓòÉ
  5607.  
  5608.       PSNS_OK 
  5609.       PSNS_HANDLE_IN_USE 
  5610.       PSNS_COMMUNICATIONS_ERROR 
  5611.       PSNS_INVALID_HANDLE 
  5612.       PSNS_INVALID_RULEBOOK 
  5613.       PSNS_IN_USE 
  5614.       PSNS_INVALID_MASK 
  5615.  
  5616.  
  5617. ΓòÉΓòÉΓòÉ <hidden> PsnsRulebookInfo - Remarks ΓòÉΓòÉΓòÉ
  5618.  
  5619. Use this function to change a rulebook or to inspect the current settings for a 
  5620. rulebook.  The mask parameter defines which settings are being changed.  For 
  5621. more information on the individual fields, see RULEBOOKINFO. 
  5622.  
  5623. It is not possible to change the name of a rulebook with this call; to do that, 
  5624. use PsnsRenameRulebook. 
  5625.  
  5626.  
  5627. ΓòÉΓòÉΓòÉ <hidden> PsnsRulebookInfo - Related functions ΓòÉΓòÉΓòÉ
  5628.  
  5629.      PsnsCreateRulebook 
  5630.  
  5631.      PsnsDeleteRulebook 
  5632.  
  5633.      PsnsRenameRulebook 
  5634.  
  5635.      PsnsCopyRulebook 
  5636.  
  5637.      PsnsRulebookInfo 
  5638.  
  5639.      PsnsListRulebooks 
  5640.  
  5641.      PsnsAddRulebookRule 
  5642.  
  5643.      PsnsDeleteRulebookRule 
  5644.  
  5645.      PsnsRulebookRuleInfo 
  5646.  
  5647.  
  5648. ΓòÉΓòÉΓòÉ 3.71. PsnsRulebookRuleInfo ΓòÉΓòÉΓòÉ
  5649.  
  5650. Select an item 
  5651.  
  5652.      Syntax 
  5653.      Parameters 
  5654.      Returns 
  5655.      Remarks 
  5656.      Example 
  5657.      Related functions 
  5658.  
  5659.  
  5660. ΓòÉΓòÉΓòÉ <hidden> PsnsRulebookRuleInfo - Syntax ΓòÉΓòÉΓòÉ
  5661.  
  5662. /****************************************************/
  5663. /* This function gets or sets all the information   */
  5664. /* about a rule in a rulebook.                      */
  5665. /****************************************************/
  5666.  
  5667. int PsnsRulebookRuleInfo(PSNSHANDLE handle,
  5668.                          const char *rulebook,
  5669.                          int which,
  5670.                          PRULEBOOKRULE pRulebookRule,
  5671.                          long mask);
  5672.  
  5673.  
  5674. ΓòÉΓòÉΓòÉ <hidden> PsnsRulebookRuleInfo - Parameters ΓòÉΓòÉΓòÉ
  5675.  
  5676.  handle (PSNSHANDLE) 
  5677.            Handle returned by PsnsInit. 
  5678.  
  5679.  rulebook (const char *) 
  5680.            Name of the rulebook to be inspected or changed. 
  5681.  
  5682.  which (int) 
  5683.            Number of the rule to be inspected or changed (the first rule is 1). 
  5684.  
  5685.  pRulebookRule (RULEBOOKRULE) 
  5686.            Pointer to a RULEBOOKRULE structure which contains the new settings 
  5687.            if they are to be changed, and to receive the current settings.  If 
  5688.            the corresponding bit in mask is set then the settings will be 
  5689.            changed to what is passed in this structure.  The new settings are 
  5690.            returned in this structure.  To get the settings without changing 
  5691.            them, set mask = RB_NONE. 
  5692.  
  5693.  mask (long) 
  5694.            Possible values: 
  5695.  
  5696.                 RB_NONE 
  5697.                 RB_DRIVE 
  5698.                 RB_DIRECTORY 
  5699.                 RB_PATTERN 
  5700.                 RB_GENERATIONS 
  5701.                 RB_COMPRESSION 
  5702.  
  5703.            To set more than one setting, OR the different values together.  To 
  5704.            set all the settings, use mask = RB_ALL. 
  5705.  
  5706.  
  5707. ΓòÉΓòÉΓòÉ <hidden> PsnsRulebookRuleInfo - Returns ΓòÉΓòÉΓòÉ
  5708.  
  5709.       PSNS_OK 
  5710.       PSNS_HANDLE_IN_USE 
  5711.       PSNS_COMMUNICATIONS_ERROR 
  5712.       PSNS_INVALID_HANDLE 
  5713.       PSNS_INVALID_RULEBOOK 
  5714.       PSNS_INVALID_POSITION 
  5715.       PSNS_INVALID_DRIVE 
  5716.       PSNS_INVALID_PATH 
  5717.       PSNS_INVALID_FILENAME 
  5718.       PSNS_INVALID_GENERATIONS 
  5719.       PSNS_INVALID_COMPRESSION 
  5720.       PSNS_IN_USE 
  5721.       PSNS_INVALID_MASK 
  5722.       PSNS_READONLY 
  5723.  
  5724.  
  5725. ΓòÉΓòÉΓòÉ <hidden> PsnsRulebookRuleInfo - Remarks ΓòÉΓòÉΓòÉ
  5726.  
  5727. Use this function to change a rulebook rule or to inspect the current settings 
  5728. for a rulebook rule.  The mask parameter defines which settings are being 
  5729. changed.  For more information on the individual fields, see RULEBOOKRULE. 
  5730.  
  5731.  
  5732. ΓòÉΓòÉΓòÉ <hidden> PsnsRulebookRuleInfo - Related functions ΓòÉΓòÉΓòÉ
  5733.  
  5734.      PsnsRulebookInfo 
  5735.  
  5736.      PsnsAddRulebookRule 
  5737.  
  5738.      PsnsDeleteRulebookRule 
  5739.  
  5740.  
  5741. ΓòÉΓòÉΓòÉ 3.72. PsnsRunBackupMethod ΓòÉΓòÉΓòÉ
  5742.  
  5743. Select an item 
  5744.  
  5745.      Syntax 
  5746.      Parameters 
  5747.      Returns 
  5748.      Remarks 
  5749.      Example 
  5750.      Related functions 
  5751.  
  5752.  
  5753. ΓòÉΓòÉΓòÉ <hidden> PsnsRunBackupMethod - Syntax ΓòÉΓòÉΓòÉ
  5754.  
  5755. /****************************************************/
  5756. /* This function runs a backup method.              */
  5757. /****************************************************/
  5758.  
  5759. int PsnsRunBackupMethod(PSNSHANDLE handle,
  5760.                         const char *name,
  5761.                         PSNSSTATSFN psnsStatsFn);
  5762.  
  5763.  
  5764. ΓòÉΓòÉΓòÉ <hidden> PsnsRunBackupMethod - Parameters ΓòÉΓòÉΓòÉ
  5765.  
  5766.  handle (PSNSHANDLE) 
  5767.            Handle returned by PsnsInit. 
  5768.  
  5769.  name (const char *) 
  5770.            Name of the backup method to be run. 
  5771.  
  5772.  psnsStatsFn (PSNSSTATSFN) 
  5773.            Pointer to a statistics callback function.  This can be NULL. 
  5774.  
  5775.  
  5776. ΓòÉΓòÉΓòÉ <hidden> PsnsRunBackupMethod - Returns ΓòÉΓòÉΓòÉ
  5777.  
  5778.       PSNS_OK 
  5779.       PSNS_HANDLE_IN_USE 
  5780.       PSNS_COMMUNICATIONS_ERROR 
  5781.       PSNS_INVALID_HANDLE 
  5782.       PSNS_INVALID_BACKUP_METHOD 
  5783.       PSNS_ARCHIVE_ERROR 
  5784.       PSNS_IN_USE 
  5785.       PSNS_TRANSFERRED_OUT 
  5786.  
  5787.  
  5788. ΓòÉΓòÉΓòÉ <hidden> PsnsRunBackupMethod - Remarks ΓòÉΓòÉΓòÉ
  5789.  
  5790. Use this function to run a backup method.  The callback function, if provided, 
  5791. is called whenever the statistics (number of files, folder and bytes backed up) 
  5792. have changed, or whenever there is a message which might interest the user. 
  5793. For more information on the statistics callback function, see PSNSSTATSFN. 
  5794.  
  5795.  
  5796. ΓòÉΓòÉΓòÉ <hidden> PsnsRunBackupMethod - Related functions ΓòÉΓòÉΓòÉ
  5797.  
  5798.      PsnsEstimateBackupMethod 
  5799.  
  5800.      PsnsEstimateRestoreMethod 
  5801.  
  5802.      PsnsRunRestoreMethod 
  5803.  
  5804.  
  5805. ΓòÉΓòÉΓòÉ 3.73. PsnsRunRestoreMethod ΓòÉΓòÉΓòÉ
  5806.  
  5807. Select an item 
  5808.  
  5809.      Syntax 
  5810.      Parameters 
  5811.      Returns 
  5812.      Remarks 
  5813.      Example 
  5814.      Related functions 
  5815.  
  5816.  
  5817. ΓòÉΓòÉΓòÉ <hidden> PsnsRunRestoreMethod - Syntax ΓòÉΓòÉΓòÉ
  5818.  
  5819. /****************************************************/
  5820. /* This function runs a restore method.             */
  5821. /****************************************************/
  5822.  
  5823. int PsnsRunRestoreMethod(PSNSHANDLE handle,
  5824.                          const char *name,
  5825.                          PSNSSTATSFN psnsStatsFn,
  5826.                          BOOL base,
  5827.                          BOOL incremental);
  5828.  
  5829.  
  5830. ΓòÉΓòÉΓòÉ <hidden> PsnsRunRestoreMethod - Parameters ΓòÉΓòÉΓòÉ
  5831.  
  5832.  handle (PSNSHANDLE) 
  5833.            Handle returned by PsnsInit. 
  5834.  
  5835.  name (const char *) 
  5836.            Name of the restore method to be run. 
  5837.  
  5838.  psnsStatsFn (PSNSSTATSFN) 
  5839.            Pointer to a statistics callback function.  This can be NULL. 
  5840.  
  5841.  base (BOOL) 
  5842.            This parameter is only used when running a restore method that 
  5843.            references a dual device backup set.  It is ignored for single 
  5844.            device backup sets. 
  5845.  
  5846.            TRUE           Restore from the base storage device. 
  5847.            FALSE          Do not restore from the base storage device. 
  5848.  
  5849.  incremental (BOOL) 
  5850.            This parameter is only used when running a restore method that 
  5851.            references a dual device backup set.  It is ignored for single 
  5852.            device backup sets. 
  5853.  
  5854.            TRUE           Restore from the incremental storage device. 
  5855.            FALSE          Do not restore from the incremental storage device. 
  5856.  
  5857.  
  5858. ΓòÉΓòÉΓòÉ <hidden> PsnsRunRestoreMethod - Returns ΓòÉΓòÉΓòÉ
  5859.  
  5860.       PSNS_OK 
  5861.       PSNS_HANDLE_IN_USE 
  5862.       PSNS_COMMUNICATIONS_ERROR 
  5863.       PSNS_INVALID_HANDLE 
  5864.       PSNS_INVALID_RESTORE_METHOD 
  5865.       PSNS_IN_USE 
  5866.       PSNS_ARCHIVE_ERROR 
  5867.       PSNS_TRANSFERRED_OUT 
  5868.  
  5869.  
  5870. ΓòÉΓòÉΓòÉ <hidden> PsnsRunRestoreMethod - Remarks ΓòÉΓòÉΓòÉ
  5871.  
  5872. Use this function to run a restore method.  The callback function, if provided, 
  5873. is called whenever the statistics (number of files, folder and bytes restored) 
  5874. have changed, or whenever there is a message which might interest the user. 
  5875. For more information on the statistics callback function, see PSNSSTATSFN. 
  5876.  
  5877. When restoring from a dual device backup set you must set at least one of the 
  5878. base and incremental parameters to be true.  For single device backup sets 
  5879. these parameters are ignored. 
  5880.  
  5881.  
  5882. ΓòÉΓòÉΓòÉ <hidden> PsnsRunRestoreMethod - Related functions ΓòÉΓòÉΓòÉ
  5883.  
  5884.      PsnsEstimateRestoreMethod 
  5885.  
  5886.      PsnsEstimateBackupMethod 
  5887.  
  5888.      PsnsRunBackupMethod 
  5889.  
  5890.  
  5891. ΓòÉΓòÉΓòÉ 3.74. PsnsSelectSourceDrive ΓòÉΓòÉΓòÉ
  5892.  
  5893. Select an item 
  5894.  
  5895.      Syntax 
  5896.      Parameters 
  5897.      Returns 
  5898.      Remarks 
  5899.      Example 
  5900.      Related functions 
  5901.  
  5902.  
  5903. ΓòÉΓòÉΓòÉ <hidden> PsnsSelectSourceDrive - Syntax ΓòÉΓòÉΓòÉ
  5904.  
  5905. /****************************************************/
  5906. /* This function selects whether or not a source    */
  5907. /* drive should be checked for files to back up.    */
  5908. /****************************************************/
  5909.  
  5910. int PsnsSelectSourceDrive(PSNSHANDLE handle,
  5911.                           char drive,
  5912.                           BOOL use);
  5913.  
  5914.  
  5915. ΓòÉΓòÉΓòÉ <hidden> PsnsSelectSourceDrive - Parameters ΓòÉΓòÉΓòÉ
  5916.  
  5917.  handle (PSNSHANDLE) 
  5918.            Handle returned by PsnsInit. 
  5919.  
  5920.  drive (char) 
  5921.            Drive letter to select or deselect. 
  5922.  
  5923.  use (BOOL) 
  5924.  
  5925.            TRUE           Select this source drive for backup. 
  5926.            FALSE          Deselect this source drive for backup. 
  5927.  
  5928.  
  5929. ΓòÉΓòÉΓòÉ <hidden> PsnsSelectSourceDrive - Returns ΓòÉΓòÉΓòÉ
  5930.  
  5931.       PSNS_OK 
  5932.       PSNS_HANDLE_IN_USE 
  5933.       PSNS_COMMUNICATIONS_ERROR 
  5934.       PSNS_INVALID_HANDLE 
  5935.       PSNS_INVALID_SOURCE_DRIVE 
  5936.  
  5937.  
  5938. ΓòÉΓòÉΓòÉ <hidden> PsnsSelectSourceDrive - Remarks ΓòÉΓòÉΓòÉ
  5939.  
  5940. Use this function to tell OS/2 Warp Server Backup/Restore whether or not to 
  5941. check a source drive for files when performing a backup.  For example, if you 
  5942. had a backup method to back up all program source files on your computer, you 
  5943. would probably want to check all local drives but not check any network drives 
  5944. you have attached. 
  5945.  
  5946. By default, local drives are selected and remote drives are not selected. 
  5947.  
  5948.  
  5949. ΓòÉΓòÉΓòÉ <hidden> PsnsSelectSourceDrive - Related functions ΓòÉΓòÉΓòÉ
  5950.  
  5951.      PsnsListSourceDrives 
  5952.  
  5953.      PsnsRefreshSourceDrives 
  5954.  
  5955.      PsnsSourceDriveType 
  5956.  
  5957.  
  5958. ΓòÉΓòÉΓòÉ 3.75. PsnsSetBackupSetConfig ΓòÉΓòÉΓòÉ
  5959.  
  5960. Select an item 
  5961.  
  5962.      Syntax 
  5963.      Parameters 
  5964.      Returns 
  5965.      Remarks 
  5966.      Example 
  5967.      Related functions 
  5968.  
  5969.  
  5970. ΓòÉΓòÉΓòÉ <hidden> PsnsSetBackupSetConfig - Syntax ΓòÉΓòÉΓòÉ
  5971.  
  5972. /****************************************************/
  5973. /* This function sets the configuration information */
  5974. /* for a backup set.                                */
  5975. /****************************************************/
  5976.  
  5977. int PsnsSetBackupSetConfig(PSNSHANDLE handle,
  5978.                            const char *name,
  5979.                            const char *config,
  5980.                            const char *incConfig);
  5981.  
  5982.  
  5983. ΓòÉΓòÉΓòÉ <hidden> PsnsSetBackupSetConfig - Parameters ΓòÉΓòÉΓòÉ
  5984.  
  5985.  handle (PSNSHANDLE) 
  5986.            Handle returned by PsnsInit. 
  5987.  
  5988.  name (const char *) 
  5989.            Name of the backup set to be configured. 
  5990.  
  5991.  config (const char *) 
  5992.            Configuration string for the backup set.  The format of this string 
  5993.            depends on which storage device the backup set uses.  For dual 
  5994.            device backup sets this is the configuration string for the base 
  5995.            backup set. 
  5996.  
  5997.  incConfig (const char *) 
  5998.            Configuration string for the incremental storage device of a dual 
  5999.            device backup set. The format of this string depends on which 
  6000.            incremental storage device the dual device backup set uses.  For 
  6001.            single device backup sets this parameter should be passed as NULL. 
  6002.  
  6003.  
  6004. ΓòÉΓòÉΓòÉ <hidden> PsnsSetBackupSetConfig - Returns ΓòÉΓòÉΓòÉ
  6005.  
  6006.       PSNS_OK 
  6007.       PSNS_HANDLE_IN_USE 
  6008.       PSNS_COMMUNICATIONS_ERROR 
  6009.       PSNS_INVALID_HANDLE 
  6010.       PSNS_INVALID_BACKUP_SET 
  6011.       PSNS_INVALID_CONFIGURATION 
  6012.       PSNS_IN_USE 
  6013.       PSNS_TRANSFERRED_OUT 
  6014.       PSNS_INVALID_KEYWORD 
  6015.       PSNS_INVALID_VALUE 
  6016.       PSNS_SYNTAX_ERROR 
  6017.       PSNS_INCOMPLETE_STRING 
  6018.       PSNS_SEMANTIC_ERROR 
  6019.  
  6020.  
  6021. ΓòÉΓòÉΓòÉ <hidden> PsnsSetBackupSetConfig - Remarks ΓòÉΓòÉΓòÉ
  6022.  
  6023. Use this function to set the configuration information for a backup set. The 
  6024. format of this information depends on the storage device which the backup set 
  6025. uses; to find out how all the standard OS/2 Warp Server Backup/Restore storage 
  6026. devices handle this, see Storage Device Configuration. 
  6027.  
  6028.  
  6029. ΓòÉΓòÉΓòÉ <hidden> PsnsSetBackupSetConfig - Related functions ΓòÉΓòÉΓòÉ
  6030.  
  6031.      PsnsGetBackupSetConfig 
  6032.  
  6033.      PsnsSetStorageDeviceConfig 
  6034.  
  6035.      PsnsGetStorageDeviceConfig 
  6036.  
  6037.      PsnsTransferIn 
  6038.  
  6039.  
  6040. ΓòÉΓòÉΓòÉ 3.76. PsnsSetStorageDeviceConfig ΓòÉΓòÉΓòÉ
  6041.  
  6042. Select an item 
  6043.  
  6044.      Syntax 
  6045.      Parameters 
  6046.      Returns 
  6047.      Remarks 
  6048.      Example 
  6049.      Related functions 
  6050.  
  6051.  
  6052. ΓòÉΓòÉΓòÉ <hidden> PsnsSetStorageDeviceConfig - Syntax ΓòÉΓòÉΓòÉ
  6053.  
  6054. /****************************************************/
  6055. /* This function sets the configuration information */
  6056. /* for a storage device.                            */
  6057. /****************************************************/
  6058.  
  6059. int PsnsSetStorageDeviceConfig(PSNSHANDLE handle,
  6060.                                const char *name,
  6061.                                const char *config);
  6062.  
  6063.  
  6064. ΓòÉΓòÉΓòÉ <hidden> PsnsSetStorageDeviceConfig - Parameters ΓòÉΓòÉΓòÉ
  6065.  
  6066.  handle (PSNSHANDLE) 
  6067.            Handle returned by PsnsInit. 
  6068.  
  6069.  name (const char *) 
  6070.            Name of the storage device to be configured. 
  6071.  
  6072.  config (const char *) 
  6073.            Configuration string for the storage device.  The format of this 
  6074.            string depends on the storage device type. 
  6075.  
  6076.  
  6077. ΓòÉΓòÉΓòÉ <hidden> PsnsSetStorageDeviceConfig - Returns ΓòÉΓòÉΓòÉ
  6078.  
  6079.       PSNS_OK 
  6080.       PSNS_HANDLE_IN_USE 
  6081.       PSNS_COMMUNICATIONS_ERROR 
  6082.       PSNS_INVALID_HANDLE 
  6083.       PSNS_INVALID_STORAGE_DEVICE 
  6084.       PSNS_INVALID_CONFIGURATION 
  6085.       PSNS_IN_USE 
  6086.       PSNS_NOT_CONFIGURABLE 
  6087.       PSNS_INVALID_KEYWORD 
  6088.       PSNS_INVALID_VALUE 
  6089.       PSNS_SYNTAX_ERROR 
  6090.       PSNS_INCOMPLETE_STRING 
  6091.       PSNS_SEMANTIC_ERROR 
  6092.  
  6093.  
  6094. ΓòÉΓòÉΓòÉ <hidden> PsnsSetStorageDeviceConfig - Remarks ΓòÉΓòÉΓòÉ
  6095.  
  6096. Use this function to set the configuration information for a storage device. 
  6097. The only storage device currently changeable using this command is ADSM. The 
  6098. format of this information depends on the storage device; to find out how all 
  6099. the standard OS/2 Warp Server Backup/Restore storage devices handle this, see 
  6100. Storage Device Configuration. 
  6101.  
  6102.  
  6103. ΓòÉΓòÉΓòÉ <hidden> PsnsSetStorageDeviceConfig - Related functions ΓòÉΓòÉΓòÉ
  6104.  
  6105.      PsnsGetStorageDeviceConfig 
  6106.  
  6107.      PsnsSetBackupSetConfig 
  6108.  
  6109.      PsnsGetBackupSetConfig 
  6110.  
  6111.  
  6112. ΓòÉΓòÉΓòÉ 3.77. PsnsSettings ΓòÉΓòÉΓòÉ
  6113.  
  6114. Select an item 
  6115.  
  6116.      Syntax 
  6117.      Parameters 
  6118.      Returns 
  6119.      Remarks 
  6120.      Example 
  6121.      Related functions 
  6122.  
  6123.  
  6124. ΓòÉΓòÉΓòÉ <hidden> PsnsSettings - Syntax ΓòÉΓòÉΓòÉ
  6125.  
  6126. /****************************************************/
  6127. /* This function gets or sets many of the general   */
  6128. /* options.                                         */
  6129. /****************************************************/
  6130.  
  6131. int PsnsSettings(PSNSHANDLE handle,
  6132.                  PPSNSSETTINGS pPsnsSettings,
  6133.                  long mask);
  6134.  
  6135.  
  6136. ΓòÉΓòÉΓòÉ <hidden> PsnsSettings - Parameters ΓòÉΓòÉΓòÉ
  6137.  
  6138.  handle (PSNSHANDLE) 
  6139.            Handle returned by PsnsInit. 
  6140.  
  6141.  pPsnsSettings (PPSNSSETTINGS) 
  6142.            Pointer to a PSNSSETTINGS structure which contains the new settings, 
  6143.            if they are to be changed.  If the corresponding bit in mask is set 
  6144.            then the settings will be changed to what is passed in this 
  6145.            structure.  The new settings are returned in the structure.  To get 
  6146.            the settings without changing them at all, set mask = SET_NONE. 
  6147.  
  6148.  mask (long) 
  6149.            Possible values: 
  6150.  
  6151.                 SET_NONE 
  6152.                 SET_MANUALPRIORITY 
  6153.                 SET_AUTOPRIORITY 
  6154.                 SET_TEMPPATH 
  6155.                 SET_FLAGS 
  6156.                 SET_LOGFILELIMIT 
  6157.                 SET_BACKUPEXIT 
  6158.                 SET_RESTOREEXIT 
  6159.                 SET_ACLENABLE 
  6160.                 SET_ACLFILENAME 
  6161.                 SET_ALL 
  6162.  
  6163.            To set more than one setting, OR the different values together.  To 
  6164.            set all the settings, use mask = SET_ALL. 
  6165.  
  6166.  
  6167. ΓòÉΓòÉΓòÉ <hidden> PsnsSettings - Returns ΓòÉΓòÉΓòÉ
  6168.  
  6169.       PSNS_OK 
  6170.       PSNS_HANDLE_IN_USE 
  6171.       PSNS_COMMUNICATIONS_ERROR 
  6172.       PSNS_INVALID_HANDLE 
  6173.       PSNS_INVALID_PRIORITY 
  6174.       PSNS_INVALID_PATH 
  6175.       PSNS_INVALID_FLAGS 
  6176.       PSNS_INVALID_MASK 
  6177.  
  6178.  
  6179. ΓòÉΓòÉΓòÉ <hidden> PsnsSettings - Remarks ΓòÉΓòÉΓòÉ
  6180.  
  6181. Use this function to change the following settings: 
  6182.  
  6183.      Priority of backup and restore threads 
  6184.      Path for temporary files 
  6185.      Log file options 
  6186.      User exits 
  6187.  
  6188.  For more information on the individual options, see PSNSSETTINGS. 
  6189.  
  6190.  
  6191. ΓòÉΓòÉΓòÉ <hidden> PsnsSettings - Related functions ΓòÉΓòÉΓòÉ
  6192.  
  6193.      PsnsDefaults 
  6194.  
  6195.  
  6196. ΓòÉΓòÉΓòÉ 3.78. PsnsSourceDriveType ΓòÉΓòÉΓòÉ
  6197.  
  6198. Select an item 
  6199.  
  6200.      Syntax 
  6201.      Parameters 
  6202.      Returns 
  6203.      Remarks 
  6204.      Example 
  6205.      Related functions 
  6206.  
  6207.  
  6208. ΓòÉΓòÉΓòÉ <hidden> PsnsSourceDriveType - Syntax ΓòÉΓòÉΓòÉ
  6209.  
  6210. /****************************************************/
  6211. /* This function sets the type of a source drive.   */
  6212. /****************************************************/
  6213.  
  6214. int PsnsSourceDriveType(PSNSHANDLE handle,
  6215.                         char drive,
  6216.                         DRIVETYPE driveType);
  6217.  
  6218.  
  6219. ΓòÉΓòÉΓòÉ <hidden> PsnsSourceDriveType - Parameters ΓòÉΓòÉΓòÉ
  6220.  
  6221.  handle (PSNSHANDLE) 
  6222.            Handle returned by PsnsInit. 
  6223.  
  6224.  drive (char) 
  6225.            Drive letter of the source drive to be changed. 
  6226.  
  6227.  driveType (DRIVETYPE) 
  6228.            New type for the source drive. 
  6229.  
  6230.  
  6231. ΓòÉΓòÉΓòÉ <hidden> PsnsSourceDriveType - Returns ΓòÉΓòÉΓòÉ
  6232.  
  6233.       PSNS_OK 
  6234.       PSNS_HANDLE_IN_USE 
  6235.       PSNS_COMMUNICATIONS_ERROR 
  6236.       PSNS_INVALID_HANDLE 
  6237.       PSNS_INVALID_DRIVE_TYPE 
  6238.  
  6239.  
  6240. ΓòÉΓòÉΓòÉ <hidden> PsnsSourceDriveType - Remarks ΓòÉΓòÉΓòÉ
  6241.  
  6242. Use this function to tell OS/2 Warp Server Backup/Restore what type of drive a 
  6243. particular source drive is. Usually this should be detected automatically but 
  6244. this call allows you to override the automatic detection. 
  6245.  
  6246.  
  6247. ΓòÉΓòÉΓòÉ <hidden> PsnsSourceDriveType - Related functions ΓòÉΓòÉΓòÉ
  6248.  
  6249.      PsnsListSourceDrives 
  6250.  
  6251.      PsnsSelectSourceDrive 
  6252.  
  6253.      PsnsRefreshSourceDrives 
  6254.  
  6255.  
  6256. ΓòÉΓòÉΓòÉ 3.79. PsnsStorageDeviceInfo ΓòÉΓòÉΓòÉ
  6257.  
  6258. Select an item 
  6259.  
  6260.      Syntax 
  6261.      Parameters 
  6262.      Returns 
  6263.      Remarks 
  6264.      Example 
  6265.      Related functions 
  6266.  
  6267.  
  6268. ΓòÉΓòÉΓòÉ <hidden> PsnsStorageDeviceInfo - Syntax ΓòÉΓòÉΓòÉ
  6269.  
  6270. /****************************************************/
  6271. /* This function gets all the information           */
  6272. /* about a storage device.                          */
  6273. /****************************************************/
  6274.  
  6275. int PsnsStorageDeviceInfo(PSNSHANDLE handle,
  6276.                           const char *name,
  6277.                           PSTORAGEDEVICEINFO pStorageDevice,
  6278.                           long mask);
  6279.  
  6280.  
  6281. ΓòÉΓòÉΓòÉ <hidden> PsnsStorageDeviceInfo - Parameters ΓòÉΓòÉΓòÉ
  6282.  
  6283.  handle (PSNSHANDLE) 
  6284.            Handle returned by PsnsInit. 
  6285.  
  6286.  name (const char *) 
  6287.            Name of the storage device to be inspected. 
  6288.  
  6289.  pStorageDevice (PSTORAGEDEVICEINFO) 
  6290.            Pointer to a STORAGEDEVICEINFO structure to receive the storage 
  6291.            device information. 
  6292.  
  6293.  mask (long) 
  6294.            Reserved - must be SD_NONE. 
  6295.  
  6296.  
  6297. ΓòÉΓòÉΓòÉ <hidden> PsnsStorageDeviceInfo - Returns ΓòÉΓòÉΓòÉ
  6298.  
  6299.       PSNS_OK 
  6300.       PSNS_HANDLE_IN_USE 
  6301.       PSNS_COMMUNICATIONS_ERROR 
  6302.       PSNS_INVALID_HANDLE 
  6303.       PSNS_INVALID_STORAGE_DEVICE 
  6304.       PSNS_INVALID_MASK 
  6305.       PSNS_IN_USE 
  6306.  
  6307.  
  6308. ΓòÉΓòÉΓòÉ <hidden> PsnsStorageDeviceInfo - Remarks ΓòÉΓòÉΓòÉ
  6309.  
  6310. Use this function to get information about a storage device.  Since there are 
  6311. currently no storage device settings which can be modified, the mask parameter 
  6312. is unused.  For more information on the individual fields, see 
  6313. STORAGEDEVICEINFO. 
  6314.  
  6315.  
  6316. ΓòÉΓòÉΓòÉ <hidden> PsnsStorageDeviceInfo - Related functions ΓòÉΓòÉΓòÉ
  6317.  
  6318.      PsnsCreateStorageDevice 
  6319.  
  6320.      PsnsDeleteStorageDevice 
  6321.  
  6322.      PsnsSetStorageDeviceConfig 
  6323.  
  6324.      PsnsGetStorageDeviceConfig 
  6325.  
  6326.      PsnsListStorageDevices 
  6327.  
  6328.      PsnsRefreshStorageDevices 
  6329.  
  6330.  
  6331. ΓòÉΓòÉΓòÉ 3.80. PsnsTerm ΓòÉΓòÉΓòÉ
  6332.  
  6333. Select an item 
  6334.  
  6335.      Syntax 
  6336.      Parameters 
  6337.      Returns 
  6338.      Remarks 
  6339.      Example 
  6340.      Related functions 
  6341.  
  6342.  
  6343. ΓòÉΓòÉΓòÉ <hidden> PsnsTerm - Syntax ΓòÉΓòÉΓòÉ
  6344.  
  6345. /****************************************************/
  6346. /* This function terminates an API session and      */
  6347. /* frees the API handle.                            */
  6348. /****************************************************/
  6349.  
  6350. int PsnsTerm(PSNSHANDLE handle);
  6351.  
  6352.  
  6353. ΓòÉΓòÉΓòÉ <hidden> PsnsTerm - Parameters ΓòÉΓòÉΓòÉ
  6354.  
  6355.  handle (PSNSHANDLE) 
  6356.            Handle returned by PsnsInit. 
  6357.  
  6358.  
  6359. ΓòÉΓòÉΓòÉ <hidden> PsnsTerm - Returns ΓòÉΓòÉΓòÉ
  6360.  
  6361.       PSNS_OK 
  6362.       PSNS_HANDLE_IN_USE 
  6363.       PSNS_COMMUNICATIONS_ERROR 
  6364.       PSNS_INVALID_HANDLE 
  6365.  
  6366.  
  6367. ΓòÉΓòÉΓòÉ <hidden> PsnsTerm - Remarks ΓòÉΓòÉΓòÉ
  6368.  
  6369. You should call this function whenever you have finished with a handle which 
  6370. was obtained using PsnsInit. 
  6371.  
  6372.  
  6373. ΓòÉΓòÉΓòÉ <hidden> PsnsTerm - Related functions ΓòÉΓòÉΓòÉ
  6374.  
  6375.      PsnsInit 
  6376.  
  6377.  
  6378. ΓòÉΓòÉΓòÉ 3.81. PsnsTransferBackupSet ΓòÉΓòÉΓòÉ
  6379.  
  6380. Select an item 
  6381.  
  6382.      Syntax 
  6383.      Parameters 
  6384.      Returns 
  6385.      Remarks 
  6386.      Example 
  6387.      Related functions 
  6388.  
  6389.  
  6390. ΓòÉΓòÉΓòÉ <hidden> PsnsTransferBackupSet - Syntax ΓòÉΓòÉΓòÉ
  6391.  
  6392. /****************************************************/
  6393. /* This function transfers a backup set in or out.  */
  6394. /****************************************************/
  6395.  
  6396. int PsnsTransferBackupSet(PSNSHANDLE handle,
  6397.                           const char *name,
  6398.                           BOOL action,
  6399.                           BOOL base);
  6400.  
  6401.  
  6402. ΓòÉΓòÉΓòÉ <hidden> PsnsTransferBackupSet - Parameters ΓòÉΓòÉΓòÉ
  6403.  
  6404.  handle (PSNSHANDLE) 
  6405.            Handle returned by PsnsInit. 
  6406.  
  6407.  name (const char *) 
  6408.            Name of the backup set to be transferred in or out. 
  6409.  
  6410.  action (BOOL) 
  6411.  
  6412.            TRUE           Transfer the backup set in. 
  6413.            FALSE          Transfer the backup set out. 
  6414.  
  6415.  base (BOOL) 
  6416.            This parameter is only used when transferring out a dual device 
  6417.            backup set. It is ignored for single device backup sets and when 
  6418.            transferring in. 
  6419.  
  6420.            TRUE           Transfer out to the base storage device. 
  6421.            FALSE          Transfer out to the incremental storage device. 
  6422.  
  6423.  
  6424. ΓòÉΓòÉΓòÉ <hidden> PsnsTransferBackupSet - Returns ΓòÉΓòÉΓòÉ
  6425.  
  6426.       PSNS_OK 
  6427.       PSNS_HANDLE_IN_USE 
  6428.       PSNS_COMMUNICATIONS_ERROR 
  6429.       PSNS_INVALID_HANDLE 
  6430.       PSNS_INVALID_BACKUP_SET 
  6431.       PSNS_TRANSFERRED_OUT 
  6432.       PSNS_TRANSFERRED_IN 
  6433.  
  6434.  
  6435. ΓòÉΓòÉΓòÉ <hidden> PsnsTransferBackupSet - Remarks ΓòÉΓòÉΓòÉ
  6436.  
  6437. Use this function to transfer out or transfer in a backup set.  When a backup 
  6438. set is transferred out, you cannot use it for backing up or restoring, but you 
  6439. can take it to another computer and transfer it in to use the data on it. 
  6440. Transferring out ensures that all indexing information stored on the backup set 
  6441. media is up to date. 
  6442.  
  6443.  
  6444. ΓòÉΓòÉΓòÉ <hidden> PsnsTransferBackupSet - Related functions ΓòÉΓòÉΓòÉ
  6445.  
  6446.      PsnsCreateBackupSet 
  6447.  
  6448.      PsnsDeleteBackupSet 
  6449.  
  6450.      PsnsBackupSetInfo 
  6451.  
  6452.      PsnsSetBackupSetConfig 
  6453.  
  6454.      PsnsGetBackupSetConfig 
  6455.  
  6456.      PsnsListBackupSets 
  6457.  
  6458.      PsnsTransferIn 
  6459.  
  6460.      PsnsGetLogFile 
  6461.  
  6462.      PsnsEmptyBackupSet 
  6463.  
  6464.  
  6465. ΓòÉΓòÉΓòÉ 3.82. PsnsTransferIn ΓòÉΓòÉΓòÉ
  6466.  
  6467. Select an item 
  6468.  
  6469.      Syntax 
  6470.      Parameters 
  6471.      Returns 
  6472.      Remarks 
  6473.      Related functions 
  6474.  
  6475.  
  6476. ΓòÉΓòÉΓòÉ <hidden> PsnsTransferIn - Syntax ΓòÉΓòÉΓòÉ
  6477.  
  6478. /****************************************************/
  6479. /* This function transfers in a backup set from a   */
  6480. /* storage device.                                  */
  6481. /****************************************************/
  6482.  
  6483. int PsnsTransferIn(PSNSHANDLE handle,
  6484.                    const char *storageDevice,
  6485.                    const char *backupSet);
  6486.  
  6487.  
  6488. ΓòÉΓòÉΓòÉ <hidden> PsnsTransferIn - Parameters ΓòÉΓòÉΓòÉ
  6489.  
  6490.  handle (PSNSHANDLE) 
  6491.            Handle returned by PsnsInit. 
  6492.  
  6493.  storageDevice (const char *) 
  6494.            Name of the storage device from which to transfer in. 
  6495.  
  6496.  backupSet (const char *) 
  6497.            Name of the backup set to transfer in. 
  6498.  
  6499.  
  6500. ΓòÉΓòÉΓòÉ <hidden> PsnsTransferIn - Returns ΓòÉΓòÉΓòÉ
  6501.  
  6502.       PSNS_OK 
  6503.       PSNS_HANDLE_IN_USE 
  6504.       PSNS_COMMUNICATIONS_ERROR 
  6505.       PSNS_INVALID_HANDLE 
  6506.       PSNS_INVALID_STORAGE_DEVICE 
  6507.       PSNS_IN_USE 
  6508.  
  6509.  
  6510. ΓòÉΓòÉΓòÉ <hidden> PsnsTransferIn - Remarks ΓòÉΓòÉΓòÉ
  6511.  
  6512. Use this function to transfer in a backup set which OS/2 Warp Server 
  6513. Backup/Restore does not know about. This function reads all the indexing 
  6514. information off the backup set media and creates a new backup set which refers 
  6515. to it. 
  6516.  
  6517.  
  6518. ΓòÉΓòÉΓòÉ <hidden> PsnsTransferIn - Related functions ΓòÉΓòÉΓòÉ
  6519.  
  6520.      PsnsCreateBackupSet 
  6521.  
  6522.      PsnsDeleteBackupSet 
  6523.  
  6524.      PsnsBackupSetInfo 
  6525.  
  6526.      PsnsSetBackupSetConfig 
  6527.  
  6528.      PsnsGetBackupSetConfig 
  6529.  
  6530.      PsnsListBackupSets 
  6531.  
  6532.      PsnsTransferBackupSet 
  6533.  
  6534.      PsnsGetLogFile 
  6535.  
  6536.      PsnsEmptyBackupSet 
  6537.  
  6538.  
  6539. ΓòÉΓòÉΓòÉ 3.83. PsnsVolumeInfo ΓòÉΓòÉΓòÉ
  6540.  
  6541. Select an item 
  6542.  
  6543.      Syntax 
  6544.      Parameters 
  6545.      Returns 
  6546.      Remarks 
  6547.      Example 
  6548.      Related functions 
  6549.  
  6550.  
  6551. ΓòÉΓòÉΓòÉ <hidden> PsnsVolumeInfo - Syntax ΓòÉΓòÉΓòÉ
  6552.  
  6553. /****************************************************/
  6554. /* This function gets all the information about a   */
  6555. /* volume.                                          */
  6556. /****************************************************/
  6557.  
  6558. int PsnsVolumeInfo(PSNSHANDLE handle,
  6559.                    ULONG volumeID,
  6560.                    PVOLUMEINFO pVolumeInfo,
  6561.                    long mask);
  6562.  
  6563.  
  6564. ΓòÉΓòÉΓòÉ <hidden> PsnsVolumeInfo - Parameters ΓòÉΓòÉΓòÉ
  6565.  
  6566.  handle (PSNSHANDLE) 
  6567.            Handle returned by PsnsInit. 
  6568.  
  6569.  volumeID (ULONG) 
  6570.            ID of the volume to be inspected. 
  6571.  
  6572.  pVolumeInfo (PVOLUMEINFO) 
  6573.            Pointer to a VOLUMEINFO structure to receive the volume information. 
  6574.  
  6575.  mask (long) 
  6576.            Reserved - must be 0. 
  6577.  
  6578.  
  6579. ΓòÉΓòÉΓòÉ <hidden> PsnsVolumeInfo - Returns ΓòÉΓòÉΓòÉ
  6580.  
  6581.       PSNS_OK 
  6582.       PSNS_HANDLE_IN_USE 
  6583.       PSNS_COMMUNICATIONS_ERROR 
  6584.       PSNS_INVALID_HANDLE 
  6585.       PSNS_INVALID_VOLUME 
  6586.       PSNS_IN_USE 
  6587.       PSNS_INVALID_MASK 
  6588.  
  6589.  
  6590. ΓòÉΓòÉΓòÉ <hidden> PsnsVolumeInfo - Remarks ΓòÉΓòÉΓòÉ
  6591.  
  6592. Use this function to get information about a volume.  Since there are currently 
  6593. no volume settings which can be modified, the mask parameter is ignored. 
  6594.  
  6595.  
  6596. ΓòÉΓòÉΓòÉ <hidden> PsnsVolumeInfo - Related functions ΓòÉΓòÉΓòÉ
  6597.  
  6598.      PsnsCreateVolume 
  6599.  
  6600.      PsnsDeleteVolume 
  6601.  
  6602.      PsnsListVolumes 
  6603.  
  6604.      PsnsListVolumeBackupSets 
  6605.  
  6606.      PsnsActivateVolume 
  6607.  
  6608.      PsnsAssociateVolume 
  6609.  
  6610.  
  6611. ΓòÉΓòÉΓòÉ 4. Data types ΓòÉΓòÉΓòÉ
  6612.  
  6613. This section lists the data types defined by the OS/2 Warp Server 
  6614. Backup/Restore C API. 
  6615.  
  6616.      BACKUPMETHODINFO 
  6617.      BACKUPSETINFO 
  6618.      BACKUPSETVOLUME 
  6619.      DRIVETYPE 
  6620.      ESTIMATE 
  6621.      EVENTINFO 
  6622.      EVENTOPTION 
  6623.      EVENTTYPE 
  6624.      FILEFILTERINFO 
  6625.      FILEFILTERRULE 
  6626.      FILEFILTERTYPE 
  6627.      HPSNSLIST 
  6628.      PSNSCOMPRESSION 
  6629.      PSNSCONNECTION 
  6630.      PSNSDEFAULTS 
  6631.      PSNSFFB 
  6632.      PSNSFILEINFO 
  6633.      PSNSHANDLE 
  6634.      PSNSPIPEINFO 
  6635.      PSNSPRIORITY 
  6636.      PSNSSETTINGS 
  6637.      PSNSSTATSFN 
  6638.      RESTOREMETHODINFO 
  6639.      RULEBOOKINFO 
  6640.      RULEBOOKRULE 
  6641.      SOURCEDRIVEINFO 
  6642.      STORAGEDEVICEINFO 
  6643.      ULONG64 
  6644.      VOLUMEINFO 
  6645.  
  6646.  
  6647. ΓòÉΓòÉΓòÉ 4.1. BACKUPMETHODINFO ΓòÉΓòÉΓòÉ
  6648.  
  6649. typedef struct {
  6650.    char name[PSNS_NAME_SIZE + 1];
  6651.    char description[PSNS_DESCRIPTION_SIZE + 1];
  6652.    BOOL allFiles;
  6653.    char drive;
  6654.    char directory[CCHMAXPATH];
  6655.    BOOL subdirectories;
  6656.    PSNSCOMPRESSION compression;
  6657.    int generations;
  6658.    BOOL useRulebook;
  6659.    char rulebook[PSNS_NAME_SIZE + 1];
  6660.    BOOL useFileFilter;
  6661.    char fileFilter[PSNS_NAME_SIZE + 1];
  6662.    BOOL changedFilesOnly;
  6663.    BOOL preview;
  6664.    char backupSet[PSNS_NAME_SIZE + 1];
  6665. } BACKUPMETHODINFO, *PBACKUPMETHODINFO;
  6666.  
  6667.  name (char[]) 
  6668.            Name of the backup method. 
  6669.  
  6670.  description (char[]) 
  6671.            Description of the backup method. 
  6672.  
  6673.  allFiles (BOOL) 
  6674.  
  6675.            TRUE           Allow backup of any file; the drive, directory and 
  6676.                           subdirectories fields are ignored. 
  6677.            FALSE          Allow backup of files specified by the drive, 
  6678.                           directory and subdirectories fields. 
  6679.  
  6680.  drive (char) 
  6681.            Drive letter from which to back up files.  An asterisk (*) means all 
  6682.            drives. 
  6683.  
  6684.  directory (char[]) 
  6685.            Directory to from which to back up files.  This may end in a an 
  6686.            asterisk (*) to allow matching of more than one directory. 
  6687.  
  6688.  subdirectories (BOOL) 
  6689.  
  6690.            TRUE           Include subdirectories of the specified directory. 
  6691.            FALSE          Do not include subdirectories. 
  6692.  
  6693.  compression (PSNSCOMPRESSION) 
  6694.  
  6695.            PSNS_NOCOMPRESSIONDon't compress data. 
  6696.            PSNS_COMPRESSIONDo compress data. 
  6697.            PSNS_DEFAULT   Default compression. 
  6698.  
  6699.  generations (int) 
  6700.            Number of generations of backed up files to keep. 
  6701.  
  6702.  useRulebook (BOOL) 
  6703.  
  6704.            TRUE           Use the rulebook named in rulebook The compression 
  6705.                           and generations fields are ignored. 
  6706.            FALSE          Do not use a rulebook; use the settings in 
  6707.                           compression and generations  The rulebook field is 
  6708.                           ignored. 
  6709.  
  6710.  rulebook (char[]) 
  6711.            Name of the rulebook to use.  If this is a zero-length string then 
  6712.            the default rulebook is used. 
  6713.  
  6714.  useFileFilter (BOOL) 
  6715.  
  6716.            TRUE           Use the file filter named in fileFilter to decide 
  6717.                           which files to back up. 
  6718.            FALSE          Back up all files in the selected directories. 
  6719.                           fileFilter is ignored. 
  6720.  
  6721.  fileFilter (char[]) 
  6722.            Name of the file filter to use.  If this is a zero-length string 
  6723.            then the default file filter is used. 
  6724.  
  6725.  changedFilesOnly (BOOL) 
  6726.  
  6727.            TRUE           Only back up files which have changed since the last 
  6728.                           backup to this backup set. 
  6729.            FALSE          Back up all files, regardless of whether they have 
  6730.                           changed. 
  6731.  
  6732.  preview (BOOL) 
  6733.  
  6734.            TRUE           Show a preview before the backup and allow the user 
  6735.                           to select or deselect individual files. 
  6736.            FALSE          Do not show a preview. 
  6737.  
  6738.            Note:  Showing a preview is only useful if the backup method is to 
  6739.            be run from the OS/2 Warp Server Backup/Restore window; it is not 
  6740.            possible to show a preview when running a backup method using the 
  6741.            API. 
  6742.  
  6743.  backupSet (char[]) 
  6744.            Backup set into which back up data is to be put.  If this is a 
  6745.            zero-length string then the default backup set will be used. 
  6746.  
  6747.  
  6748. ΓòÉΓòÉΓòÉ 4.2. BACKUPSETINFO ΓòÉΓòÉΓòÉ
  6749.  
  6750. typedef struct {
  6751.    char name[PSNS_NAME_SIZE + 1];
  6752.    char description[PSNS_DESCRIPTION_SIZE + 1];
  6753.    char storageDevice[PSNS_DEVICE_NAME + 1];
  6754.    char incStorageDevice[PSNS_DEVICE_NAME + 1];
  6755.    BOOL transferredIn;
  6756. } BACKUPSETINFO, *PBACKUPSETINFO;
  6757.  
  6758.  name (char[]) 
  6759.            Name of the backup set. 
  6760.  
  6761.  description (char[]) 
  6762.            Description of the backup set. 
  6763.  
  6764.  storageDevice (char[]) 
  6765.            Storage device which the backup set uses.  For dual device backup 
  6766.            sets this is the base device. 
  6767.  
  6768.  incStorageDevice (char[]) 
  6769.            For single device backup sets this is an empty string.  For dual 
  6770.            device backup sets this is the device incremental backups are 
  6771.            written to.  Note that once a backup set has been created it cannot 
  6772.            be changed from a single device backup set to a dual device backup 
  6773.            set or vice-versa. 
  6774.  
  6775.  transferredIn (BOOL) 
  6776.            TRUE if the backup set is transferred in and available for use; 
  6777.            FALSE otherwise. 
  6778.  
  6779.  
  6780. ΓòÉΓòÉΓòÉ 4.3. BACKUPSETVOLUME ΓòÉΓòÉΓòÉ
  6781.  
  6782. typedef struct {
  6783.    ULONG id;
  6784.    char backupSet[PSNS_NAME_SIZE + 1];
  6785.    ULONG spaceUsed;
  6786. } BACKUPSETVOLUME, *PBACKUPSETVOLUME;
  6787.  
  6788.  id (ULONG) 
  6789.            Volume ID. 
  6790.  
  6791.  backupSet (char[]) 
  6792.            Name of the backup set. 
  6793.  
  6794.  spaceUsed (ULONG) 
  6795.            Space taken up on the volume by this backup set in units of 
  6796.            unitMultiplier. 
  6797.  
  6798.  
  6799. ΓòÉΓòÉΓòÉ 4.4. ESTIMATE ΓòÉΓòÉΓòÉ
  6800.  
  6801. typedef struct {
  6802.    PSNSFFB total;
  6803.    ULONG time;
  6804. } ESTIMATE, *PESTIMATE;
  6805.  
  6806.  total (PSNSFFB) 
  6807.            Files, folders and bytes counted. 
  6808.  
  6809.  time (ULONG) 
  6810.            Estimated time for the backup, in seconds. 
  6811.  
  6812.  
  6813. ΓòÉΓòÉΓòÉ 4.5. EVENTINFO ΓòÉΓòÉΓòÉ
  6814.  
  6815. typedef enum {
  6816.    EV_REGULAR  =1,         // Regular interval event
  6817.    EV_DAILY    =2,         // Daily event
  6818.    EV_STARTUP  =3,         // Startup event
  6819.    EV_NAMEDDAYS=4,         // Named days event
  6820.    EV_MONTHLY  =5          // Monthly event
  6821. } EVENTTYPE;
  6822.  
  6823. typedef enum {
  6824.    EVENT_NO       =-1,     // No
  6825.    EVENT_AS_METHOD=0,      // Use setting in backup method
  6826.    EVENT_YES      =+1      // Yes
  6827. } EVENTOPTION;
  6828.  
  6829. typedef struct {
  6830.    USHORT id;
  6831.    EVENTTYPE type;
  6832.    char backupMethod[PSNS_NAME_SIZE + 1];
  6833.    union {
  6834.       struct {
  6835.          int hours, minutes;
  6836.       } regular;
  6837.       struct {
  6838.          int hours, minutes;
  6839.       } daily;
  6840.       struct {
  6841.          int day, hours, minutes;
  6842.       } monthly;
  6843.       struct {
  6844.          int hours, minutes;
  6845.          char days, weeks;
  6846.       } namedDays;
  6847.       struct {
  6848.          int hours, minutes;
  6849.       } startup;
  6850.    } info;
  6851.    EVENTOPTION changedFilesOnly;
  6852.    EVENTOPTION showPreview;
  6853.    BOOL active;
  6854.    DATETIME lastRun;
  6855.    DATETIME nextRun;
  6856. } EVENTINFO, *PEVENTINFO;
  6857.  
  6858.  id (USHORT) 
  6859.            ID of the event. 
  6860.  
  6861.  type (EVENTTYPE) 
  6862.            Type of the event. 
  6863.  
  6864.  backupMethod (char[]) 
  6865.            Name of the backup method which will be run. 
  6866.  
  6867.  info.regular 
  6868.            Interval at which the regular event will occur, in hours and 
  6869.            minutes. 
  6870.  
  6871.  info.daily 
  6872.            Time of day when the daily event will occur, in hours and minutes. 
  6873.  
  6874.  info.monthly 
  6875.            Day of the month and time of day when the monthly event will occur. 
  6876.  
  6877.  info.namedDays 
  6878.  
  6879.            hours, minutes Time of day when the event will occur. 
  6880.            days           Bit-field specifying on which days the event will 
  6881.                           occur: 1 = Monday, 2 = Tuesday, 4 = Wednesday and so 
  6882.                           on. 
  6883.            weeks          Bit-field specifying in which weeks of the month the 
  6884.                           event will occur: 1 = First week, 2 = second, 4 = 
  6885.                           third, 8 = fourth, 16 = last. 
  6886.  
  6887.  info.startup 
  6888.            Hours and minutes after startup when the event will occur. 
  6889.  
  6890.  changedFilesOnly (EVENTOPTION) 
  6891.  
  6892.            EVENT_YES      Only back up files which have changed since the last 
  6893.                           backup. 
  6894.            EVENT_NO       Back up all files, whether or not they have changed. 
  6895.            EVENT_AS_METHODUse the backup method to decide whether to back up 
  6896.                           changed files. 
  6897.  
  6898.  showPreview (EVENTOPTION) 
  6899.  
  6900.            EVENT_YES      Show a preview before performing the backup. 
  6901.            EVENT_NO       Do not show a preview. 
  6902.            EVENT_AS_METHODUse the backup method to decide whether to show a 
  6903.                           preview. 
  6904.  
  6905.  active (BOOL) 
  6906.  
  6907.            TRUE           The event is active. 
  6908.            FALSE          The event is inactive and will not occur. 
  6909.  
  6910.  lastRun (DATETIME) 
  6911.            Date and time when the event was last run. 
  6912.  
  6913.  nextRun (DATETIME) 
  6914.            Date and time when the event is next due to be run. 
  6915.  
  6916.  
  6917. ΓòÉΓòÉΓòÉ 4.6. FILEFILTERINFO ΓòÉΓòÉΓòÉ
  6918.  
  6919. typedef enum {
  6920.    FILTER_TREE=1,
  6921.    FILTER_LIST=2
  6922. } FILEFILTERTYPE;
  6923.  
  6924. typedef struct {
  6925.    FILEFILTERTYPE type;
  6926.    char name[PSNS_NAME_SIZE + 1];
  6927.    char description[PSNS_DESCRIPTION_SIZE + 1];
  6928.    int numRules;
  6929.    char searchFile[CCHMAXPATH];
  6930. } FILEFILTERINFO, *PFILEFILTERINFO;
  6931.  
  6932.  type (FILEFILTERTYPE) 
  6933.            Type of the file filter. 
  6934.  
  6935.            FILTER_TREE    Tree-based filter. 
  6936.            FILTER_LIST    Rule-based filter. 
  6937.  
  6938.            In fact all file filters are stored as rule-based filters; the type 
  6939.            only affects how the file filter is displayed when it is edited. 
  6940.  
  6941.  name (char[]) 
  6942.            Name of the file filter. 
  6943.  
  6944.  description (char[]) 
  6945.            Description of the file filter. 
  6946.  
  6947.  numRules (int) 
  6948.            Number of rules in the file filter. 
  6949.  
  6950.  searchFile (char[]) 
  6951.            This field is only used when listing file filters; it specifies a 
  6952.            filename to match. All file filters which select this file will be 
  6953.            listed. 
  6954.  
  6955.  
  6956. ΓòÉΓòÉΓòÉ 4.7. FILEFILTERRULE ΓòÉΓòÉΓòÉ
  6957.  
  6958. typedef struct {
  6959.    char drive;
  6960.    char directory[CCHMAXPATH];
  6961.    char pattern[CCHMAXPATH];
  6962.    BOOL subdirectories;
  6963.    BOOL include;
  6964. } FILEFILTERRULE, *PFILEFILTERRULE;
  6965.  
  6966.  drive (char) 
  6967.            Drive letter to include/exclude, or an asterisk (*) for all drives. 
  6968.  
  6969.  directory (char[]) 
  6970.            Directory to include/exclude. 
  6971.  
  6972.  pattern (char[]) 
  6973.            Wildcard specifying which files to include/exclude. 
  6974.  
  6975.  subdirectories (BOOL) 
  6976.  
  6977.            TRUE           Also include/exclude subdirectories in the specified 
  6978.                           directory. 
  6979.            FALSE          Do not include/exclude subdirectories. 
  6980.  
  6981.  include (BOOL) 
  6982.  
  6983.            TRUE           Include the specified files. 
  6984.            FALSE          Exclude the specified files. 
  6985.  
  6986.  
  6987. ΓòÉΓòÉΓòÉ 4.8. HPSNSLIST ΓòÉΓòÉΓòÉ
  6988.  
  6989. typedef int HPSNSLIST, *PHPSNSLIST;
  6990.  
  6991.  
  6992. ΓòÉΓòÉΓòÉ 4.9. PSNSCOMPRESSION ΓòÉΓòÉΓòÉ
  6993.  
  6994. typedef enum {
  6995.    PSNS_NOCOMPRESSION,
  6996.    PSNS_COMPRESSION,
  6997.    PSNS_DEFAULT
  6998. } PSNSCOMPRESSION;
  6999.  
  7000.  
  7001. ΓòÉΓòÉΓòÉ 4.10. PSNSCONNECTION ΓòÉΓòÉΓòÉ
  7002.  
  7003. typedef enum {
  7004.    PSNS_PIPE,
  7005.    PSNS_TCPIP
  7006. } PSNSCONNECTION;
  7007.  
  7008. typedef struct {
  7009.    char serverName[CCHMAXPATH];
  7010.    char pipeName[CCHMAXPATH];
  7011. } PSNSPIPEINFO, *PPSNSPIPEINFO;
  7012.  
  7013.  serverName (char[]) 
  7014.            Name of the server to connect to, or empty for a local server. 
  7015.  
  7016.  pipeName (char[]) 
  7017.            Name of the pipe to connect to on that server, or empty for the 
  7018.            default. 
  7019.  
  7020.  
  7021. ΓòÉΓòÉΓòÉ 4.11. PSNSDEFAULTS ΓòÉΓòÉΓòÉ
  7022.  
  7023. typedef struct {
  7024.    char fileFilter[PSNS_SIZE_NAME + 1];
  7025.    char rulebook[PSNS_SIZE_NAME + 1];
  7026.    char backupSet[PSNS_SIZE_NAME + 1];
  7027.    BOOL compression;
  7028.    int generations;
  7029. } PSNSDEFAULTS, *PPSNSDEFAULTS;
  7030.  
  7031.  fileFilter (char[]) 
  7032.            Name of the default file filter. 
  7033.  
  7034.  rulebook (char[]) 
  7035.            Name of the default rulebook. 
  7036.  
  7037.  backupSet (char[]) 
  7038.            Name of the default backup set. 
  7039.  
  7040.  compression (BOOL) 
  7041.  
  7042.            TRUE           Do compress data by default. 
  7043.            FALSE          Don't compress data by default. 
  7044.  
  7045.  generations (int) 
  7046.            Default number of generations to keep. 
  7047.  
  7048.  
  7049. ΓòÉΓòÉΓòÉ 4.12. PSNSFFB ΓòÉΓòÉΓòÉ
  7050.  
  7051. typedef struct {
  7052.    unsigned long files, folders;
  7053.    ULONG64 bytes;
  7054. } PSNSFFB, *PPSNSFFB;
  7055.  
  7056.  
  7057. ΓòÉΓòÉΓòÉ 4.13. PSNSFILEINFO ΓòÉΓòÉΓòÉ
  7058.  
  7059. typedef struct {
  7060.    char backupSet[PSNS_NAME_SIZE + 1];
  7061.    char filename[CCHMAXPATH];
  7062.    short generations;
  7063.    short thisGeneration;
  7064.    FDATE creationDate;
  7065.    FTIME creationTime;
  7066.    FDATE writeDate;
  7067.    FTIME writeTime;
  7068.    FDATE backupDate;
  7069.    FTIME backupTime;
  7070.    ULONG size;
  7071.    ULONG attribs;
  7072.    ULONG volumeID;
  7073. } PSNSFILEINFO, *PPSNSFILEINFO;
  7074.  
  7075.  backupSet (char[]) 
  7076.            Name of the backup set to which this file is backed up. 
  7077.  
  7078.  filename (char[]) 
  7079.            Original name and path of the file. 
  7080.  
  7081.  generations (short) 
  7082.            Number of generations of this file which are backed up to this 
  7083.            backup set. 
  7084.  
  7085.  thisGeneration (short) 
  7086.            Number of the generation to which the information in this structure 
  7087.            refers. 
  7088.  
  7089.  creationDate (FDATE) 
  7090.            Date when the backed-up file was created. 
  7091.  
  7092.  creationTime (FTIME) 
  7093.            Time when the backed-up file was created. 
  7094.  
  7095.  writeDate (FDATE) 
  7096.            Date when the backed-up file was last changed. 
  7097.  
  7098.  writeTime (FTIME) 
  7099.            Time when the backed-up file was last changed. 
  7100.  
  7101.  backupDate (FDATE) 
  7102.            Date when this generation was backed up. 
  7103.  
  7104.  backupTime (FTIME) 
  7105.            Time when this generation was backed up. 
  7106.  
  7107.  size (ULONG) 
  7108.            Size of the file. 
  7109.  
  7110.  attribs (ULONG) 
  7111.            File attributes, in the form returned by DosQueryFileInfo. 
  7112.  
  7113.  volumeID (ULONG) 
  7114.            ID of the volume on which this generation is stored. 
  7115.  
  7116.  
  7117. ΓòÉΓòÉΓòÉ 4.14. PSNSHANDLE ΓòÉΓòÉΓòÉ
  7118.  
  7119. typedef unsigned long PSNSHANDLE;
  7120.  
  7121.  
  7122. ΓòÉΓòÉΓòÉ 4.15. PSNSMESSAGEFN ΓòÉΓòÉΓòÉ
  7123.  
  7124. typedef ULONG (*PSNSMESSAGEFN)(const char *msg, ULONG style, void *privates);
  7125.  
  7126. This type defines a callback function which can be registered using 
  7127. PsnsMessageCallback and will be called every time there is a message or query 
  7128. which might be shown to the user.  There are three arguments: 
  7129.  
  7130.  msg (const char *) 
  7131.            Message text 
  7132.  
  7133.  style (ULONG) 
  7134.            Flags describing which options are available to the user. 
  7135.  
  7136.            PSNSM_OK       OK 
  7137.            PSNSM_RETRY    Retry 
  7138.            PSNSM_IGNORE   Ignore 
  7139.            PSNSM_CANCEL   Cancel 
  7140.            PSNSM_YES      Yes 
  7141.            PSNSM_NO       No 
  7142.            PSNSM_ABORT    Abort 
  7143.  
  7144.  privates (void *) 
  7145.            The pointer which was passed to PsnsMessageCallback. 
  7146.  
  7147.  The function should return one of these constants to indicate which choice the 
  7148.  user made.  A return value of PSNSM_DEFAULT is also allowed, which causes some 
  7149.  default action to be taken; this would for example be used when user 
  7150.  interaction is not possible. 
  7151.  
  7152.  Example 
  7153.  
  7154.  
  7155. ΓòÉΓòÉΓòÉ 4.16. PSNSSETTINGS ΓòÉΓòÉΓòÉ
  7156.  
  7157. typedef enum {
  7158.    NORMAL=1,
  7159.    HIGH  =2
  7160. } PSNSPRIORITY;
  7161.  
  7162. typedef struct {
  7163.    PSNSPRIORITY manualPriority;
  7164.    PSNSPRIORITY autoPriority;
  7165.    char tempPath[CCHMAXPATH];
  7166.    long flags;
  7167.    ULONG logFileLimit;
  7168.    char backupExit[CCHMAXPATH];
  7169.    char restoreExit[CCHMAXPATH];
  7170.    BOOL enableACLBackup;
  7171.    char uadFilename[CCHMAXPATH];
  7172. } PSNSSETTINGS, *PPSNSSETTINGS;
  7173.  
  7174.  manualPriority (PSNSPRIORITY) 
  7175.            Priority for manual backups. 
  7176.  
  7177.  autoPriority (PSNSPRIORITY) 
  7178.            Priority for automatic backups. 
  7179.  
  7180.  tempPath (char[]) 
  7181.            Path for temporary files. 
  7182.  
  7183.  flags (long) 
  7184.            Various on/off flags: 
  7185.  
  7186.            SET_LOG        Enable logging for backup, restore and drop 
  7187.                           activities. 
  7188.            SET_LOG_SUCCESSESLog individual files which are successful. 
  7189.            SET_LOG_FAILURESLog individual files which fail. 
  7190.            SET_BACKUP_EXITEnable the user exit on backup. 
  7191.            SET_RESTORE_EXITEnable the user exit on restore. 
  7192.  
  7193.  logFileLimit (ULONG) 
  7194.            Maximum number of lines in a log file.  If this is 0 then there is 
  7195.            no limit to the size of a log file. 
  7196.  
  7197.  backupExit (char[]) 
  7198.            Name of a Rexx command file to run on backup. 
  7199.  
  7200.  restoreExit (char []) 
  7201.            Name of a Rexx command file to run on restore. 
  7202.  
  7203.  enableACLBackup (BOOL) 
  7204.  
  7205.            TRUE           Back up and restore Access Control Lists using 
  7206.                           BACKACC and RESTACC. 
  7207.            FALSE          Do not back up and restore Access Control Lists. 
  7208.  
  7209.  uadFilename (char[]) 
  7210.            Name of the file which contains the User Accounts Database, usually 
  7211.            NET.ACC. 
  7212.  
  7213.  For more information on Rexx user exits and on backing up Access Control 
  7214.  Lists, see the OS/2 Warp Server Backup/Restore online help. 
  7215.  
  7216.  
  7217. ΓòÉΓòÉΓòÉ 4.17. PSNSSTATSFN ΓòÉΓòÉΓòÉ
  7218.  
  7219. typedef struct {
  7220.    PSNSFFB total, processed, failed;
  7221.    unsigned long timeElapsed, timeEstimate;    // in seconds
  7222.    unsigned long dataRate;                     // bytes per second
  7223.    ULONG64 spaceLeft;
  7224. } PSNSSTATS, *PPSNSSTATS;
  7225.  
  7226. typedef void (*PSNSSTATSFN)(PPSNSSTATS pPsnsStats, char *message);
  7227.  
  7228. This type defines a callback function which is called during 
  7229. PsnsRunBackupMethod and PsnsRunRestoreMethod. The function is called whenever 
  7230. there are statistics or messages which might interest the user.  If the 
  7231. pPsnsStats parameter is non-NULL, it points to a PSNSSTATS structure which 
  7232. contains statistics about the backup or restore operation.  If the message 
  7233. parameter is non-NULL, it contains a filename or a message. 
  7234.  
  7235.  
  7236. ΓòÉΓòÉΓòÉ 4.18. RESTOREMETHODINFO ΓòÉΓòÉΓòÉ
  7237.  
  7238. typedef struct {
  7239.    char name[PSNS_SIZE_NAME + 1];
  7240.    char description[PSNS_SIZE_DESCRIPTION + 1];
  7241.    char backupSet[PSNS_SIZE_NAME + 1];
  7242.    BOOL allFiles;
  7243.    char drive;
  7244.    char directory[CCHMAXPATH];
  7245.    char pattern[CCHMAXPATH];
  7246.    BOOL subdirectories;
  7247.    BOOL byDate;
  7248.    FDATE date;
  7249.    FTIME time;
  7250.    BOOL preview;
  7251.    BOOL prompt;
  7252.    BOOL originalLocation;
  7253.    char destinationDrive;
  7254.    char destinationPath[CCHMAXPATH];
  7255. } RESTOREMETHODINFO, *PRESTOREMETHODINFO;
  7256.  
  7257.  name (char[]) 
  7258.            Name of the restore method. 
  7259.  
  7260.  description (char[]) 
  7261.            Description of the restore method. 
  7262.  
  7263.  backupSet (char[]) 
  7264.            Backup set from which to restore.  This can be an asterisk (*) to 
  7265.            restore from all backup sets, or an empty string to restore from the 
  7266.            default backup set. 
  7267.  
  7268.  allFiles (BOOL) 
  7269.  
  7270.            TRUE           Restore all files in the backup set; the drive, 
  7271.                           directory, pattern and subdirectories fields are 
  7272.                           ignored. 
  7273.            FALSE          Restore only the files specified in the drive, 
  7274.                           directory, pattern and subdirectories fields. 
  7275.  
  7276.  drive (char) 
  7277.            Original drive of the files to be restored. 
  7278.  
  7279.  directory (char[]) 
  7280.            Original directory of the files to be restored. 
  7281.  
  7282.  pattern (char[]) 
  7283.            Wildcard selecting which files are to be restored. 
  7284.  
  7285.  subdirectories (BOOL) 
  7286.  
  7287.            TRUE           Restore files in subdirectories of the selected 
  7288.                           directories. 
  7289.            FALSE          Do not restore files in subdirectories. 
  7290.  
  7291.  byDate (BOOL) 
  7292.  
  7293.            TRUE           Restore files as they were on the date and time 
  7294.                           specified in date and time. 
  7295.            FALSE          Restore the most recent generation of each file. 
  7296.  
  7297.  date (FDATE) 
  7298.            Files will be restored to the state they were in on this date if 
  7299.            byDate is set to TRUE. 
  7300.  
  7301.  time (FTIME) 
  7302.            Files will be restored to the state they were in at this time if 
  7303.            byDate is set to TRUE. 
  7304.  
  7305.  preview (BOOL) 
  7306.  
  7307.            TRUE           Show a preview and allow the user to select or 
  7308.                           deselect individual files before performing the 
  7309.                           restore. 
  7310.            FALSE          Do not show a preview. 
  7311.  
  7312.            Note:  Showing a preview is only useful if the restore method is to 
  7313.            be run from the OS/2 Warp Server Backup/Restore window; it is not 
  7314.            possible to show a preview when running a restore method using the 
  7315.            API. 
  7316.  
  7317.  prompt 
  7318.  
  7319.            TRUE           Prompt the user to select a generation of each file 
  7320.                           to be restored. 
  7321.            FALSE          Do not prompt the user; restore the most recent 
  7322.                           generation of each file. 
  7323.  
  7324.            Note:  This is only useful if the restore method is to be run from 
  7325.            the OS/2 Warp Server Backup/Restore window; it is not possible to 
  7326.            pick generations when running a restore method using the API. 
  7327.  
  7328.  originalLocation (BOOL) 
  7329.  
  7330.            TRUE           Restore files to their original locations; 
  7331.                           destinationDrive and destinationPath are ignored. 
  7332.            FALSE          Restore files to the drive and path specified in 
  7333.                           destinationDrive and destinationPath. 
  7334.  
  7335.  destinationDrive (char) 
  7336.            Drive to which to restore files if originalLocation is set to FALSE 
  7337.  
  7338.  destinationPath (char[]) 
  7339.            Path to which to restore files if originalLocation is set to FALSE 
  7340.  
  7341.  
  7342. ΓòÉΓòÉΓòÉ 4.19. RULEBOOKINFO ΓòÉΓòÉΓòÉ
  7343.  
  7344. typedef struct {
  7345.    char name[PSNS_NAME_SIZE + 1];
  7346.    char description[PSNS_DESCRIPTION_SIZE + 1];
  7347.    int numRules;
  7348. } RULEBOOKINFO, *PRULEBOOKINFO;
  7349.  
  7350.  name (char[]) 
  7351.            Name of the rulebook. 
  7352.  
  7353.  description (char[]) 
  7354.            Description of the rulebook. 
  7355.  
  7356.  numRules (int) 
  7357.            Number of rules in the rulebook. 
  7358.  
  7359.  
  7360. ΓòÉΓòÉΓòÉ 4.20. RULEBOOKRULE ΓòÉΓòÉΓòÉ
  7361.  
  7362. typedef struct {
  7363.    char drive;
  7364.    char directory[CCHMAXPATH];
  7365.    char pattern[CCHMAXPATH];
  7366.    BOOL subdirectories;
  7367.    int generations;
  7368.    PSNSCOMPRESSION compression;
  7369. } RULEBOOKRULE, *PRULEBOOKRULE;
  7370.  
  7371.  drive (char) 
  7372.            Drive letter to include/exclude, or anasterisk (*) for all drives. 
  7373.  
  7374.  directory (char[]) 
  7375.            Directory to include/exclude. 
  7376.  
  7377.  pattern (char[]) 
  7378.            Wildcard specifying which files to include/exclude. 
  7379.  
  7380.  subdirectories (BOOL) 
  7381.  
  7382.            TRUE           Also select subdirectories in the specified 
  7383.                           directory. 
  7384.            FALSE          Do not select subdirectories. 
  7385.  
  7386.  generations (int) 
  7387.            Number of generations of the specified files to keep. 
  7388.  
  7389.  compression (PSNSCOMPRESSION) 
  7390.  
  7391.            PSNS_COMPRESSIONCompress the specified files. 
  7392.            PSNS_NOCOMPRESSIONDo not compress the specified files. 
  7393.            PSNS_DEFAULT   Use the default compression for the specified files. 
  7394.  
  7395.  
  7396. ΓòÉΓòÉΓòÉ 4.21. SOURCEDRIVEINFO ΓòÉΓòÉΓòÉ
  7397.  
  7398. typedef enum {
  7399.    DRI_HARDDISK =1,
  7400.    DRI_DISKETTE =2,
  7401.    DRI_LANDRIVE =3,
  7402.    DRI_RWOPTICAL=4,
  7403.    DRI_CDROM    =5,
  7404.    DRI_PRM      =6
  7405.    DRI_OTHER    =7
  7406. } DRIVETYPE;
  7407.  
  7408. typedef struct {
  7409.    char letter;
  7410.    DRIVETYPE type;
  7411.    BOOL selected;
  7412. } SOURCEDRIVEINFO, *PSOURCEDRIVEINFO;
  7413.  
  7414.  letter (char) 
  7415.            Drive letter of the source drive. 
  7416.  
  7417.  type (DRIVETYPE) 
  7418.            Type of the source drive. 
  7419.  
  7420.  selected (BOOL) 
  7421.  
  7422.            TRUE           This drive will be checked for files to back up. 
  7423.            FALSE          This drive will not be checked for files to back up. 
  7424.  
  7425.  
  7426. ΓòÉΓòÉΓòÉ 4.22. STORAGEDEVICEINFO ΓòÉΓòÉΓòÉ
  7427.  
  7428. typedef struct {
  7429.    char name[PSNS_DEVICE_NAME + 1];
  7430.    char dllName[CCHMAXPATH];
  7431. } STORAGEDEVICEINFO, *PSTORAGEDEVICEINFO;
  7432.  
  7433.  name (char[]) 
  7434.            Name of the storage device. 
  7435.  
  7436.  dllName (char[]) 
  7437.            Name of the Dynamic Link Library (DLL) which implements the storage 
  7438.            device. 
  7439.  
  7440.  
  7441. ΓòÉΓòÉΓòÉ 4.23. ULONG64 ΓòÉΓòÉΓòÉ
  7442.  
  7443. typedef struct {
  7444.    unsigned long high, low;
  7445. } ULONG64, *PULONG64;
  7446.  
  7447. This structure is used for storing quantities which do not fit into a 32-bit 
  7448. integer. 
  7449.  
  7450.  high (unsigned long) 
  7451.            High 32 bits. 
  7452.  
  7453.  low (unsigned long) 
  7454.            Low 32 bits. 
  7455.  
  7456.  
  7457. ΓòÉΓòÉΓòÉ 4.24. VOLUMEINFO ΓòÉΓòÉΓòÉ
  7458.  
  7459. typedef struct {
  7460.    ULONG id;
  7461.    char name[PSNS_VOLUME_NAME_SIZE + 1];
  7462.    char storageDevice[PSNS_DEVICE_NAME + 1];
  7463.    BOOL transferredOut;
  7464.    BOOL available;
  7465.    char backupSets;
  7466.    ULONG unitMultiplier;
  7467.    ULONG totalCapacity;
  7468.    ULONG psnsCapacity;
  7469.    ULONG psnsUsed;
  7470.    ULONG psnsFree;
  7471.    ULONG otherFree;
  7472.    ULONG otherUsed;
  7473.    ULONG totalBad;
  7474.    char backupSet[PSNS_NAME_SIZE+1];
  7475.    LONG indexNo;
  7476. } VOLUMEINFO, *PVOLUMEINFO;
  7477.  
  7478.  id (ULONG) 
  7479.            Volume ID of the volume. 
  7480.  
  7481.  name (char[]) 
  7482.            Name of the volume. 
  7483.  
  7484.  storageDevice (char[]) 
  7485.            Name of the storage device which the volume uses. Index diskettes 
  7486.            have an empty string here. 
  7487.  
  7488.  transferredOut (BOOL) 
  7489.  
  7490.            TRUE           The volume belongs to a backup set which has been 
  7491.                           transferred out. 
  7492.            FALSE          The volume does not belong to a backup set which has 
  7493.                           been transferred out. 
  7494.  
  7495.  available (BOOL) 
  7496.  
  7497.            TRUE           The volume is available for use. 
  7498.            FALSE          The user has made the volume unavailable and it will 
  7499.                           not be used for backing up or restoring data. 
  7500.  
  7501.  backupSets (char) 
  7502.            Number of backup sets which use this volume. 
  7503.  
  7504.  unitMultiplier (ULONG) 
  7505.            This specifies the units in which the volume usage information is 
  7506.            specified.  It is a number in bytes, for example 1024 for kilobytes. 
  7507.  
  7508.  totalCapacity (ULONG) 
  7509.            Total size of the volume in units of unitMultiplier. 
  7510.  
  7511.  psnsCapacity (ULONG) 
  7512.            Amount of space on the volume, in units of unitMultiplier, which is 
  7513.            available for OS/2 Warp Server Backup/Restore to use. 
  7514.  
  7515.  psnsUsed (ULONG) 
  7516.            Amount of space, in units of unitMultiplier, currently used on the 
  7517.            volume by OS/2 Warp Server Backup/Restore. 
  7518.  
  7519.  psnsFree (ULONG) 
  7520.            Amount of free space on the volume, in units of unitMultiplier, 
  7521.            which OS/2 Warp Server Backup/Restore may use. 
  7522.  
  7523.  otherFree (ULONG) 
  7524.            Amount of free space on the volume, in units of unitMultiplier, 
  7525.            which OS/2 Warp Server Backup/Restore may not use. 
  7526.  
  7527.  otherUsed (ULONG) 
  7528.            Amount of space on the volume, in units of unitMultiplier, used by 
  7529.            programs other than OS/2 Warp Server Backup/Restore. 
  7530.  
  7531.  totalBad (ULONG) 
  7532.            Total amount of unusable space on the volume, in units of 
  7533.            unitMultiplier. 
  7534.  
  7535.  char backupSet (char[]) 
  7536.            If the volume is used for only one backup set, this contains the 
  7537.            name of that backup set. 
  7538.  
  7539.  indexNo (LONG) 
  7540.            If the volume is used for only one backup set, this contains the 
  7541.            index of the volume within the backup set. A negative value 
  7542.            signifies that the volume is an index diskette. A value of zero 
  7543.            means that the volume is unassociated or fixed. 
  7544.  
  7545.  
  7546. ΓòÉΓòÉΓòÉ 5. Errors ΓòÉΓòÉΓòÉ
  7547.  
  7548.  0  PSNS_OK 
  7549.            No errors occurred. 
  7550.  
  7551.  1  PSNS_NO_MORE_HANDLES 
  7552.            Too many list handles are in use and a new one cannot be allocated. 
  7553.  
  7554.  3  PSNS_UNKNOWN_ERROR 
  7555.            An unknown internal error occurred. 
  7556.  
  7557.  4  PSNS_HANDLE_IN_USE 
  7558.            An API call is already in progress using this handle.  You may not 
  7559.            call more than one API function at the same time with the same 
  7560.            handle. If another thread needs to call API functions, it should 
  7561.            obtain a new handle using PsnsInit. 
  7562.  
  7563.  5  PSNS_ALREADY_EXISTS 
  7564.            You are trying to create, copy or rename an object, but the name you 
  7565.            have specified already exists. 
  7566.  
  7567.  6  PSNS_ARCHIVE_ERROR 
  7568.            An internal error was encountered when processing index files. 
  7569.  
  7570.  7  PSNS_INVALID_HANDLE 
  7571.            The handle you have passed is not one which was returned by 
  7572.            PsnsInit. 
  7573.  
  7574.  8  PSNS_INVALID_LIST_HANDLE 
  7575.            The list handle you have passed to a listing function is not known. 
  7576.  
  7577.  9  PSNS_INVALID_PARAMETER 
  7578.            A parameter passed to an API function is invalid, for example, a 
  7579.            pointer is NULL when it shouldn't be. 
  7580.  
  7581.  10  PSNS_INVALID_BACKUP_METHOD 
  7582.            The named backup method does not exist. 
  7583.  
  7584.  11  PSNS_INVALID_VOLUME 
  7585.            The given volume ID does not exist. 
  7586.  
  7587.  12  PSNS_INVALID_EVENT_TYPE 
  7588.            The given event type is not one defined in EVENTTYPE. 
  7589.  
  7590.  13  PSNS_INVALID_EVENT_OPTION 
  7591.            The given event option is not one defined in EVENTOPTION. 
  7592.  
  7593.  14  PSNS_INVALID_MASK 
  7594.            The mask you have supplied does not make sense, for example, 
  7595.            searching for files which are both larger and smaller than 10kB. 
  7596.  
  7597.  15  PSNS_INVALID_DRIVE_TYPE 
  7598.            The given drive type is not one defined in DRIVETYPE. 
  7599.  
  7600.  16  PSNS_INVALID_GENERATIONS 
  7601.            The number of generations you have specified is not allowed; the 
  7602.            number of generations must be between 1 and 250. 
  7603.  
  7604.  17  PSNS_INVALID_RULEBOOK 
  7605.            The named rulebook does not exist. 
  7606.  
  7607.  18  PSNS_INVALID_FILE_FILTER 
  7608.            The named file filter does not exist. 
  7609.  
  7610.  19  PSNS_INVALID_BACKUP_SET 
  7611.            The named backup set does not exist. 
  7612.  
  7613.  20  PSNS_INVALID_RESTORE_METHOD 
  7614.            The named restore method does not exist. 
  7615.  
  7616.  21  PSNS_INVALID_SOURCE_DRIVE 
  7617.            You gave an invalid character for a source drive letter. 
  7618.  
  7619.  22  PSNS_INVALID_POSITION 
  7620.            The position you referred to in a rule or file filter is out of 
  7621.            range. 
  7622.  
  7623.  23  PSNS_INVALID_EVENT 
  7624.            The given event ID does not exist. 
  7625.  
  7626.  24  PSNS_INVALID_DRIVE 
  7627.            The specified drive is not a valid drive letter. 
  7628.  
  7629.  25  PSNS_INVALID_PATH 
  7630.            The specified path is not valid. 
  7631.  
  7632.  26  PSNS_INVALID_FILENAME 
  7633.            The specified filename is not valid. 
  7634.  
  7635.  27  PSNS_ALREADY_ASSOCIATED 
  7636.            The volume is already associated with a backup set. 
  7637.  
  7638.  28  PSNS_INVALID_NAME 
  7639.            The name you gave when creating, copying or renaming an object is 
  7640.            not valid. See object names for a description of what constitutes a 
  7641.            valid object name. 
  7642.  
  7643.  29  PSNS_INVALID_FILE_FILTER_TYPE 
  7644.            The given file filter type is not one defined in FILEFILTERTYPE. 
  7645.  
  7646.  30  PSNS_INVALID_STORAGE_DEVICE_TYPE 
  7647.            The given storage device type does not exist as a creatable storage 
  7648.            device type. 
  7649.  
  7650.  31  PSNS_INVALID_STORAGE_DEVICE 
  7651.            The named storage device does not exist. 
  7652.  
  7653.  32  PSNS_IN_USE 
  7654.            You tried to delete or change an object which is currently in use 
  7655.            and therefore cannot be deleted or changed. 
  7656.  
  7657.  33  PSNS_CANNOT_DELETE 
  7658.            You tried to delete a storage device or volume which may not be 
  7659.            deleted. 
  7660.  
  7661.  34  PSNS_FILE_NOT_FOUND 
  7662.            The named file was not found in the backup set. 
  7663.  
  7664.  35  PSNS_INVALID_TIME 
  7665.            The time you specified for an event is not valid. 
  7666.  
  7667.  36  PSNS_NO_EVENTS 
  7668.            There are no events currently scheduled. 
  7669.  
  7670.  37  PSNS_TOO_MUCH_DATA 
  7671.            The buffer you supplied is not large enough to receive all the data 
  7672.            which would be returned; the data has been truncated to fit in the 
  7673.            buffer. 
  7674.  
  7675.  38  PSNS_CANT_CONNECT 
  7676.            An error occurred when trying to connect to the API server. 
  7677.  
  7678.  39  PSNS_INVALID_CONFIGURATION 
  7679.            The configuration string you gave for a storage device or backup 
  7680.            method is not valid. 
  7681.  
  7682.  40  PSNS_INVALID_PRIORITY 
  7683.            The given priority is not one defined in PSNSPRIORITY. 
  7684.  
  7685.  41  PSNS_INVALID_GENERATION 
  7686.            The generation you specified does not exist. 
  7687.  
  7688.  42  PSNS_TRANSFERRED_IN 
  7689.            The backup set was already transferred in. 
  7690.  
  7691.  43  PSNS_TRANSFERRED_OUT 
  7692.            The backup set was already transferred out, or you tried to perform 
  7693.            an operation using a backup set which is transferred out. 
  7694.  
  7695.  44  PSNS_INVALID_COMPRESSION 
  7696.            The specified compression option is not valid. 
  7697.  
  7698.  45  PSNS_MALFORMED_METHOD 
  7699.            Some options in the backup or restore method are not compatible with 
  7700.            each other. 
  7701.  
  7702.  46  PSNS_INVALID_DATE 
  7703.            The given date is not valid. 
  7704.  
  7705.  47  PSNS_READONLY 
  7706.            You tried to change a rule which cannot be changed. 
  7707.  
  7708.  48  PSNS_NOT_CONFIGURABLE 
  7709.            The backup set or storage device configuration cannot be changed 
  7710.            now. 
  7711.  
  7712.  49  PSNS_INVALID_FLAGS 
  7713.            The flags you specified in PsnsSettings are not valid. 
  7714.  
  7715.  50  PSNS_COMMUNICATIONS_ERROR 
  7716.            Contact with the API server has been lost; all handles to that 
  7717.            server have been closed. 
  7718.  
  7719.  51  PSNS_INVALID_RC 
  7720.            The return code passed to PsnsGetMessageText is not valid. 
  7721.  
  7722.  52  PSNS_INDEX_DISKETTE 
  7723.            The volume ID passed to PsnsActivateVolume is that of an index 
  7724.            diskette. The active state of index diskettes cannot be altered in 
  7725.            this way. 
  7726.  
  7727.  53  PSNS_FIXED_VOLUME 
  7728.            An API function for working with removable volumes has been passed 
  7729.            the ID of a fixed volume. 
  7730.  
  7731.  54  PSNS_INAPPROPRIATE_BACKUP_SET 
  7732.            The backup set passed to PsnsAssociateVolume is not appropriate for 
  7733.            association with the volume. 
  7734.  
  7735.  55  PSNS_INVALID_KEYWORD 
  7736.            A keyword in a configuration string is incorrect, for example, using 
  7737.            the BEEP keyword with an ADSM storage device. 
  7738.  
  7739.  56  PSNS_INVALID_VALUE 
  7740.            A value in a configuration string is incorrect, for example, a 
  7741.            non-numeric was found where a numeric value was expected. 
  7742.  
  7743.  57  PSNS_SYNTAX_ERROR 
  7744.            A configuration string did not conform to the format described in 
  7745.            Storage Device & Backup Set Configuration. 
  7746.  
  7747.  58  PSNS_INCOMPLETE_STRING 
  7748.            A required parameter was missing from the configuration string. 
  7749.  
  7750.  59  PSNS_SEMANTIC_ERROR 
  7751.            An error occurred whilst processing a configuration string, for 
  7752.            example, a path name is invalid. 
  7753.  
  7754.  60  PSNS_ERROR_DURING_BACKUP 
  7755.            There were errors during the backup. If the logging of failures is 
  7756.            enabled, the backup set log contains details of the errors. 
  7757.  
  7758.  61  PSNS_ERROR_DURING_RESTORE 
  7759.            There were errors during the restore. If the logging of failures is 
  7760.            enabled, the backup set log contains details of the errors. 
  7761.  
  7762.  62  PSNS_UNHANDLED_EXCEPTION 
  7763.            An OS/2 Warp Server Backup/Restore internal error occurred; there 
  7764.            was an unhandled exception. 
  7765.  
  7766.  
  7767. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  7768.  
  7769. /****************************************************/
  7770. /* Functions used:                                  */
  7771. /*    PsnsListBackupMethods                         */
  7772. /*    PsnsDeleteBackupMethod                        */
  7773. /*                                                  */
  7774. /* Find all backup methods which use backup set     */
  7775. /* 'Llama', and delete them.                        */
  7776. /****************************************************/
  7777.  
  7778. HPSNSLIST hlist = 0;
  7779. BACKUPMETHODINFO info;
  7780. int rc;
  7781.  
  7782. /* Set up the search criteria with the backup set   */
  7783. /* we want to search on.                            */
  7784. strcpy(info.backupSet, "Llama");
  7785.  
  7786. /* Now list all the backup methods which use this   */
  7787. /* backup set.                                      */
  7788. do {
  7789.    rc = PsnsListBackupMethods(handle, &hlist, &info, BM_BACKUPSET);
  7790.    if(!rc && hlist) {
  7791.       /* For every backup method returned, print its name */
  7792.       /* and delete it.                                   */
  7793.       printf("Found backup method '%s'\n", info.name);
  7794.       rc = PsnsDeleteBackupMethod(handle, info.name);
  7795.    }
  7796. } while(!rc && hlist);
  7797.  
  7798. /* If we didn't get to the end of the list, close it */
  7799. if(hlist) PsnsCloseList(handle, &hlist);
  7800.  
  7801. if(rc) printf("Error encountered, rc = %d\n", rc);
  7802.  
  7803.  
  7804. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  7805.  
  7806.  
  7807. /****************************************************/
  7808. /* Functions used:                                  */
  7809. /*    PsnsCreateBackupMethod                        */
  7810. /*    PsnsBackupMethodInfo                          */
  7811. /*    PsnsEstimateBackupMethod                      */
  7812. /*                                                  */
  7813. /* Create a backup method to back up all changed    */
  7814. /* files on drive E, and find out how many files    */
  7815. /* would be backed up.                              */
  7816. /****************************************************/
  7817.  
  7818. BACKUPMETHODINFO info = { 0 };
  7819. ESTIMATE estimate;
  7820. int rc;
  7821.  
  7822. /* First create a new backup method. */
  7823. rc = PsnsCreateBackupMethod(handle, "Drive E to Llama");
  7824. if(rc) { printf("PsnsCreateBackupMethod returned %d\n", rc); return 1; }
  7825.  
  7826. /* Now set up the backup method to do what we want. */
  7827. strcpy(info.description, "Backs up drive E to backup set Llama");
  7828. info.allFiles = FALSE;
  7829. info.drive = 'E';
  7830. strcpy(info.directory, "*");
  7831. info.subdirectories = TRUE;
  7832. info.compression = TRUE;
  7833. info.generations = 2;
  7834. info.useRulebook = FALSE;
  7835. info.useFileFilter = FALSE;
  7836. info.changedFilesOnly = TRUE;
  7837. info.preview = FALSE;
  7838. strcpy(info.backupSet, "Llama");
  7839. rc = PsnsBackupMethodInfo(handle, "Drive E to Llama", &info, BM_ALL);
  7840. if(rc) { printf("PsnsBackupMethodInfo returned %d\n", rc); return 1; }
  7841.  
  7842. /* Estimate the backup method. */
  7843. rc = PsnsEstimateBackupMethod(handle, "Drive E to Llama", &estimate);
  7844. if(rc) {
  7845.    printf("PsnsEstimateBackupMethod returned %d\n", rc);
  7846.    return 1;
  7847. } else {
  7848.    printf("Files     Folders\n");
  7849.    printf("%8d  %8d\n",
  7850.       estimate.total.files, estimate.total.folders);
  7851.    printf("Estimated time: %d seconds\n", estimate.time);
  7852. }
  7853.  
  7854.  
  7855. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  7856.  
  7857.  
  7858. /****************************************************/
  7859. /* Functions used:                                  */
  7860. /*    PsnsRenameBackupMethod                        */
  7861. /*                                                  */
  7862. /* Rename backup method 'Orange' to 'Apple'.        */
  7863. /****************************************************/
  7864.  
  7865. int rc;
  7866. rc = PsnsRenameBackupMethod(handle, "Orange", "Apple");
  7867. if(rc) { printf("PsnsRenameBackupMethod returned %d\n", rc); return 1; }
  7868.  
  7869.  
  7870. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  7871.  
  7872.  
  7873. /****************************************************/
  7874. /* Functions used:                                  */
  7875. /*    PsnsCopyBackupMethod                          */
  7876. /*                                                  */
  7877. /* Copy backup method 'Orange' to 'Orange Mk II'.   */
  7878. /****************************************************/
  7879.  
  7880. int rc;
  7881. rc = PsnsCopyBackupMethod(handle, "Orange", "Orange Mk II");
  7882. if(rc) { printf("PsnsCopyBackupMethod returned %d\n", rc); return 1; }
  7883.  
  7884.  
  7885. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  7886.  
  7887.  
  7888. /****************************************************/
  7889. /* Functions used:                                  */
  7890. /*    PsnsRunBackupMethod                           */
  7891. /*                                                  */
  7892. /* Run backup method 'Orange' and display progress  */
  7893. /* information.                                     */
  7894. /****************************************************/
  7895.  
  7896. /* First define the statistics callback function.   */
  7897. void show_stats(PPSNSSTATS stats, char *message)
  7898. {
  7899.    if(message) printf("** %s\n", message);
  7900.    if(stats) printf("%8d  %8d\n",
  7901.       stats->processed.files, stats->processed.folders);
  7902. }
  7903.  
  7904.   .
  7905.   .
  7906.   .
  7907.  
  7908. int rc;
  7909.  
  7910. /* Run the backup method */
  7911. printf("Files     Folders\n--------  --------\n");
  7912. rc = PsnsRunBackupMethod(handle, "Orange", show_stats);
  7913. if(rc) { printf("PsnsRunBackupMethod returned %d\n", rc); return 1; }
  7914.  
  7915.  
  7916. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  7917.  
  7918.  
  7919. /****************************************************/
  7920. /* Functions used:                                  */
  7921. /*    PsnsInit                                      */
  7922. /*    PsnsTerm                                      */
  7923. /*                                                  */
  7924. /* Establish a connection to PSnS and then close it */
  7925. /* again.                                           */
  7926. /****************************************************/
  7927.  
  7928. int rc;
  7929. PSNSPIPEINFO pipeinfo;
  7930. PSNSHANDLE handle;
  7931.  
  7932. /* Set up the structure saying where we want to     */
  7933. /* connect to.                                      */
  7934. strcpy(pipeinfo.serverName, "WDGSRV");
  7935. pipeinfo.pipeName[0] = '\0';
  7936.  
  7937. /* Connect to PSnS */
  7938. rc = PsnsInit(&handle, PSNS_PIPE, &pipeinfo);
  7939. if(rc) { printf("PsnsInit returned %d\n", rc); return 1; }
  7940. printf("Connection established\n");
  7941.  
  7942. /* Disconnect */
  7943. PsnsTerm(handle);
  7944. printf("Connection terminated\n");
  7945.  
  7946.  
  7947. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  7948.  
  7949. /****************************************************/
  7950. /* Functions used:                                  */
  7951. /*    PsnsListRestoreMethods                        */
  7952. /*    PsnsDeleteRestoreMethod                       */
  7953. /*                                                  */
  7954. /* Find all restore methods which use backup set    */
  7955. /* 'Llama', and delete them.                        */
  7956. /****************************************************/
  7957.  
  7958. HPSNSLIST hlist = 0;
  7959. RESTOREMETHODINFO info;
  7960. int rc;
  7961.  
  7962. /* Set up the search criteria with the backup set   */
  7963. /* we want to search on.                            */
  7964. strcpy(info.backupSet, "Llama");
  7965.  
  7966. /* Now list all the restore methods which use this  */
  7967. /* backup set.                                      */
  7968. do {
  7969.    rc = PsnsListRestoreMethods(handle, &hlist, &info, RM_BACKUPSET);
  7970.    if(!rc && hlist) {
  7971.       /* For every restore method returned, print its name */
  7972.       /* and delete it.                                   */
  7973.       printf("Found restore method '%s'\n", info.name);
  7974.       rc = PsnsDeleteRestoreMethod(handle, info.name);
  7975.    }
  7976. } while(!rc && hlist);
  7977.  
  7978. /* If we didn't get to the end of the list, close it */
  7979. if(hlist) PsnsCloseList(handle, &hlist);
  7980.  
  7981. if(rc) printf("Error encountered, rc = %d\n", rc);
  7982.  
  7983.  
  7984. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  7985.  
  7986.  
  7987. /****************************************************/
  7988. /* Functions used:                                  */
  7989. /*    PsnsCreateRestoreMethod                       */
  7990. /*    PsnsRestoreMethodInfo                         */
  7991. /*    PsnsEstimateRestoreMethod                     */
  7992. /*                                                  */
  7993. /* Create a restore method to restore all .c files  */
  7994. /* to their original locations, and find out how    */
  7995. /* many files would be restored.                    */
  7996. /****************************************************/
  7997.  
  7998. RESTOREMETHODINFO info;
  7999. ESTIMATE estimate;
  8000. int rc;
  8001.  
  8002. /* First create a new restore method. */
  8003. rc = PsnsCreateRestoreMethod(handle, "C files");
  8004. if(rc) { printf("PsnsCreateRestoreMethod returned %d\n", rc); return 1; }
  8005.  
  8006. /* Now set up the restore method to do what we want. */
  8007. strcpy(info.description, "Restores all .c files");
  8008. strcpy(info.backupSet, "*");
  8009. info.allFiles = FALSE;
  8010. info.drive = '*';
  8011. strcpy(info.directory, "*");
  8012. strcpy(info.pattern, "*.c");
  8013. info.subdirectories = TRUE;
  8014. info.byDate = FALSE;
  8015. info.preview = FALSE;
  8016. info.prompt = FALSE;
  8017. info.originalLocation = TRUE;
  8018. rc = PsnsRestoreMethodInfo(handle, "C files", &info, RM_ALL);
  8019. if(rc) { printf("PsnsRestoreMethodInfo returned %d\n", rc); return 1; }
  8020.  
  8021. /* Estimate the restore method. */
  8022. rc = PsnsEstimateRestoreMethod(handle, "C files", &estimate);
  8023. if(rc) {
  8024.    printf("PsnsEstimateRestoreMethod returned %d\n", rc);
  8025.    return 1;
  8026. } else {
  8027.    printf("Files     Folders\n");
  8028.    printf("%8d  %8d\n",
  8029.       estimate.total.files, estimate.total.folders);
  8030.    printf("Estimated time: %d seconds\n", estimate.time);
  8031. }
  8032.  
  8033.  
  8034. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8035.  
  8036.  
  8037. /****************************************************/
  8038. /* Functions used:                                  */
  8039. /*    PsnsRenameRestoreMethod                       */
  8040. /*                                                  */
  8041. /* Rename restore method 'Gibbon' to 'All C files'. */
  8042. /****************************************************/
  8043.  
  8044. int rc;
  8045. rc = PsnsRenameRestoreMethod(handle, "Gibbon", "All C files");
  8046. if(rc) { printf("PsnsRenameRestoreMethod returned %d\n", rc); return 1; }
  8047.  
  8048.  
  8049. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8050.  
  8051.  
  8052. /****************************************************/
  8053. /* Functions used:                                  */
  8054. /*    PsnsCopyRestoreMethod                         */
  8055. /*                                                  */
  8056. /* Copy restore method 'Fish' to 'Haggis'.          */
  8057. /****************************************************/
  8058.  
  8059. int rc;
  8060. rc = PsnsCopyRestoreMethod(handle, "Fish", "Haggis");
  8061. if(rc) { printf("PsnsCopyRestoreMethod returned %d\n", rc); return 1; }
  8062.  
  8063.  
  8064. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8065.  
  8066.  
  8067. /****************************************************/
  8068. /* Functions used:                                  */
  8069. /*    PsnsRunRestoreMethod                          */
  8070. /*                                                  */
  8071. /* Run restore method 'C files' and display         */
  8072. /* progress information.                            */
  8073. /****************************************************/
  8074.  
  8075. /* First define the statistics callback function.   */
  8076. void show_stats(PPSNSSTATS stats, char *message)
  8077. {
  8078.    if(message) printf("** %s\n", message);
  8079.    if(stats) printf("%8d  %8d\n",
  8080.       stats->processed.files, stats->processed.folders);
  8081. }
  8082.  
  8083.   .
  8084.   .
  8085.   .
  8086.  
  8087. int rc;
  8088.  
  8089. /* Run the restore method */
  8090. printf("Files     Folders\n--------  --------\n");
  8091. rc = PsnsRunRestoreMethod(handle, "C files", show_stats, 0, 0);
  8092. if(rc) { printf("PsnsRunRestoreMethod returned %d\n", rc); return 1; }
  8093.  
  8094.  
  8095. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8096.  
  8097. /****************************************************/
  8098. /* Functions used:                                  */
  8099. /*    PsnsListBackupSets                            */
  8100. /*    PsnsTransferBackupSet                         */
  8101. /*                                                  */
  8102. /* Find all backup sets which use storage device    */
  8103. /* 'Drive E', and transfer them out.                */
  8104. /****************************************************/
  8105.  
  8106. HPSNSLIST hlist = 0;
  8107. BACKUPSETINFO info;
  8108. int rc;
  8109.  
  8110. /* Set up the search criteria with the storage      */
  8111. /* device we want to search on.                     */
  8112. strcpy(info.storageDevice, "Drive E");
  8113.  
  8114. /* Now list all the backup sets which use this      */
  8115. /* storage device.                                  */
  8116. do {
  8117.    rc = PsnsListBackupSets(handle, &hlist, &info, BS_STORAGEDEVICE);
  8118.    if(!rc && hlist) {
  8119.       /* For every backup set returned, print its name    */
  8120.       /* and transfer it out.                             */
  8121.       printf("Found backup method '%s'\n", info.name);
  8122.       rc = PsnsTransferBackupSet(handle, info.name, FALSE, 0);
  8123.    }
  8124. } while(!rc && hlist);
  8125.  
  8126. /* If we didn't get to the end of the list, close it */
  8127. if(hlist) PsnsCloseList(handle, &hlist);
  8128.  
  8129. if(rc) printf("Error encountered, rc = %d\n", rc);
  8130.  
  8131.  
  8132. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8133.  
  8134.  
  8135. /****************************************************/
  8136. /* Functions used:                                  */
  8137. /*    PsnsCreateBackupSet                           */
  8138. /*    PsnsBackupSetInfo                             */
  8139. /*                                                  */
  8140. /* Create a single device backup set on storage     */
  8141. /* device 'Drive E'  and set its description.       */
  8142. /****************************************************/
  8143.  
  8144. BACKUPSETINFO info = { 0 };
  8145. int rc;
  8146.  
  8147. /* Create the backup set */
  8148. rc = PsnsCreateBackupSet(handle, "Llama", "Drive E", "PATH=LlamaBackup", NULL, NULL);
  8149. if(rc) { printf("PsnsCreateBackupSet returned %d\n", rc); return 1; }
  8150.  
  8151. /* Set the description */
  8152. strcpy(info.description, "Contains complete backup of the Llama Files");
  8153. rc = PsnsBackupSetInfo(handle, "Llama", &info, BS_DESCRIPTION);
  8154. if(rc) { printf("PsnsBackupSetInfo returned %d\n", rc); return 1; }
  8155.  
  8156.  
  8157. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8158.  
  8159.  
  8160. /****************************************************/
  8161. /* Functions used:                                  */
  8162. /*    PsnsDeleteBackupSet                           */
  8163. /*                                                  */
  8164. /* Delete backup set "Llama".                       */
  8165. /****************************************************/
  8166.  
  8167. char answer[4];
  8168. int rc;
  8169.  
  8170. printf("Are you sure you want to do this? Type 'yes' to proceed.\n");
  8171. fgets(answer, 4, stdin);
  8172. if(strcmp(answer, "yes") == 0)
  8173.    rc = PsnsDeleteBackupSet(handle, "Llama");
  8174. if(rc) { printf("PsnsDeleteBackupSet returned %d\n", rc); return 1; }
  8175.  
  8176.  
  8177. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8178.  
  8179.  
  8180. /****************************************************/
  8181. /* Functions used:                                  */
  8182. /*    PsnsEmptyBackupSet                            */
  8183. /*                                                  */
  8184. /* Empty backup set "Llama".                        */
  8185. /****************************************************/
  8186.  
  8187. char answer[4];
  8188. int rc;
  8189.  
  8190. printf("Are you sure you want to lose this valuable data? Type 'yes' to proceed.\n");
  8191. fgets(answer, 4, stdin);
  8192. if(strcmp(answer, "yes") == 0)
  8193.    rc = PsnsEmptyBackupSet(handle, "Llama");
  8194. if(rc) { printf("PsnsEmptyBackupSet returned %d\n", rc); return 1; }
  8195.  
  8196.  
  8197. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8198.  
  8199.  
  8200. /****************************************************/
  8201. /* Functions used:                                  */
  8202. /*    PsnsGetLogFile                                */
  8203. /*                                                  */
  8204. /* Delete the log file for backup set 'Llama'.      */
  8205. /****************************************************/
  8206.  
  8207. char logfile[CCHMAXPATH];
  8208. int rc;
  8209.  
  8210. rc = PsnsGetLogFile(handle, "Llama", logfile);
  8211. if(rc) { printf("PsnsGetLogFile returned %d\n", rc); return 1; }
  8212. DosDelete(logfile);
  8213.  
  8214.  
  8215. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8216.  
  8217.  
  8218. /****************************************************/
  8219. /* Functions used:                                  */
  8220. /*    PsnsListStorageDevices                        */
  8221. /*    PsnsCreateStorageDevice                       */
  8222. /*                                                  */
  8223. /* List the creatable storage devices, prompt the   */
  8224. /* user to select one, and create a new storage     */
  8225. /* device.                                          */
  8226. /****************************************************/
  8227.  
  8228. int rc, i = 0, j;
  8229. HPSNSLIST hlist = 0;
  8230. STORAGEDEVICEINFO info;
  8231. char answer[4];
  8232. char *names[20];
  8233. char newname[PSNS_NAME_SIZE];
  8234.  
  8235. /* Display a list of the creatable storage devices */
  8236. printf("Select a storage device to create:\n");
  8237. do {
  8238.    rc = PsnsListStorageDevices(handle, &hlist, &info, SD_CREATABLE);
  8239.    if(!rc && hlist) {
  8240.       names[i] = strdup(info.name);
  8241.       printf("  %2d. %s\n", ++i, info.name);
  8242.    }
  8243. } while(!rc && hlist);
  8244.  
  8245. /* If we didn't get to the end of the list, close it */
  8246. if(hlist) PsnsCloseList(handle, &hlist);
  8247.  
  8248. if(rc) { printf("PsnsListStorageDevices returned %d\n", rc); return 1; }
  8249.  
  8250. /* Wait for the user to make a selection */
  8251. fgets(answer, 4, stdin);
  8252. j = atoi(answer);
  8253. if(j <= 0 || j > i)
  8254.    printf("You entered an invalid selection\n");
  8255. else {
  8256.    /* get the configuration from the user */
  8257.    char config[ 260];
  8258.    printf( "Enter the configuration string for the device\n");
  8259.    fgets( config, 260, stdin);
  8260.  
  8261.    /* Create a new storage device */
  8262.    rc = PsnsCreateStorageDevice(handle, names[j-1], config, newname);
  8263.    if(rc) { printf("PsnsCreateStorageDevice returned %d\n", rc); return 1; }
  8264.    printf("New storage device is '%s'.\n", newname);
  8265. }
  8266.  
  8267.  
  8268. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8269.  
  8270.  
  8271. /****************************************************/
  8272. /* Functions used:                                  */
  8273. /*    PsnsRefreshStorageDevices                     */
  8274. /*                                                  */
  8275. /* Refresh the list of available storage devices.   */
  8276. /****************************************************/
  8277.  
  8278. int rc;
  8279.  
  8280. rc = PsnsRefreshStorageDevices(handle);
  8281. if(rc) { printf("PsnsRefreshStorageDevices returned %d\n", rc); return 1; }
  8282.  
  8283.  
  8284. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8285.  
  8286.  
  8287. /****************************************************/
  8288. /* Functions used:                                  */
  8289. /*    PsnsDeleteStorageDevice                       */
  8290. /*                                                  */
  8291. /* Delete storage device 'Drive E'.                 */
  8292. /****************************************************/
  8293.  
  8294. int rc;
  8295.  
  8296. rc = PsnsDeleteStorageDevice(handle, "Drive E");
  8297. if(rc) { printf("PsnsDeleteStorageDevice returned %d\n", rc); return 1; }
  8298.  
  8299.  
  8300. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8301.  
  8302.  
  8303. /****************************************************/
  8304. /* Functions used:                                  */
  8305. /*    PsnsStorageDeviceInfo                         */
  8306. /*                                                  */
  8307. /* Find out which dynamic link library (DLL) is     */
  8308. /* used by storage device "Drive E".                */
  8309. /****************************************************/
  8310.  
  8311. int rc;
  8312. STORAGEDEVICEINFO info;
  8313.  
  8314. rc = PsnsStorageDeviceInfo(handle, "Drive E", &info, SD_NONE);
  8315. if(rc) { printf("PsnsStorageDeviceInfo returned %d\n", rc); return 1; }
  8316. printf("DLL name: %s\n", info.dllName);
  8317.  
  8318.  
  8319. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8320.  
  8321.  
  8322. /****************************************************/
  8323. /* Functions used:                                  */
  8324. /*    PsnsVolumeInfo                                */
  8325. /*    PsnsListVolumeBackupSets                      */
  8326. /*                                                  */
  8327. /* Print out space usage information for a volume.  */
  8328. /****************************************************/
  8329.  
  8330. void PrintSpaceUsage(PSNSHANDLE handle, ULONG volID)
  8331. {
  8332.    HPSNSLIST hlist = 0;
  8333.    VOLUMEINFO volInfo;
  8334.    BACKUPSETVOLUME bksVol;
  8335.    int rc;
  8336.  
  8337.    rc = PsnsVolumeInfo(handle, volID, &volInfo, 0);
  8338.    if(rc) return rc;
  8339.    printf("Free space: %d\nSpace used by PSnS: %d\n",
  8340.           volInfo.otherFree + volume.psnsFree, volInfo.psnsUsed);
  8341.    bksVol.id = volID;
  8342.    do {
  8343.       rc = PsnsListVolumeBackupSets(handle, &hlist, &bksVol);
  8344.       if(!rc && hlist)
  8345.          printf("   Backup set '%s': %d\n", bksVol.backupSet, bksVol.spaceUsed);
  8346.    } while(!rc && hlist);
  8347.    return rc;
  8348. }
  8349.  
  8350.  
  8351. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8352.  
  8353.  
  8354. /****************************************************/
  8355. /* Functions used:                                  */
  8356. /*    PsnsListVolumes                               */
  8357. /*    PsnsDeleteVolume                              */
  8358. /*                                                  */
  8359. /* Find all volumes on a storage device which have  */
  8360. /* no space used on them, and delete them.          */
  8361. /****************************************************/
  8362.  
  8363. int rc;
  8364. VOLUMEINFO info;
  8365. HPSNSLIST hlist = 0;
  8366.  
  8367. /* Set up the search criteria */
  8368. strcpy(info.storageDevice, "Diskette A (3.5\")"); /* Search for this storage device */
  8369. info.psnsUsed = 1;                                /* and less than 1 byte used      */
  8370.  
  8371. do {
  8372.    rc = PsnsListVolumes(handle, &hlist, &info,
  8373.       VOL_STORAGEDEVICE | VOL_PSNSUSED_LESS);
  8374.    if(!rc && hlist) {
  8375.       printf("Found empty volume %d\n", info.name);
  8376.       rc = PsnsDeleteVolume(handle, info.id);
  8377.    }
  8378. } while(!rc && hlist);
  8379.  
  8380. /* If we didn't get to the end of the list, close it */
  8381. if(hlist) PsnsCloseList(handle, &hlist);
  8382.  
  8383. if(rc) { printf("Error encountered, rc = %d\n", rc); return 1; }
  8384.  
  8385.  
  8386. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8387.  
  8388.  
  8389. /****************************************************/
  8390. /* Functions used:                                  */
  8391. /*    PsnsCreateVolume                              */
  8392. /*    PsnsAssociateVolume                           */
  8393. /*    PsnsActivateVolume                            */
  8394. /*                                                  */
  8395. /* Create a new diskette volume, associate it with  */
  8396. /* backup set 'Llama' and mark it as inactive.      */
  8397. /****************************************************/
  8398.  
  8399. int rc;
  8400. VOLUMEINFO info;
  8401. ULONG id;
  8402.  
  8403. /* Create a new volume */
  8404. rc = PsnsCreateVolume(handle, "Diskette A (3.5\")", &id);
  8405. if(rc) { printf("PsnsCreateVolume returned %d\n", rc); return 1; }
  8406. printf("New volume ID = %lu\n", id);
  8407.  
  8408. /* Associate the volume with a backup set */
  8409. rc = PsnsAssociateVolume(handle, id, "Llama");
  8410. if(rc) { printf("PsnsAssociateVolume returned %d\n", rc); return 1; }
  8411.  
  8412. /* Mark the volume as inactive */
  8413. rc = PsnsActivateVolume(handle, id, FALSE);
  8414. if(rc) { printf("PsnsActivateVolume returned %d\n", rc); return 1; }
  8415.  
  8416.  
  8417. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8418.  
  8419.  
  8420. /****************************************************/
  8421. /* Functions used:                                  */
  8422. /*    PsnsCreateEvent                               */
  8423. /*    PsnsEventInfo                                 */
  8424. /*                                                  */
  8425. /* Create a new event to perform an hourly backup   */
  8426. /* with backup method "Orange".                     */
  8427. /****************************************************/
  8428.  
  8429. int rc;
  8430. EVENTINFO info;
  8431. USHORT id;
  8432.  
  8433. /* Create the new event */
  8434. rc = PsnsCreateEvent(handle, EV_REGULAR, "Orange", &id);
  8435. if(rc) { printf("PsnsCreateEvent returned %d\n", rc); return 1; }
  8436. printf("New event ID = %hu\n", id);
  8437.  
  8438. /* Set up the time of the event */
  8439. info.info.regular.hours = 1;
  8440. info.info.regular.minutes = 0;
  8441. info.changedFilesOnly = EVENT_AS_METHOD;
  8442. info.showPreview = EVENT_NO;
  8443. info.active = TRUE;
  8444. strcpy(info.backupMethod, "Orange");
  8445. rc = PsnsEventInfo(handle, id, &info, EV_ALL);
  8446. if(rc) { printf("PsnsEventInfo returned %d\n", rc); return 1; }
  8447.  
  8448.  
  8449. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8450.  
  8451.  
  8452. /****************************************************/
  8453. /* Functions used:                                  */
  8454. /*    PsnsListEvents                                */
  8455. /*    PsnsActivateEvent                             */
  8456. /*                                                  */
  8457. /* List all events which use backup method "Apple"  */
  8458. /* and deactivate them.                             */
  8459. /****************************************************/
  8460.  
  8461. int rc;
  8462. EVENTINFO info;
  8463. HPSNSLIST hlist = 0;
  8464.  
  8465. /* Set up the search criteria */
  8466. strcpy(info.backupMethod, "Apple");
  8467.  
  8468. /* List all events which match the criteria */
  8469. do {
  8470.    rc = PsnsListEvents(handle, &hlist, &info, EV_BACKUPMETHOD);
  8471.    if(!rc && hlist) {
  8472.        printf("Found event, id = %hu\n", info.id);
  8473.        rc = PsnsActivateEvent(handle, info.id, FALSE);
  8474.    }
  8475. } while(!rc && hlist);
  8476.  
  8477. /* If we didn't get to the end of the list, close it */
  8478. if(hlist) PsnsCloseList(handle, &hlist);
  8479.  
  8480. if(rc) { printf("Error encountered, rc = %d\n", rc); return 1; }
  8481.  
  8482.  
  8483. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8484.  
  8485.  
  8486. /****************************************************/
  8487. /* Functions used:                                  */
  8488. /*    PsnsGetNextEvent                              */
  8489. /*    PsnsDeleteEvent                               */
  8490. /*                                                  */
  8491. /* Find out which event is due to occur next, and   */
  8492. /* delete it.                                       */
  8493. /****************************************************/
  8494.  
  8495. int rc;
  8496. EVENTINFO info;
  8497.  
  8498. /* Get the next event to occur */
  8499. rc = PsnsGetNextEvent(handle, &info);
  8500. if(rc == PSNS_NO_EVENTS) { printf("No events currently scheduled.\n"); return 0; }
  8501. if(rc) { printf("PsnsGetNextEvent returned %d\n", rc); return 1; }
  8502. printf("Next event is id = %hu.\n", info.id);
  8503.  
  8504. /* Delete the event */
  8505. rc = PsnsDeleteEvent(handle, info.id);
  8506. if(rc) { printf("PsnsDeleteEvent returned %d\n", rc); return 1; }
  8507.  
  8508.  
  8509. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8510.  
  8511.  
  8512. /****************************************************/
  8513. /* Functions used:                                  */
  8514. /*    PsnsCopyEvent                                 */
  8515. /*                                                  */
  8516. /* Copy event with the given ID and return the ID   */
  8517. /* of the new event.                                */
  8518. /****************************************************/
  8519.  
  8520. USHORT CopyEvent(PSNSHANDLE handle, USHORT id)
  8521. {
  8522.    USHORT newid;
  8523.    int rc;
  8524.  
  8525.    /* Copy the event */
  8526.    rc = PsnsCopyEvent(handle, id, &newid);
  8527.    if(rc) { printf("PsnsCopyEvent returned %d\n", rc); return (USHORT)-1; }
  8528.    printf("New id = %hu\n", newid);
  8529.    return newid;
  8530. }
  8531.  
  8532.  
  8533. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8534.  
  8535.  
  8536. /****************************************************/
  8537. /* Functions used:                                  */
  8538. /*    PsnsCreateFileFilter                          */
  8539. /*    PsnsFileFilterInfo                            */
  8540. /*    PsnsAddFileFilterRule                         */
  8541. /*                                                  */
  8542. /* Create a file filter to back up all the source   */
  8543. /* files in Project Watermelon.                     */
  8544. /****************************************************/
  8545.  
  8546. int rc;
  8547. FILEFILTERINFO info;
  8548. FILEFILTERRULE rule;
  8549.  
  8550. /* Create a new file filter */
  8551. rc = PsnsCreateFileFilter(handle, "Watermelon source", FILTER_LIST);
  8552. if(rc) { printf("PsnsCreateFileFilter returned %d\n", rc); return 1; }
  8553.  
  8554. /* Set the description */
  8555. strcpy(info.description, "Filter to select source for Project Watermelon");
  8556. rc = PsnsFileFilterInfo(handle, "Watermelon source", &info, FF_DESCRIPTION);
  8557. if(rc) { printf("PsnsFileFilterInfo returned %d\n", rc); return 1; }
  8558.  
  8559. /* Set up the first rule and add it */
  8560. rule.drive = 'D';
  8561. strcpy(rule.directory, "\\watermelon\\*\\");
  8562. strcpy(rule.pattern, "*.c");
  8563. rule.subdirectories = TRUE;
  8564. rule.include = TRUE;
  8565. rc = PsnsAddFileFilterRule(handle, "Watermelon source", &rule, 1);
  8566. if(rc) { printf("PsnsAddFileFilterRule returned %d\n", rc); return 1; }
  8567.  
  8568. /* Add more rules */
  8569. strcpy(rule.pattern, "*.cpp");
  8570. rc = PsnsAddFileFilterRule(handle, "Watermelon source", &rule, 1);
  8571. if(rc) { printf("PsnsAddFileFilterRule returned %d\n", rc); return 1; }
  8572. strcpy(rule.pattern, "*.h");
  8573. rc = PsnsAddFileFilterRule(handle, "Watermelon source", &rule, 1);
  8574. if(rc) { printf("PsnsAddFileFilterRule returned %d\n", rc); return 1; }
  8575.  
  8576.  
  8577. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8578.  
  8579.  
  8580. /****************************************************/
  8581. /* Functions used:                                  */
  8582. /*    PsnsListFileFilters                           */
  8583. /*    PsnsDeleteFileFilter                          */
  8584. /*                                                  */
  8585. /* List all file filters which match the file       */
  8586. /* E:\AARDVARK.EXE and delete them.                 */
  8587. /****************************************************/
  8588.  
  8589. HPSNSLIST hlist;
  8590. FILEFILTERINFO info;
  8591. int rc;
  8592.  
  8593. /* Set up the search criteria */
  8594. strcpy(info.searchFile, "E:\\AARDVARK.EXE");
  8595.  
  8596. /* Now list all the file filters which match this   */
  8597. /* file.                                            */
  8598. do {
  8599.    rc = PsnsListFileFilters(handle, &hlist, &info, FF_SEARCHFILE);
  8600.    if(!rc && hlist) {
  8601.       /* For every file filter returned, print its name   */
  8602.       /* and delete it.                                   */
  8603.       printf("Found file filter '%s'\n", info.name);
  8604.       rc = PsnsDeleteFileFilter(handle, info.name);
  8605.    }
  8606. } while(!rc && hlist);
  8607.  
  8608. /* If we didn't get to the end of the list, close it */
  8609. if(hlist) PsnsCloseList(handle, &hlist);
  8610.  
  8611. if(rc) printf("Error encountered, rc = %d\n", rc);
  8612.  
  8613.  
  8614. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8615.  
  8616.  
  8617. /****************************************************/
  8618. /* Functions used:                                  */
  8619. /*    PsnsRenameFileFilter                          */
  8620. /*                                                  */
  8621. /* Rename file filter 'Watermelon source' to        */
  8622. /* 'my filter'.                                     */
  8623. /****************************************************/
  8624.  
  8625. int rc;
  8626.  
  8627. rc = PsnsRenameFileFilter(handle, "Watermelon source", "my filter");
  8628. if(rc) { printf("PsnsRenameFileFilter returned %d\n", rc); return 1; }
  8629.  
  8630.  
  8631. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8632.  
  8633.  
  8634. /****************************************************/
  8635. /* Functions used:                                  */
  8636. /*    PsnsCopyFileFilter                            */
  8637. /*                                                  */
  8638. /* Copy file filter 'Watermelon source' to          */
  8639. /* 'Watermelon II'.                                 */
  8640. /****************************************************/
  8641.  
  8642. int rc;
  8643.  
  8644. rc = PsnsCopyFileFilter(handle, "Watermelon source", "Watermelon II");
  8645. if(rc) { printf("PsnsCopyFileFilter returned %d\n", rc); return 1; }
  8646.  
  8647.  
  8648. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8649.  
  8650.  
  8651. /****************************************************/
  8652. /* Functions used:                                  */
  8653. /*    PsnsFileFilterInfo                            */
  8654. /*    PsnsFileFilterRuleInfo                        */
  8655. /*                                                  */
  8656. /* Print out details of a file filter.              */
  8657. /****************************************************/
  8658.  
  8659. int show_filter(PSNSHANDLE handle, const char *name)
  8660. {
  8661.    FILEFILTERINFO info;
  8662.    FILEFILTERRULE rule;
  8663.    int rc, i;
  8664.  
  8665.    rc = PsnsFileFilterInfo(handle, name, &info, FF_NONE);
  8666.    if(rc) return rc;
  8667.    printf("File filter '%s'\n%s", info.name, info.description);
  8668.  
  8669.    for(i = 1; i <= info.numRules; i++) {
  8670.       rc = PsnsFileFilterRuleInfo(handle, name, i, &rule, FF_NONE);
  8671.       if(rc) return rc;
  8672.       printf("   %s %c:%s%s\\%s\n", rule.include ? "Include" : "Exclude",
  8673.          rule.drive, rule.directory,
  8674.          rule.subdirectories ? "\\*" : "",
  8675.          rule.pattern);
  8676.    }
  8677.    return 0;
  8678. }
  8679.  
  8680.  
  8681. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8682.  
  8683.  
  8684. /****************************************************/
  8685. /* Functions used:                                  */
  8686. /*    PsnsDeleteFileFilterRule                      */
  8687. /*                                                  */
  8688. /* Delete all the rules in a file filter.           */
  8689. /****************************************************/
  8690.  
  8691. int rc;
  8692. do {
  8693.    rc = PsnsDeleteFileFilterRule(handle, "Watermelon source", 1);
  8694. } while(rc == 0);
  8695.  
  8696.  
  8697. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8698.  
  8699.  
  8700. /****************************************************/
  8701. /* Functions used:                                  */
  8702. /*    PsnsCreateRulebook                            */
  8703. /*    PsnsRulebookInfo                              */
  8704. /*    PsnsAddRulebookRule                           */
  8705. /*                                                  */
  8706. /* Create a rulebook to keep 10 generations of all  */
  8707. /* .foo and .bar files.                             */
  8708. /****************************************************/
  8709.  
  8710. int rc;
  8711. RULEBOOKINFO info;
  8712. RULEBOOKRULE rule;
  8713.  
  8714. /* Create a new rulebook */
  8715. rc = PsnsCreateRulebook(handle, "My rulebook");
  8716. if(rc) { printf("PsnsCreateRulebook returned %d\n", rc); return 1; }
  8717.  
  8718. /* Set the description */
  8719. strcpy(info.description, "Rulebook to keep 10 generations of .foo and .bar files");
  8720. rc = PsnsRulebookInfo(handle, "My rulebook", &info, RB_DESCRIPTION);
  8721. if(rc) { printf("PsnsRulebookInfo returned %d\n", rc); return 1; }
  8722.  
  8723. /* Set up the first rule and add it */
  8724. rule.drive = 'D';
  8725. strcpy(rule.directory, "\\");
  8726. strcpy(rule.pattern, "*.foo");
  8727. rule.subdirectories = TRUE;
  8728. rule.generations = 10;
  8729. rule.compression = PSNS_DEFAULT;
  8730. rc = PsnsAddRulebookRule(handle, "My rulebook", &rule, 1);
  8731. if(rc) { printf("PsnsAddRulebookRule returned %d\n", rc); return 1; }
  8732.  
  8733. /* Add the other rule */
  8734. strcpy(rule.pattern, "*.bar");
  8735. rc = PsnsAddRulebookRule(handle, "My rulebook", &rule, 1);
  8736. if(rc) { printf("PsnsAddRulebookRule returned %d\n", rc); return 1; }
  8737.  
  8738.  
  8739. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8740.  
  8741.  
  8742. /****************************************************/
  8743. /* Functions used:                                  */
  8744. /*    PsnsListRulebooks                             */
  8745. /*    PsnsDeleteRulebook                            */
  8746. /*                                                  */
  8747. /* List all rulebooks and delete them.              */
  8748. /****************************************************/
  8749.  
  8750. HPSNSLIST hlist;
  8751. RULEBOOKINFO info;
  8752. int rc;
  8753.  
  8754. /* List all rulebooks */
  8755. do {
  8756.    rc = PsnsListRulebooks(handle, &hlist, &info, RB_NONE);
  8757.    if(!rc && hlist) {
  8758.       /* For every rulebook returned, print its name and  */
  8759.       /* delete it.                                       */
  8760.       printf("Found rulebook '%s'\n", info.name);
  8761.       rc = PsnsDeleteRulebook(handle, info.name);
  8762.    }
  8763. } while(!rc && hlist);
  8764.  
  8765. /* If we didn't get to the end of the list, close it */
  8766. if(hlist) PsnsCloseList(handle, &hlist);
  8767.  
  8768. if(rc) printf("Error encountered, rc = %d\n", rc);
  8769.  
  8770.  
  8771. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8772.  
  8773.  
  8774. /****************************************************/
  8775. /* Functions used:                                  */
  8776. /*    PsnsRenameRulebook                            */
  8777. /*                                                  */
  8778. /* Rename file filter 'My rulebook' to 'Spoon'.     */
  8779. /****************************************************/
  8780.  
  8781. int rc;
  8782.  
  8783. rc = PsnsRenameRulebook(handle, "My rulebook", "Spoon");
  8784. if(rc) { printf("PsnsRenameRulebook returned %d\n", rc); return 1; }
  8785.  
  8786.  
  8787. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8788.  
  8789.  
  8790. /****************************************************/
  8791. /* Functions used:                                  */
  8792. /*    PsnsCopyRulebook                              */
  8793. /*                                                  */
  8794. /* Copy file filter 'My rulebook' to                */
  8795. /* 'My other rulebook'.                             */
  8796. /****************************************************/
  8797.  
  8798. int rc;
  8799.  
  8800. rc = PsnsCopyRulebook(handle, "My rulebook", "My other rulebook");
  8801. if(rc) { printf("PsnsCopyRulebook returned %d\n", rc); return 1; }
  8802.  
  8803.  
  8804. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8805.  
  8806.  
  8807. /****************************************************/
  8808. /* Functions used:                                  */
  8809. /*    PsnsRulebookInfo                              */
  8810. /*    PsnsRulebookRuleInfo                          */
  8811. /*                                                  */
  8812. /* Print out details of a rulebook.                 */
  8813. /****************************************************/
  8814.  
  8815. int show_rulebook(PSNSHANDLE handle, const char *name)
  8816. {
  8817.    RULEBOOKINFO info;
  8818.    RULEBOOKRULE rule;
  8819.    int rc, i;
  8820.  
  8821.    rc = PsnsRulebookInfo(handle, name, &info, RB_NONE);
  8822.    if(rc) return rc;
  8823.    printf("Rulebook '%s'\n%s", info.name, info.description);
  8824.  
  8825.    for(i = 1; i <= info.numRules; i++) {
  8826.       rc = PsnsRulebookRuleInfo(handle, name, i, &rule, RB_NONE);
  8827.       if(rc) return rc;
  8828.       printf("%c:%s%s\\%s\n : %d generations, %scompression",
  8829.          rule.drive, rule.directory,
  8830.          rule.subdirectories ? "\\*" : "",
  8831.          rule.pattern, rule.generations,
  8832.          rule.compression == PSNS_DEFAULT ? "default " :
  8833.             (rule.compression == PSNS_COMPRESSION ? "" : "no "));
  8834.    }
  8835.    return 0;
  8836. }
  8837.  
  8838.  
  8839. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8840.  
  8841.  
  8842. /****************************************************/
  8843. /* Functions used:                                  */
  8844. /*    PsnsDeleteRulebookRule                        */
  8845. /*                                                  */
  8846. /* Delete all the rules in a rulebook.              */
  8847. /****************************************************/
  8848.  
  8849. int rc;
  8850. do {
  8851.    rc = PsnsDeleteRulebookRule(handle, "My rulebook", 1);
  8852. } while(rc == 0);
  8853.  
  8854.  
  8855. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8856.  
  8857.  
  8858. /****************************************************/
  8859. /* Functions used:                                  */
  8860. /*    PsnsListSourceDrives                          */
  8861. /*    PsnsSelectSourceDrive                         */
  8862. /*                                                  */
  8863. /* Deselect all LAN drives for backup.              */
  8864. /****************************************************/
  8865.  
  8866. HPSNSLIST hlist;
  8867. SOURCEDRIVEINFO info;
  8868. int rc;
  8869.  
  8870. /* Set up the search criteria */
  8871. info.type = DRI_LANDRIVE;
  8872.  
  8873. /* List all source drives */
  8874. do {
  8875.    rc = PsnsListSourceDrives(handle, &hlist, &info, DR_TYPE);
  8876.    if(!rc && hlist) {
  8877.       /* For every source returned, print its letter and */
  8878.       /* deselect it.                                    */
  8879.       printf("Found LAN drive '%c'\n", info.letter);
  8880.       rc = PsnsSelectSourceDrive(handle, info.letter, FALSE);
  8881.    }
  8882. } while(!rc && hlist);
  8883.  
  8884. /* If we didn't get to the end of the list, close it */
  8885. if(hlist) PsnsCloseList(handle, &hlist);
  8886.  
  8887. if(rc) printf("Error encountered, rc = %d\n", rc);
  8888.  
  8889.  
  8890. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8891.  
  8892.  
  8893. /****************************************************/
  8894. /* Functions used:                                  */
  8895. /*    PsnsRefreshSourceDrives                       */
  8896. /*    PsnsSourceDriveType                           */
  8897. /*                                                  */
  8898. /* Refresh the list of source drives, then set the  */
  8899. /* type of drive H to be a hard disk.               */
  8900. /****************************************************/
  8901.  
  8902. int rc;
  8903.  
  8904. rc = PsnsRefreshSourceDrives(handle);
  8905. if(rc) { printf("PsnsRefreshSourceDrives returned %d\n", rc); return 1; }
  8906.  
  8907. rc = PsnsSourceDriveType(handle, 'H', DRI_HARDDISK);
  8908. if(rc) { printf("PsnsSourceDriveType returned %d\n", rc); return 1; }
  8909.  
  8910.  
  8911. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8912.  
  8913.  
  8914. /****************************************************/
  8915. /* Functions used:                                  */
  8916. /*    PsnsListFiles                                 */
  8917. /*    PsnsAddFile                                   */
  8918. /*    PsnsDropFiles                                 */
  8919. /*    PsnsPurgeFiles                                */
  8920. /*    PsnsCloseList                                 */
  8921. /*                                                  */
  8922. /* Find all files which have a generation backed    */
  8923. /* up before a given date, and drop them.           */
  8924. /****************************************************/
  8925.  
  8926. /* First define the statistics callback function.   */
  8927. void show_stats(PPSNSSTATS stats, char *message)
  8928. {
  8929.    if(message) printf("** %s\n", message);
  8930.    if(stats) printf("%8d  %8d\n",
  8931.       stats->processed.files, stats->processed.folders);
  8932. }
  8933.  
  8934. int DropBefore(PSNSHANDLE handle, char *backupset, FDATE date)
  8935. {
  8936.    HPSNSLIST hlist;
  8937.    PSNSFILEINFO info;
  8938.    short gen;
  8939.    int rc;
  8940.  
  8941.    /* Set up the search criteria */
  8942.    strcpy(info.backupSet, backupset)
  8943.    info.backupDate = date;
  8944.  
  8945.    /* List all files which have a generation backed up before that date */
  8946.    do {
  8947.       rc = PsnsListFiles(handle, &hlist, &info, FILE_BACKUPDATE_BEFORE | FILE_ALLGENERATIONS);
  8948.       if(!rc && hlist) {
  8949.          printf("%s - generation %h\n ", info.filename, info.thisGeneration);
  8950.          PsnsAddFile(handle, info.filename, info.thisGeneration);
  8951.       }
  8952.    } while(!rc && hlist);
  8953.  
  8954.    /* If we didn't get to the end of the list, close it */
  8955.    if(hlist) PsnsCloseList(handle, &hlist);
  8956.  
  8957.    if(rc) {
  8958.       printf("Error encountered, rc = %d\nNo generations dropped.", rc);
  8959.       PsnsPurgeFiles(handle);
  8960.       return rc;
  8961.    }
  8962.  
  8963.    rc = PsnsDropFiles(handle, backupset, show_stats);
  8964.    return rc;
  8965. }
  8966.  
  8967.  
  8968. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  8969.  
  8970.  
  8971. /****************************************************/
  8972. /* Functions used:                                  */
  8973. /*    PsnsDefaults                                  */
  8974. /*    PsnsSettings                                  */
  8975. /*                                                  */
  8976. /* Show what the current defaults and settings are. */
  8977. /****************************************************/
  8978.  
  8979. PSNSSETTINGS settings;
  8980. PSNSDEFAULTS defaults;
  8981. int rc;
  8982.  
  8983. rc = PsnsSettings(handle, &settings, SET_NONE);
  8984. if(rc) { printf("PsnsSettings returned %d\n", rc); return 1; }
  8985. printf("Manual backup priority: %s\n", settings.manualPriority == HIGH ? "High" : "Normal");
  8986. printf("Automatic backup priority: %s\n", settings.autoPriority == HIGH ? "High" : "Normal");
  8987. printf("Temporary file path: %s\n", settings.tempPath);
  8988. printf("Logging: %s\n", settings.flags & SET_LOG ? "On" : "Off");
  8989. if(settings.flags & SET_LOG & SET_LOG_SUCCESSES) printf("  Log individial successes\n");
  8990. if(settings.flags & SET_LOG & SET_LOG_FAILURES) printf("  Log individial failures\n");
  8991. printf("Backup user exit %s\n", settings.flags & SET_BACKUP_EXIT ? "enabled" : "disabled");
  8992. printf("Restore user exit %s\n", settings.flags & SET_RESTORE_EXIT ? "enabled" : "disabled");
  8993. printf("ACL backup %s\n", settings.enableACLBackup ? "enabled" : "disabled");
  8994. if(settings.enableACLBackup) printf("UAD file: %s\n", settings.uadFilename);
  8995.  
  8996. rc = PsnsDefaults(handle, &defaults, SET_NONE);
  8997. if(rc) { printf("PsnsDefaults returned %d\n", rc); return 1; }
  8998. printf("Default file filter: %s\n", defaults.fileFilter);
  8999. printf("Default rulebook: %s\n", defaults.rulebook);
  9000. printf("Default backup set: %s\n", defaults.backupSet);
  9001. printf("Default compression: %s\n", defaults.compression ? "PSnS compression" : "No compression");
  9002. printf("Default generations: %d\n", defaults.generations);
  9003.  
  9004.  
  9005. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  9006.  
  9007.  
  9008. /****************************************************/
  9009. /* Functions used:                                  */
  9010. /*    PsnsMessageCallback                           */
  9011. /*                                                  */
  9012. /* Register a message callback which logs errors to */
  9013. /* a file and then takes the default action.        */
  9014. /****************************************************/
  9015.  
  9016. ULONG callback(const char *msg, ULONG style, void *privates)
  9017. {
  9018.    FILE *f = (FILE *)privates;
  9019.    fputs(msg, f); fputc('\n', f);
  9020.    return PSNSM_DEFAULT;
  9021. }
  9022.  
  9023.   .
  9024.   .
  9025.   .
  9026.  
  9027. /* Main program */
  9028. FILE *f;
  9029.  
  9030. f = fopen("D:\\PSNS\\API.LOG", "w");
  9031. PsnsMessageCallback(handle, callback, f);
  9032.  
  9033.  
  9034. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  9035.  
  9036.  
  9037. /****************************************************/
  9038. /* Functions used:                                  */
  9039. /*    PsnsGetMessageText                            */
  9040. /*                                                  */
  9041. /* Print out the message corresponding to an API    */
  9042. /* error code.                                      */
  9043. /****************************************************/
  9044.  
  9045. int print_message(PSNSHANDLE handle, int code)
  9046. {
  9047.    int    rc;
  9048.    char  *buffer;
  9049.    ULONG  cbString;
  9050.  
  9051.    rc = PsnsGetMessageText(handle, code, NULL, &cbString);
  9052.    if( rc) return rc;
  9053.  
  9054.    buffer = malloc( cbString);
  9055.    rc = PsnsGetMessageText(handle, code, buffer, &cbString);
  9056.    if( !rc)
  9057.       printf("* %s\n", buffer);
  9058.    free( buffer);
  9059.    return rc;
  9060. }
  9061.  
  9062.  
  9063. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  9064.  
  9065.  
  9066. /****************************************************/
  9067. /* Functions used:                                  */
  9068. /*    PsnsGetLastError                              */
  9069. /*                                                  */
  9070. /* Print out the details of the last error for a    */
  9071. /* handle.                                          */
  9072. /****************************************************/
  9073.  
  9074. int last_error( PSNSHANDLE handle)
  9075. {
  9076.    int    rc;
  9077.    char  *buffer;
  9078.    ULONG  cbString;
  9079.  
  9080.    rc = PsnsGetLastError( handle, NULL, &cbString);
  9081.    if( !rc) return rc;
  9082.  
  9083.    buffer = malloc( cbString);
  9084.    rc = PsnsGetLastError( handle, buffer, &cbString);
  9085.    if( !rc)
  9086.       printf("* %s\n", buffer);
  9087.    free( buffer);
  9088.    return rc;
  9089. }
  9090.  
  9091.  
  9092. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  9093.  
  9094.  
  9095. /****************************************************/
  9096. /* Functions used:                                  */
  9097. /*    PsnsPurgeFiles                                */
  9098. /*    PsnsAddFile                                   */
  9099. /*    PsnsBackupFiles                               */
  9100. /*                                                  */
  9101. /* Back up a selection of files                     */
  9102. /****************************************************/
  9103.  
  9104. int rc;
  9105. BACKUPMETHODINFO backupMethodInfo;
  9106.  
  9107. /* empty the file list for this handle */
  9108. rc = PsnsPurgeFiles( handle);
  9109. if( rc) { printf( "PsnsPurgeFiles returned %d", rc); return rc; }
  9110.  
  9111. /* add a single file to the list */
  9112. rc = PsnsAddFile( handle, "D:\\Setup.cmd", 0);
  9113. if( rc) { printf( "PsnsAddFile returned %d", rc); return rc; }
  9114.  
  9115. /* add a directory and its contents */
  9116. rc = PsnsAddFile( handle, "D:\\Data\\", 0);
  9117. if( rc) { printf( "PsnsAddFile returned %d", rc); return rc; }
  9118.  
  9119. /* add a directory and all files & directories beneath it */
  9120. rc = PsnsAddFile( handle, "D:\\Code\\*\\", 0);
  9121. if( rc) { printf( "PsnsAddFile returned %d", rc); return rc; }
  9122.  
  9123. /* Fill in some details for the backup method */
  9124. strcpy( backupMethodInfo.backupSet, "Project Llama");
  9125. backupMethodInfo.compression = PSNS_COMPRESSION;
  9126. backupMethodInfo.generations = 8;
  9127. backupMethodInfo.changedFilesOnly = FALSE;
  9128.  
  9129. /* back up the files */
  9130. rc = PsnsBackupFiles( handle, &backupMethodInfo, fnCallBack);
  9131. if( rc) { printf( "PsnsBackupFiles returned %d", rc); return rc; }
  9132.  
  9133. return PSNS_OK;
  9134.  
  9135.  
  9136. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  9137.  
  9138.  
  9139. /****************************************************/
  9140. /* Functions used:                                  */
  9141. /*    PsnsPurgeFiles                                */
  9142. /*    PsnsAddFile                                   */
  9143. /*    PsnsRestoreFiles                              */
  9144. /*                                                  */
  9145. /* Restore a selection of files                     */
  9146. /****************************************************/
  9147.  
  9148. int rc;
  9149. RESTOREMETHODINFO restoreMethodInfo;
  9150.  
  9151. /* empty the file list for this handle */
  9152. rc = PsnsPurgeFiles( handle);
  9153. if( rc) { printf( "PsnsPurgeFiles returned %d", rc); return rc; }
  9154.  
  9155. /* add a single file to the list */
  9156. rc = PsnsAddFile( handle, "D:\\Setup.cmd", 0);
  9157. if( rc) { printf( "PsnsAddFile returned %d", rc); return rc; }
  9158.  
  9159. /* add a directory and its contents */
  9160. rc = PsnsAddFile( handle, "D:\\Data\\", 0);
  9161. if( rc) { printf( "PsnsAddFile returned %d", rc); return rc; }
  9162.  
  9163. /* add a directory and all files & directories beneath it */
  9164. rc = PsnsAddFile( handle, "D:\\Code\\*\\", 0);
  9165. if( rc) { printf( "PsnsAddFile returned %d", rc); return rc; }
  9166.  
  9167. /* Fill in some details for the restore method */
  9168. strcpy( restoreMethodInfo.backupSet, "Project Llama");
  9169.  
  9170. /* restore the files */
  9171. rc = PsnsRestoreFiles( handle, &restoreMethodInfo, fnCallBack);
  9172. if( rc) { printf( "PsnsRestoreFiles returned %d", rc); return rc; }
  9173.  
  9174. return PSNS_OK;
  9175.  
  9176.  
  9177. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  9178.  
  9179.  
  9180. /****************************************************/
  9181. /* Functions used:                                  */
  9182. /*    PsnsGetBackupSetConfig                        */
  9183. /*    PsnsSetBackupSetConfig                        */
  9184. /*                                                  */
  9185. /* Make sure an optical backup set doesn't play a   */
  9186. /* sound when requesting a volume                   */
  9187. /****************************************************/
  9188.  
  9189. int quieten_backupset( PSNSHANDLE handle, const char *backupset)
  9190. {
  9191.    int   rc = PSNS_OK;
  9192.    char *string;
  9193.    ULONG cbString, cbStringInc;
  9194.  
  9195.    /* find out how large a buffer is needed */
  9196.    rc = PsnsGetBackupSetConfig( handle, backupset, NULL, &cbString, NULL, NULL);
  9197.    if( rc) return rc;
  9198.  
  9199.    string = malloc( cbString);
  9200.  
  9201.    /* query the configuration string */
  9202.    rc = PsnsGetBackupSetConfig( handle, backupset, string, &cbString, NULL, NULL);
  9203.    if( !rc && strstr( string, "BEEP=YES"))
  9204.       /* turn beeping off */
  9205.       rc = PsnsSetBackupSetConfig( handle, backupset, "BEEP=NO", NULL);
  9206.  
  9207.    free( string);
  9208.  
  9209.    return rc;
  9210. }
  9211.  
  9212.  
  9213. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  9214.  
  9215.  
  9216. /****************************************************/
  9217. /* Functions used:                                  */
  9218. /*    PsnsGetStorageDeviceConfig                    */
  9219. /*                                                  */
  9220. /* Print out the letter of the hard drive used by   */
  9221. /* the device for storing backed up data.           */
  9222. /****************************************************/
  9223.  
  9224. int print_path( PSNSHANDLE handle, const char *device)
  9225. {
  9226.    int   rc = PSNS_OK;
  9227.    char *string;
  9228.    ULONG cbString;
  9229.  
  9230.    /* find out how large a buffer is needed */
  9231.    rc = PsnsGetStorageDeviceConfig( handle, device, 0, &cbString);
  9232.    if( rc) return rc;
  9233.  
  9234.    string = malloc( cbString);
  9235.  
  9236.    /* query the configuration string */
  9237.    rc = PsnsGetStorageDeviceConfig( handle, device, string, &cbString);
  9238.    if( !rc) {
  9239.       char strDrive[] = "DRIVE=";
  9240.  
  9241.       /* find the `drive' keyword */
  9242.       char *letter = strstr( string, strDrive) + strlen( strDrive);
  9243.       printf( "%s uses drive %c\n", device, *letter);
  9244.    }
  9245.  
  9246.    free( string);
  9247.  
  9248.    return rc;
  9249. }
  9250.  
  9251.  
  9252. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  9253.  
  9254.  
  9255. /****************************************************/
  9256. /* Functions used:                                  */
  9257. /*    PsnsSetStorageDeviceConfig                    */
  9258. /*                                                  */
  9259. /* Update the location of the ADSM options file.    */
  9260. /****************************************************/
  9261.  
  9262. int rc;
  9263.  
  9264. rc = PsnsSetStorageDeviceConfig( handle, "ADSM", "OPTFILE=E:\\DSM.OPT");
  9265. if( rc) printf( "PsnsSetStorageDeviceConfig returned %d\n", rc);
  9266.  
  9267.  
  9268. ΓòÉΓòÉΓòÉ <hidden> Example ΓòÉΓòÉΓòÉ
  9269.  
  9270. This example hasn't been written yet. 
  9271.  
  9272.  
  9273. ΓòÉΓòÉΓòÉ 6. Backup methods ΓòÉΓòÉΓòÉ
  9274.  
  9275. The main way to back up files with OS/2 Warp Server Backup/Restore is by using 
  9276. backup methods. A backup method tells OS/2 Warp Server Backup/Restore which 
  9277. files you want to back up, how you want to back them up and to where you want 
  9278. to back them up.  The following sections tell you how to create, manipulate and 
  9279. run backup methods. 
  9280.  
  9281.      Working with backup methods 
  9282.  
  9283.      Running and estimating backup methods 
  9284.  
  9285.  
  9286. ΓòÉΓòÉΓòÉ 6.1. Working with backup methods ΓòÉΓòÉΓòÉ
  9287.  
  9288. You can create a backup method using the C API by calling the function 
  9289. PsnsCreateBackupMethod. This creates a new backup method with the given name. 
  9290. The backup method is created with default settings; you should change these 
  9291. with PsnsBackupMethodInfo to make the backup method perform the task you want. 
  9292.  
  9293. To rename, copy and delete backup methods, use the functions 
  9294. PsnsRenameBackupMethod, PsnsCopyBackupMethod and PsnsDeleteBackupMethod. 
  9295.  
  9296. To see the full range of settings which can be changed for a backup method and 
  9297. descriptions of what they do, see the BACKUPMETHODINFO structure. To inspect or 
  9298. change the settings, use the function PsnsBackupMethodInfo. This function takes 
  9299. as arguments a backup method name, a pointer to a BACKUPMETHODINFO structure 
  9300. and an integer mask.  This mask controls which of the backup method settings 
  9301. are changed:  to change all of the settings, use BM_ALL; to change none of the 
  9302. settings but just inspect the current ones, use BM_NONE. To change some 
  9303. combination of different settings, use the logical OR operator to combine 
  9304. several mask values.  For more information, see PsnsBackupMethodInfo. 
  9305.  
  9306. To list backup methods or search for backup methods which match certain 
  9307. criteria, use PsnsListBackupMethods. This works in the same way as all the 
  9308. other API listing functions. 
  9309.  
  9310.  
  9311. ΓòÉΓòÉΓòÉ 6.2. Running and estimating backup methods ΓòÉΓòÉΓòÉ
  9312.  
  9313. The main way to back up files with OS/2 Warp Server Backup/Restore is by 
  9314. running a backup method. To do this, use the function PsnsRunBackupMethod. This 
  9315. function takes as arguments the name of the backup method and a pointer to a 
  9316. callback function.  As the backup progresses, there will be some information 
  9317. which OS/2 Warp Server Backup/Restore would like to communicate to the user 
  9318. about which object is currently being backed up and statistics about the 
  9319. numbers of files, folders and bytes which have been backed up successfully. 
  9320. You can supply PsnsRunBackupMethod with a pointer to a callback function, which 
  9321. should be of type PSNSSTATSFN.  The callback function takes two arguments: the 
  9322. first is a pointer to a PSNSSTATS structure, which contains information about 
  9323. files, folders and bytes processed, as well as time taken, estimated total 
  9324. time, average data rate and space left on the backup media. If this pointer is 
  9325. NULL then there is no updated statistics information to be displayed.  The 
  9326. second argument is a pointer to a text message which may contain the name of an 
  9327. object being currently backed up, or else a progress message such as "Rewinding 
  9328. tape".  If this is NULL then there is no message to be displayed. 
  9329.  
  9330. To get information about how many files and folders would be backed up by a 
  9331. backup method but without actually running the backup, use 
  9332. PsnsEstimateBackupMethod. This tells OS/2 Warp Server Backup/Restore to scan 
  9333. the source drives and work out which files need to be backed up, and then 
  9334. return the results in an ESTIMATE structure, along with the estimated time for 
  9335. the backup, based on performance in previous backups to the same storage 
  9336. device.  Note that the first time you use a storage device, the estimated time 
  9337. will be 0 since there are no previous backups on which to base the estimate. 
  9338.  
  9339.  
  9340. ΓòÉΓòÉΓòÉ 7. Restore methods ΓòÉΓòÉΓòÉ
  9341.  
  9342. The main way to restore files with OS/2 Warp Server Backup/Restore is by using 
  9343. restore methods. A backup method tells OS/2 Warp Server Backup/Restore which 
  9344. files you want to restore, to where you want to restore them, and how to choose 
  9345. which generation will be restored. The following sections tell you how to 
  9346. create, manipulate and run restore methods. 
  9347.  
  9348.      Working with restore methods 
  9349.  
  9350.      Running and estimating restore methods 
  9351.  
  9352.  
  9353. ΓòÉΓòÉΓòÉ 7.1. Working with restore methods ΓòÉΓòÉΓòÉ
  9354.  
  9355. You can create a restore method using the C API by calling the function 
  9356. PsnsCreateRestoreMethod. This creates a new restore method with the given name. 
  9357. The restore method is created with default settings; you should change these 
  9358. with PsnsRestoreMethodInfo to make the restore method perform the task you 
  9359. want. 
  9360.  
  9361. To rename, copy and delete restore methods, use the functions 
  9362. PsnsRenameRestoreMethod, PsnsCopyRestoreMethod and PsnsDeleteRestoreMethod. 
  9363.  
  9364. To see the full range of settings which can be changed for a restore method and 
  9365. descriptions of what they do, see the RESTOREMETHODINFO structure. To inspect 
  9366. or change the settings, use the function PsnsRestoreMethodInfo. This function 
  9367. takes as arguments a restore method name, a pointer to a RESTOREMETHODINFO 
  9368. structure and an integer mask.  This mask controls which of the restore method 
  9369. settings are changed:  to change all of the settings, use RM_ALL; to change 
  9370. none of the settings but just inspect the current ones, use RM_NONE. To change 
  9371. some combination of different settings, use the logical OR operator to combine 
  9372. several mask values.  For more information, see PsnsRestoreMethodInfo. 
  9373.  
  9374. To list restore methods or search for restore methods which match certain 
  9375. criteria, use PsnsListRestoreMethods. This works in the same way as all the 
  9376. other API listing functions. 
  9377.  
  9378.  
  9379. ΓòÉΓòÉΓòÉ 7.2. Running and estimating restore methods ΓòÉΓòÉΓòÉ
  9380.  
  9381. The main way to restore files with OS/2 Warp Server Backup/Restore is by 
  9382. running a restore method. To do this, use the function PsnsRunRestoreMethod. 
  9383. This function takes as arguments the name of the restore method and a pointer 
  9384. to a callback function.  As the restore progresses, there will be some 
  9385. information that OS/2 Warp Server Backup/Restore would like to communicate to 
  9386. the user about which file is currently being restored and statistics about the 
  9387. numbers of files, folders and bytes which have been restored successfully.  You 
  9388. can supply PsnsRunRestoreMethod with a pointer to a callback function, which 
  9389. should be of type PSNSSTATSFN.  The callback function takes two arguments: the 
  9390. first is a pointer to a PSNSSTATS structure, which contains information about 
  9391. files, folders and bytes processed, as well as time taken, estimated total time 
  9392. and average data rate. If this pointer is NULL then there is no updated 
  9393. statistics information to be displayed.  The second argument is a pointer to a 
  9394. text message which may contain the name of a file being currently backed up, or 
  9395. else a progress message such as "Rewinding tape".  If this is NULL then there 
  9396. is no message to be displayed. 
  9397.  
  9398. To get information about how many files and folders would be restored by a 
  9399. restore method but without actually running the restore, use 
  9400. PsnsEstimateRestoreMethod. This tells OS/2 Warp Server Backup/Restore to scan 
  9401. the backup set and work out which files would need to be restored, and then 
  9402. return the results in a ESTIMATE structure, along with the estimated time for 
  9403. the restore, based on performance in previous restores to the same storage 
  9404. device.  Note that the first time you use a storage device, the estimated time 
  9405. will be 0 since there are no previous restores on which to base the estimate. 
  9406.  
  9407.  
  9408. ΓòÉΓòÉΓòÉ 8. Backup sets ΓòÉΓòÉΓòÉ
  9409.  
  9410. A backup set is where data is stored by OS/2 Warp Server Backup/Restore  A 
  9411. backup set is associated with a particular storage device and may contain more 
  9412. than one physical volume of backed-up data.  The following section tell you how 
  9413. to create and manipulate backup sets. 
  9414.  
  9415.      Working with backup sets 
  9416.  
  9417.  
  9418. ΓòÉΓòÉΓòÉ 8.1. Working with backup sets ΓòÉΓòÉΓòÉ
  9419.  
  9420. You can create a backup set with the C API by calling the function 
  9421. PsnsCreateBackupSet. You must specify a storage device with which to associate 
  9422. the backup set. The backup set is created with a default configuration, which 
  9423. should in most cases be sufficient. 
  9424.  
  9425. To delete a backup set, use PsnsDeleteBackupSet. 
  9426.  
  9427. Note:  When you delete a backup set, all backed-up data on it is lost! 
  9428.  
  9429. To empty the backup set of data without deleting the backup set itself, use 
  9430. PsnsEmptyBackupSet. 
  9431.  
  9432. To change the description of a backup set, or to inspect the description and 
  9433. find out which storage device it is associated with, use PsnsBackupSetInfo. 
  9434. This function takes as arguments a backup set name, a pointer to a 
  9435. BACKUPSETINFO structure and an integer mask.  Currently there are only two 
  9436. useful values for the mask: BS_DESCRIPTION to set the description of the backup 
  9437. set, or BS_NONE to inspect the current settings. 
  9438.  
  9439. Other backup set settings depend on the storage device which the backup set 
  9440. uses, and so are set and queried using a configuration string.  Use the 
  9441. functions PsnsGetBackupSetConfig and PsnsSetBackupSetConfig to get and set the 
  9442. configuration string for a backup set.  For more information, see Storage 
  9443. Device configuration. 
  9444.  
  9445. To list backup sets or search for backup sets which match certain criteria, use 
  9446. PsnsListBackupSets. This works in the same way as all the other API listing 
  9447. functions. 
  9448.  
  9449. Backup sets can be transferred out, which means that OS/2 Warp Server 
  9450. Backup/Restore writes all index data to the backup set media and then will not 
  9451. use the backup set for any more backups or restores until it is transferred in 
  9452. again.  This is useful, for example, for moving backup sets between machines. 
  9453. To transfer a backup set in or out, use PsnsTransferBackupSet. This function 
  9454. takes as arguments the name of the backup set and a flag specifying whether the 
  9455. backup set is to be transferred in or out. 
  9456.  
  9457. Each backup set has a log file which is a text file containing a log of 
  9458. activity performed on that backup set.  To find the name of the log file for a 
  9459. backup set, use the function PsnsGetLogFile.  You can then, for example, view, 
  9460. process or delete the log file. 
  9461.  
  9462. Dual device backup sets can be also be created with the PsnsCreateBackupSet 
  9463. function.  These allow you to perform an initial backup to one storage device, 
  9464. then further backups to an incremental device.  The storage device to which you 
  9465. perform the initial backup is known as the base device.  You may specify the 
  9466. virtual device only as the base storage device of a dual device backup set. 
  9467.  
  9468.  
  9469. ΓòÉΓòÉΓòÉ 9. Storage devices ΓòÉΓòÉΓòÉ
  9470.  
  9471. Storage devices are the physical systems OS/2 Warp Server Backup/Restore uses 
  9472. to store backed-up data, such as tape drives, hard disks or ADSM servers.  The 
  9473. following sections tell you how to create and manipulate storage devices. 
  9474.  
  9475.      Creating a storage device 
  9476.  
  9477.      Working with storage devices 
  9478.  
  9479.  
  9480. ΓòÉΓòÉΓòÉ 9.1. Creating a storage device ΓòÉΓòÉΓòÉ
  9481.  
  9482. When a new storage device is created, it must be one of a number of available 
  9483. types; these are the names which appear when you select 'New' from the pop-up 
  9484. menu in the Storage Devices container in the OS/2 Warp Server Backup/Restore 
  9485. user interface.  To accomplish this using the API, you can find out the 
  9486. available types of storage devices to create by calling PsnsListStorageDevices 
  9487. with the SD_CREATABLE bit set in the mask.  This will list all creatable 
  9488. storage devices  You can then call PsnsCreateStorageDevice which takes as an 
  9489. argument the name of the creatable storage device from which to create the new 
  9490. storage device.  You must also specify a configuration string when you create a 
  9491. storage device, since there are some configuration options which can only be 
  9492. specified when a device is created and cannot be changed afterwards; for more 
  9493. information see Storage Device configuration. 
  9494.  
  9495.  
  9496. ΓòÉΓòÉΓòÉ 9.2. Working with storage devices ΓòÉΓòÉΓòÉ
  9497.  
  9498. Storage device settings depend on the individual storage device, so they are 
  9499. set using a configuration string.  For more information on configuration 
  9500. strings, see Storage Device configuration.  Use the functions 
  9501. PsnsGetStorageDeviceConfig and PsnsSetStorageDeviceConfig to get and set the 
  9502. storage device configuration. 
  9503.  
  9504. To find out which Dynamic Link Library (DLL) file a storage device uses, call 
  9505. PsnsStorageDeviceInfo. This function takes as arguments the name of a storage 
  9506. device and a pointer to a STORAGEDEVICEINFO structure which is filled in with 
  9507. the name of the DLL. 
  9508.  
  9509. To list storage devices or search for storage devices which match certain 
  9510. criteria, use PsnsListStorageDevices. This works in the same way as all the 
  9511. other API listing functions. 
  9512.  
  9513. OS/2 Warp Server Backup/Restore usually scans for new storage devices 
  9514. automatically when it is started up.  To perform this task manually, use the 
  9515. function PsnsRefreshStorageDevices. 
  9516.  
  9517.  
  9518. ΓòÉΓòÉΓòÉ 10. Volumes ΓòÉΓòÉΓòÉ
  9519.  
  9520. Volumes are the individual tapes, diskettes or cartridges on which backed-up 
  9521. data is stored.  OS/2 Warp Server Backup/Restore keeps track of which files are 
  9522. stored on which volumes, and how much space is used up on each volume; this 
  9523. means that the user does not have to worry about remembering exactly where 
  9524. their data is.  The following section tells you how to create and manipulate 
  9525. volumes. 
  9526.  
  9527.      Working with volumes 
  9528.  
  9529.  
  9530. ΓòÉΓòÉΓòÉ 10.1. Working with volumes ΓòÉΓòÉΓòÉ
  9531.  
  9532. Volumes are referred to by their volume ID, which is an unsigned long integer. 
  9533.  
  9534. Creating a volume involves formatting and labelling the volume.  Before you can 
  9535. create a volume using the API, you should ensure that the correct tape or 
  9536. diskette is already in the drive.  When creating a volume under the graphical 
  9537. environment, the user is asked to insert the correct tape or diskette before 
  9538. formatting, but since this cannot be done when running under the API it is 
  9539. assumed that the correct media is already in the drive. To create a volume, 
  9540. call the function PsnsCreateVolume. 
  9541.  
  9542. Note:  Creating a volume will erase all data from the media currently in the 
  9543. drive. 
  9544.  
  9545. You should not have an existing volume in the drive when you call this 
  9546. function; always empty the backup set or delete the volume if you wish to 
  9547. re-use it. 
  9548.  
  9549. To delete a volume, use the function PsnsDeleteVolume.  This will make OS/2 
  9550. Warp Server Backup/Restore forget about all backed-up data on the volume.  You 
  9551. should not use this function as a regular part of your storage management, but 
  9552. only in circumstances such as when you have lost a tape and want to let OS/2 
  9553. Warp Server Backup/Restore know this. 
  9554.  
  9555. To get information about a volume, use PsnsVolumeInfo.  This takes as arguments 
  9556. a volume ID and a pointer to a VOLUMEINFO structure. Information about the 
  9557. volume and its space usage is returned in the structure. 
  9558.  
  9559. To list volumes and to list backup sets on a volume, use the functions 
  9560. PsnsListVolumes and PsnsListVolumeBackupSets. These work in the same way as the 
  9561. other API listing functions. 
  9562.  
  9563. It is possible to deactivate a volume; in this state, the volume will not be 
  9564. used for backups or restores.  You could do this if the volume is unavailable 
  9565. and you do not want OS/2 Warp Server Backup/Restore to request it when 
  9566. performing a backup.  To deactivate or activate a volume, use the function 
  9567. PsnsActivateVolume. 
  9568.  
  9569. When a volume is first created, it is not associated with any particular backup 
  9570. set and so will not be used for backup.  Before the volume can be used, you 
  9571. must associate it with a backup set; this can be done with the API by calling 
  9572. PsnsAssociateVolume. 
  9573.  
  9574.  
  9575. ΓòÉΓòÉΓòÉ 11. Events ΓòÉΓòÉΓòÉ
  9576.  
  9577. OS/2 Warp Server Backup/Restore allows you to schedule events which will run a 
  9578. backup method at a particular time.  The following section tells you how to 
  9579. create and manipulate scheduled events. 
  9580.  
  9581.      Working with events 
  9582.  
  9583.  
  9584. ΓòÉΓòÉΓòÉ 11.1. Working with events ΓòÉΓòÉΓòÉ
  9585.  
  9586. There are five different types of scheduled events in OS/2 Warp Server 
  9587. Backup/Restore: 
  9588.  
  9589.      Interval or regular events.  These events happen at regular intervals in 
  9590.       time, for example every hour or every ten minutes. 
  9591.  
  9592.      Daily events.  These happen at a certain time each day. 
  9593.  
  9594.      Monthly events.  These happen at a certain time on a certain day of each 
  9595.       month. 
  9596.  
  9597.      Named day(s) events.  These happen at a certain time on some days of each 
  9598.       month.  You can select individually on which days of the week and in 
  9599.       which weeks of the month the event will occur. 
  9600.  
  9601.      Startup events.  These occur a fixed time after starting up OS/2 Warp 
  9602.       Server Backup/Restore. 
  9603.  
  9604.  Events are referred to by an event ID, which is an unsigned short integer. 
  9605.  They do not have names. 
  9606.  
  9607.  To create an event, call PsnsCreateEvent.  You must specify the type of the 
  9608.  event and the name of a backup method.  The backup method can be changed later 
  9609.  but you must supply one when creating an event since there is no sensible 
  9610.  default option.  A new event ID will be created and returned. 
  9611.  
  9612.  To delete an event, use PsnsDeleteEvent. 
  9613.  
  9614.  To copy an event, use PsnsCopyEvent. A new event ID will be created and 
  9615.  returned. 
  9616.  
  9617.  The information about an event is contained in the EVENTINFO structure.  This 
  9618.  contains a union which has a member for each different type of event. 
  9619.  Remember that you should only use one member of a union at a time; the other 
  9620.  members will be meaningless.  To get or set the information about an event, 
  9621.  use PsnsEventInfo. This function takes as arguments an event ID, a pointer to 
  9622.  an EVENTINFO structure and an integer mask.  This mask controls which of the 
  9623.  event settings are changed:  to change all of the settings, use EV_ALL; to 
  9624.  change none of the settings but just inspect the current ones, use EV_NONE. To 
  9625.  change some combination of different settings, use the logical OR operator to 
  9626.  combine several mask values.  For more information, see PsnsEventInfo. 
  9627.  
  9628.  To list events and search for events which match certain criteria, use 
  9629.  PsnsListEvents. This works in the same way as the other API listing functions. 
  9630.  Note that if you want to search on any of the fields which are particular to 
  9631.  one type of event (such as, which day of the month), you must specify a type 
  9632.  of event to search for as well. 
  9633.  
  9634.  To find out which event is due to occur next, use PsnsGetNextEvent. 
  9635.  
  9636.  Events can be deactivated so that they will not occur; for example, you may 
  9637.  want to deactivate a regular backup during a holiday or during system 
  9638.  maintenance.  To activate or deactivate an event, use the function 
  9639.  PsnsActivateEvent. 
  9640.  
  9641.  
  9642. ΓòÉΓòÉΓòÉ 12. File filters ΓòÉΓòÉΓòÉ
  9643.  
  9644. File filters allow you to automatically select files to be backed up.  The 
  9645. following section tells you how to create and manipulate file filters. 
  9646.  
  9647.      Working with file filters 
  9648.  
  9649.      Working with file filter rules 
  9650.  
  9651.  
  9652. ΓòÉΓòÉΓòÉ 12.1. Working with file filters ΓòÉΓòÉΓòÉ
  9653.  
  9654. In the OS/2 Warp Server Backup/Restore graphical user interface, there are two 
  9655. types of file filters: tree-based and rule-based filters.  In fact all file 
  9656. filters are stored internally as rule-based filters, so this is how they are 
  9657. accessed using the API. 
  9658.  
  9659. To create a file filter, use the function PsnsCreateFileFilter.  You must 
  9660. specify a name for the file filter and the type of the filter.  The type you 
  9661. specify only changes how the file filter is edited under the graphical user 
  9662. interface; it does not alter how the file filter appears under the API.  The 
  9663. file filter is created with one rule in it; this is the 'last' rule which 
  9664. matches all files not matched by any other rules. 
  9665.  
  9666. To delete, rename and copy file filters, use the functions 
  9667. PsnsDeleteFileFilter, PsnsRenameFileFilter and PsnsCopyFileFilter. 
  9668.  
  9669. The settings for the file filter are contained in a FILEFILTERINFO structure. 
  9670. The only settings you can change are the type and the description of the file 
  9671. filter. To inspect or change the settings, use the function PsnsFileFilterInfo. 
  9672. This function takes as arguments a file filter name, a pointer to a 
  9673. FILEFILTERINFO structure and an integer mask.  This mask controls which of the 
  9674. file filter settings are changed:  to change all of the settings, use FF_ALL; 
  9675. to change none of the settings but just inspect the current ones, use FF_NONE. 
  9676. To change some combination of different settings, use the logical OR operator 
  9677. to combine several mask values.  For more information, see PsnsFileFilterInfo. 
  9678.  
  9679. To list file filters and search for file filters which match certain criteria, 
  9680. use PsnsListFileFilters. This works in the same way as the other API listing 
  9681. functions.  You can also ask to search for all file filters which would select 
  9682. a certain file. 
  9683.  
  9684.  
  9685. ΓòÉΓòÉΓòÉ 12.2. Working with file filter rules ΓòÉΓòÉΓòÉ
  9686.  
  9687. Information about a file filter rule is kept in a FILEFILTERRULE structure.  A 
  9688. file filter rule specifies which files it matches and whether they should be 
  9689. included or excluded from the backup.  When a file is tested to see whether it 
  9690. should be backed up or not, it is matched against all of the rules in turn, 
  9691. starting from the first one.  When a rule is found which matches the file, that 
  9692. rule is used to decide whether the file should be backed up or not. 
  9693.  
  9694. Every file filter contains one rule, which is always last, which matches all 
  9695. files not selected by any other rules.  You cannot delete this rule or change 
  9696. it except to change whether the files are to be included or excluded. 
  9697.  
  9698. To add a rule to a file filter, use PsnsAddFileFilterRule.  This takes as 
  9699. arguments the name of a file filter, a pointer to a FILEFILTERRULE structure, 
  9700. and an integer which specifies where in the file filter the rule is to be 
  9701. added; use 1 to add the rule at the top of the list of rules in the file 
  9702. filter, 2 to add it in second place and so on. 
  9703.  
  9704. To delete a rule from a file filter, use PsnsDeleteFileFilterRule.  You cannot 
  9705. delete the 'last' rule in a file filter. To inspect or change the settings for 
  9706. a file filter rule, use the function PsnsFileFilterRuleInfo. This function 
  9707. takes as arguments a file filter name, a pointer to a FILEFILTERRULE structure 
  9708. and an integer mask.  This mask controls which of the file filter settings are 
  9709. changed:  to change all of the settings, use FF_ALL; to change none of the 
  9710. settings but just inspect the current ones, use FF_NONE. To change some 
  9711. combination of different settings, use the logical OR operator to combine 
  9712. several mask values.  For more information, see PsnsFileFilterRuleInfo. 
  9713.  
  9714.  
  9715. ΓòÉΓòÉΓòÉ 13. Rulebooks ΓòÉΓòÉΓòÉ
  9716.  
  9717. Rulebooks allow you to use rules to decide how many generations of a file 
  9718. should be backed up and whether or not compression should be used.  The 
  9719. following section tells you how to create and manipulate rulebooks. 
  9720.  
  9721.      Working with rulebooks 
  9722.  
  9723.      Working with rulebook rules 
  9724.  
  9725.  
  9726. ΓòÉΓòÉΓòÉ 13.1. Working with rulebooks ΓòÉΓòÉΓòÉ
  9727.  
  9728. To create a rulebook, use the function PsnsCreateRulebook. The rulebook is 
  9729. automatically created with one rule in it which is always kept as the 'last' 
  9730. rule in the rulebook. It specifies how to back up files not matched by any of 
  9731. the preceding rules and cannot be deleted but its backup attributes can be 
  9732. modified. 
  9733.  
  9734. To delete, rename and copy rulebooks, use the functions PsnsDeleteRulebook, 
  9735. PsnsRenameRulebook and PsnsCopyRulebook. 
  9736.  
  9737. The settings for the rulebook are contained in a RULEBOOKINFO structure.  The 
  9738. only setting you can change is the description of the rulebook. To inspect or 
  9739. change the settings, use the function PsnsRulebookInfo. This function takes as 
  9740. arguments a rulebook name, a pointer to a RULEBOOKINFO structure and an integer 
  9741. mask. This mask controls which of the rulebook settings are changed:  to change 
  9742. the setting, use RB_ALL; to change none of the settings but just inspect the 
  9743. current ones, use RB_NONE. For more information, see PsnsRulebookInfo. 
  9744.  
  9745. To list rulebooks and search for rulebooks which match certain criteria, use 
  9746. PsnsListRulebooks. This works in the same way as the other API listing 
  9747. functions. 
  9748.  
  9749.  
  9750. ΓòÉΓòÉΓòÉ 13.2. Working with rulebook rules ΓòÉΓòÉΓòÉ
  9751.  
  9752. Information about a rulebook rule is kept in a RULEBOOKRULE structure.  A 
  9753. rulebook rule specifies which files it matches, how many generations to keep 
  9754. and whether or not compression should be performed on the files. When a file is 
  9755. to be backed, it is compared with all of the rules in turn, starting from the 
  9756. first one.  When a rule is found which matches the file, that rule is used to 
  9757. decide the number of generations and compression to use for that file. 
  9758.  
  9759. Every rulebook contains one rule, which is always last, which matches all files 
  9760. not selected by any other rules.  You cannot delete this rule or change it 
  9761. except to change the number of generations and compression. 
  9762.  
  9763. To add a rule to a rulebook, use PsnsAddRulebookRule. This takes as arguments 
  9764. the name of a rulebook, a pointer to a RULEBOOKRULE structure, and an integer 
  9765. which specifies where in the rulebook the rule is to be added; use 1 to add the 
  9766. rule at the top of the list of rules in the rulebook, 2 to add it in second 
  9767. place and so on. 
  9768.  
  9769. To delete a rule from a rulebook, use PsnsDeleteRulebookRule.  You cannot 
  9770. delete the 'last' rule in a rulebook. To inspect or change the settings for a 
  9771. rulebook rule, use the function PsnsRulebookRuleInfo. This function takes as 
  9772. arguments a rulebook name, a pointer to a RULEBOOKRULE structure and an integer 
  9773. mask.  This mask controls which of the rulebook settings are changed:  to 
  9774. change all of the settings, use RB_ALL; to change none of the settings but just 
  9775. inspect the current ones, use RB_NONE. To change some combination of different 
  9776. settings, use the logical OR operator to combine several mask values.  For more 
  9777. information, see PsnsRulebookRuleInfo. 
  9778.  
  9779.  
  9780. ΓòÉΓòÉΓòÉ 14. Source drives ΓòÉΓòÉΓòÉ
  9781.  
  9782. OS/2 Warp Server Backup/Restore keeps a list of all drives on your system to 
  9783. decide where it should look for files to back up.  The following section tells 
  9784. you how to manipulate source drives. 
  9785.  
  9786.      Working with source drives 
  9787.  
  9788.  
  9789. ΓòÉΓòÉΓòÉ 14.1. Working with source drives ΓòÉΓòÉΓòÉ
  9790.  
  9791. OS/2 Warp Server Backup/Restore keeps a list of all drives on your system. 
  9792. When you do a backup which specifies that files should be backed up from all 
  9793. drives, this list is used to decide which drives should be checked for files to 
  9794. back up.  For example, you might want to back up files from your local hard 
  9795. disks but not from your network drives. 
  9796.  
  9797. Information about source drives is contained in a SOURCEDRIVEINFO structure. To 
  9798. list all the source drives which OS/2 Warp Server Backup/Restore knows about, 
  9799. use PsnsListSourceDrives.  This works in the same way as the other API listing 
  9800. functions. 
  9801.  
  9802. To select or deselect a source drive for backup, use PsnsSelectSourceDrive. 
  9803.  
  9804. When you start up OS/2 Warp Server Backup/Restore, it scans to see which drives 
  9805. are attached to your system.  To do this again manually, use the function 
  9806. PsnsRefreshSourceDrives.  To change the type of a source drive if it has been 
  9807. incorrectly detected, use PsnsSourceDriveType. 
  9808.  
  9809.  
  9810. ΓòÉΓòÉΓòÉ 15. Files ΓòÉΓòÉΓòÉ
  9811.  
  9812. The following two sections tell you about dealing with individual files. 
  9813.  
  9814.      Working with backed-up data 
  9815.  
  9816.      Working with lists of individual files 
  9817.  
  9818.  
  9819. ΓòÉΓòÉΓòÉ 15.1. Working with backed-up data ΓòÉΓòÉΓòÉ
  9820.  
  9821. Data is stored in a backup set as a series of generations of files.  Each time 
  9822. you back up a file, a new generation is created, and an old generation might be 
  9823. dropped. 
  9824.  
  9825. To list generations which are backed up to a backup set, use PsnsListFiles. 
  9826. This function has two modes of operation:  you can list files which match 
  9827. certain criteria, in which case only one generation of each file will be 
  9828. listed, and it will be the one which best matches the criteria; or you can list 
  9829. all generations which match the criteria by setting the FILE_ALLGENERATIONS bit 
  9830. in the mask. For more information, see listing functions. 
  9831.  
  9832. While you are listing backed-up data, you cannot perform any other operations 
  9833. on the backup set; you must wait until the listing operation is finished. 
  9834.  
  9835. To remove files from the backup set, use PsnsDropFiles. 
  9836.  
  9837.  
  9838. ΓòÉΓòÉΓòÉ 15.2. Working with lists of individual files ΓòÉΓòÉΓòÉ
  9839.  
  9840. In addition to backing up and restoring files using backup methods and restore 
  9841. methods, it is also possible to back up or restore a specific list of files; 
  9842. this is useful for working with individual files on a one-off basis.  If, 
  9843. however, you plan to back up or restore the same files regularly, you should 
  9844. use a backup or restore method. 
  9845.  
  9846. To perform operations on a list of files, you must first tell OS/2 Warp Server 
  9847. Backup/Restore which files you want to work on.  To do this, call PsnsAddFile 
  9848. once for every file or group of files you want to add to the list.  This does 
  9849. not actually do anything to the files, it simply remembers them.  Afterwards, 
  9850. use PsnsBackupFiles, PsnsRestoreFiles or PsnsDropFiles to work with the files. 
  9851.  
  9852. To empty the list without performing any operations on the files, use 
  9853. PsnsPurgeFiles. 
  9854.  
  9855.  
  9856. ΓòÉΓòÉΓòÉ 16. Listing functions ΓòÉΓòÉΓòÉ
  9857.  
  9858. There are many functions in the OS/2 Warp Server Backup/Restore API for listing 
  9859. objects of various sorts. They all work in a similar way: 
  9860.  
  9861.      Each listing function has a handle which is of type HPSNSLIST.  This 
  9862.       handle is used to identify the listing operation between calls.  The 
  9863.       first time you call a listing function, you should set the handle to 0 
  9864.       and pass a pointer to it to the listing function.  On return from the 
  9865.       listing function, the handle will have been set to a new value (unless 
  9866.       there are no items to list). You should then keep passing a pointer to 
  9867.       the same handle on each subsequent call to the listing function, so that 
  9868.       the next object can be returned on each call.  When you have listed all 
  9869.       the objects, the handle will be set back to 0 to indicate that there are 
  9870.       no more objects to list. 
  9871.  
  9872.      The other arguments to the listing functions are a pointer to a 
  9873.       structure, and a mask. The first time you call the listing function, with 
  9874.       the handle set to 0, the structure should contain the criteria you want 
  9875.       to search on, and the mask should indicate which fields in the structure 
  9876.       you want to search on. On the first call to the listing function, the 
  9877.       search criteria from the structure and the mask are stored internally and 
  9878.       the structure is used to return the first object found.  On subsequent 
  9879.       calls, the contents of the structure are overwritten with the details of 
  9880.       the next object found. 
  9881.  
  9882.      When the last object is listed the listing operation is automatically 
  9883.       stopped, the handle freed and any resources deallocated.  However, if you 
  9884.       want to stop listing objects before you get to the last one, that is, 
  9885.       while the handle is still non-zero, you should use PsnsCloseList to free 
  9886.       the listing operation. 
  9887.  
  9888.  
  9889. ΓòÉΓòÉΓòÉ 17. Object names ΓòÉΓòÉΓòÉ
  9890.  
  9891. Object names in OS/2 Warp Server Backup/Restore can contain any printable text 
  9892. character, except that: 
  9893.  
  9894.      They may not begin with a space 
  9895.  
  9896.      They may not begin with a < (less than) sign 
  9897.  
  9898.      They must be at least one character long 
  9899.  
  9900.  
  9901. ΓòÉΓòÉΓòÉ 18. Wildcards ΓòÉΓòÉΓòÉ
  9902.  
  9903. Some fields, especially when searching for objects in OS/2 Warp Server 
  9904. Backup/Restore, may contain wildcards. When searching for object names and any 
  9905. other string apart from fully qualified filenames, the asterisk character (*) 
  9906. may be used to match any sequence of characters. 
  9907.  
  9908. In fully qualified filenames, wildcards may be used as follows: 
  9909.  
  9910.      The drive letter may be *, which means look for files on all drives. 
  9911.  
  9912.      The path may end with \*\, meaning look in all subdirectories of the 
  9913.       named directory. 
  9914.  
  9915.      The filename may contain one or more asterisks (*) which act as usual 
  9916.       wildcards. 
  9917.  
  9918.  
  9919. ΓòÉΓòÉΓòÉ 19. Storage device and backup set configuration ΓòÉΓòÉΓòÉ
  9920.  
  9921. The configuration of storage devices and backup sets is done by means of 
  9922. configuration strings, the contents of which are specific to the storage 
  9923. device. A configuration string consists of a series of keywords and values, 
  9924. separated by semicolons (;), for example: 
  9925.  
  9926. BEEP=YES;VERIFY=NO;
  9927.  
  9928. The caret (^) can be used as an escape character if either semicolons or equals 
  9929. signs are required in a value. A value may also be enclosed in either single or 
  9930. double quotation marks; the caret can be used as an escape character if a 
  9931. quotation mark is required within a quoted string. A value must be enclosed in 
  9932. quotation marks if leading or trailing space characters are required. In order 
  9933. to include a caret in a value, 2 consecutive caret characters should be used. 
  9934.  
  9935. Storage devices require a configuration string when they are created with 
  9936. PsnsCreateStorageDevice; once created, their configuration string can be 
  9937. obtained with PsnsGetStorageDeviceConfig. Some storage devices, for example the 
  9938. ADSM device,  can be reconfigured, using PsnsSetStorageDeviceConfig. 
  9939.  
  9940. It is possible to supply a configuration string when creating a backup set 
  9941. using PsnsCreateBackupSet, but this is optional. Once created, a backup set's 
  9942. configuration string can be obtained with PsnsGetBackupSetConfig; backup sets 
  9943. on some types of storage device may be reconfigured using 
  9944. PsnsSetBackupSetConfig. 
  9945.  
  9946. The following sections describe the format of configuration strings for the 
  9947. standard storage devices. 
  9948.  
  9949.  
  9950. ΓòÉΓòÉΓòÉ 19.1. SCSI tape storage devices ΓòÉΓòÉΓòÉ
  9951.  
  9952. These sections describe configuration strings for SCSI tape storage devices and 
  9953. backup sets. 
  9954.  
  9955.  
  9956. ΓòÉΓòÉΓòÉ 19.1.1. Storage device configuration ΓòÉΓòÉΓòÉ
  9957.  
  9958. The following keywords are supported: 
  9959.  
  9960.       ADAPTER 
  9961.  
  9962.       Meaning        The number of the SCSI adapter to which the tape drive is 
  9963.                      attached. 
  9964.       Valid values   A valid SCSI adapter number. 
  9965.  
  9966.       This keyword must be supplied when creating a storage device. 
  9967.  
  9968.       PUN 
  9969.  
  9970.       Meaning        The SCSI Physical Unit Number (PUN) of the tape drive. 
  9971.       Valid values   A valid PUN. 
  9972.  
  9973.       This keyword must be supplied when creating a storage device. 
  9974.  
  9975.  For example: 
  9976.  
  9977.   PsnsCreateStorageDevice( handle, "Tape", "ADAPTER=2;PUN=3;", newname);
  9978.  
  9979.  SCSI tape storage devices cannot be reconfigured. 
  9980.  
  9981.  
  9982. ΓòÉΓòÉΓòÉ 19.1.2. Backup set configuration ΓòÉΓòÉΓòÉ
  9983.  
  9984. The following keywords are supported: 
  9985.  
  9986.       CHECKDRIVE 
  9987.  
  9988.       Meaning        If you select this option then OS/2 Warp Server 
  9989.                      Backup/Restore will check the drive for a suitable volume 
  9990.                      before it prompts you to insert a tape. This option is 
  9991.                      useful when you are performing unattended backups. 
  9992.       Valid values   YES or NO 
  9993.  
  9994.       This keyword is optional when creating a backup set. If it is absent, the 
  9995.       user will always be prompted to insert a tape, even if the required 
  9996.       volume is already in the drive. 
  9997.  
  9998.       BEEP 
  9999.  
  10000.       Meaning        Whether OS/2 Warp Server Backup/Restore should make a 
  10001.                      noise when it asks for a tape volume to be inserted. 
  10002.       Valid values   YES or NO 
  10003.  
  10004.       This keyword is optional when creating a backup set. If it is absent, a 
  10005.       noise will not be made. 
  10006.  
  10007.  For example: 
  10008.  
  10009.   PsnsSetBackupSetConfig( handle, bksName, "CHECKDRIVE=YES;BEEP=NO;");
  10010.  
  10011.  SCSI tape backup sets can be reconfigured. 
  10012.  
  10013.  
  10014. ΓòÉΓòÉΓòÉ 19.2. Diskette and RW optical storage devices ΓòÉΓòÉΓòÉ
  10015.  
  10016. These sections describe configuration strings for diskette and RW optical 
  10017. storage devices and backup sets. 
  10018.  
  10019.  
  10020. ΓòÉΓòÉΓòÉ 19.2.1. Storage device configuration ΓòÉΓòÉΓòÉ
  10021.  
  10022. The following keywords are supported: 
  10023.  
  10024.       DRIVE 
  10025.  
  10026.       Meaning        The letter of the drive which the storage device is to use 
  10027.                      for backup 
  10028.       Valid values   A drive letter. 
  10029.  
  10030.       This keyword must be supplied when creating a storage device. 
  10031.  
  10032.       INDEXDRIVE (Optical only) 
  10033.  
  10034.       Meaning        The letter of the drive to which the storage device backs 
  10035.                      up index files. 
  10036.       Valid values   A diskette drive letter. 
  10037.  
  10038.       This keyword is optional when creating a storage device.  If it is 
  10039.       absent, drive A will be used. 
  10040.  
  10041.  For example: 
  10042.  
  10043.   PsnsCreateStorageDevice( handle, "RW Optical", "DRIVE=F;INDEXDRIVE=A", newname);
  10044.  
  10045.  Diskette and RW optical storage devices cannot be reconfigured. 
  10046.  
  10047.  
  10048. ΓòÉΓòÉΓòÉ 19.2.2. Backup set configuration ΓòÉΓòÉΓòÉ
  10049.  
  10050. The following keywords are supported: 
  10051.  
  10052.       BACKUPINDEX 
  10053.  
  10054.       Meaning        Whether OS/2 Warp Server Backup/Restore should 
  10055.                      automatically back up its index files using index 
  10056.                      diskettes. 
  10057.       Valid values   YES or NO 
  10058.  
  10059.       This keyword is optional when creating a backup set.  If it is absent, 
  10060.       index files will be backed up. 
  10061.  
  10062.       BEEP 
  10063.  
  10064.       Meaning        Whether OS/2 Warp Server Backup/Restore should make a 
  10065.                      noise when it asks for a diskette or RW optical disk to be 
  10066.                      inserted. 
  10067.       Valid values   YES or NO 
  10068.  
  10069.       This keyword is optional when creating a backup set.  If it is absent, a 
  10070.       noise will be made. 
  10071.  
  10072.       VERIFY 
  10073.  
  10074.       Meaning        Whether OS/2 Warp Server Backup/Restore should confirm 
  10075.                      that the data written to diskette or RW optical disk is 
  10076.                      correct. 
  10077.       Valid values   YES or NO 
  10078.  
  10079.       This keyword is optional when creating a backup set.  If it is absent, 
  10080.       backups will be verified. 
  10081.  
  10082.  For example: 
  10083.  
  10084.   PsnsSetBackupSetConfig( handle, bksName, "BEEP=NO;VERIFY=YES");
  10085.  
  10086.  Diskette and RW optical backup sets can be reconfigured. 
  10087.  
  10088.  
  10089. ΓòÉΓòÉΓòÉ 19.3. ADSM storage devices ΓòÉΓòÉΓòÉ
  10090.  
  10091. These sections describe configuration strings for ADSM storage devices and 
  10092. backup sets. 
  10093.  
  10094. Note:  ADSM storage devices cannot be created using PsnsCreateStorageDevice. 
  10095. Instead, one is automatically created on installation, and this can then be 
  10096. edited if necessary. 
  10097.  
  10098.  
  10099. ΓòÉΓòÉΓòÉ 19.3.1. Storage device configuration ΓòÉΓòÉΓòÉ
  10100.  
  10101. The following keywords are supported: 
  10102.  
  10103.       OPTIONSFILE 
  10104.  
  10105.       Meaning        The name of the ADSM options file to be used when 
  10106.                      connecting to the ADSM server, or the name of the file to 
  10107.                      be used to set the initial values for the ADSM options 
  10108.                      file when the NEWOPTIONSFILE keyword is also specified. 
  10109.                      The ADSM options file must exist and contain valid options 
  10110.                      before a connection with the ADSM server may be 
  10111.                      successfully established. The options file may be updated 
  10112.                      using special keywords in the configuration string. 
  10113.       Valid values   The name of an existing ADSM options file. 
  10114.  
  10115.       This keyword is optional.  If it is absent when creating the storage 
  10116.       device, a default file name will be used, if it is absent when updating 
  10117.       the storage device, the name of the options file will not be changed. 
  10118.  
  10119.       NEWOPTIONSFILE 
  10120.  
  10121.       Meaning        The name of the ADSM options file to be used when 
  10122.                      connecting to the ADSM server. The file will be created if 
  10123.                      it does not already exist; any existing file of the same 
  10124.                      name will be replaced. 
  10125.  
  10126.                      The initial option values for the new options file depend 
  10127.                      on the value of the OPTIONSFILE keyword: 
  10128.  
  10129.                      OPTIONSFILE=filename 
  10130.  
  10131.                                     The initial values will be taken from 
  10132.                                     filename. 
  10133.  
  10134.                      OPTIONSFILE= 
  10135.  
  10136.                                     There will be no initial values. 
  10137.  
  10138.                      OPTIONSFILE not specified 
  10139.  
  10140.                                     The initial values will be taken from the 
  10141.                                     options file specified in the existing ADSM 
  10142.                                     storage device settings. 
  10143.  
  10144.                      Values in the options file may be set or updated using 
  10145.                      special keywords in the configuration string. 
  10146.  
  10147.       Valid values   A valid file name. 
  10148.  
  10149.       This keyword is optional.  If it is absent, the name of the ADSM options 
  10150.       file to be used is determined by the value of the OPTIONSFILE keyword and 
  10151.       no new options file will be created. 
  10152.  
  10153.       NODENAME 
  10154.  
  10155.       Meaning        The node name to be used for connection to the ADSM 
  10156.                      server. 
  10157.       Valid values   A valid ADSM node name; this node name must be registered 
  10158.                      at the ADSM server before a connection may be successfully 
  10159.                      established. 
  10160.  
  10161.       This keyword is optional.  If it is absent when creating the storage 
  10162.       device, a default node name will be used, if it is absent when updating 
  10163.       the storage device, the node name will not be changed. 
  10164.  
  10165.       MGMTCLASS 
  10166.  
  10167.       Meaning        This is the ADSM management class to be used for backing 
  10168.                      up objects from OS/2 Warp Server Backup/Restore. This 
  10169.                      management class must be known at the ADSM server to which 
  10170.                      you will connect, and must be defined within the active 
  10171.                      policy set of the policy domain which is associated with 
  10172.                      your node. 
  10173.  
  10174.                      If you do not specify a management class, or if the 
  10175.                      management class is not defined within your active policy 
  10176.                      set, the default management class for your node will be 
  10177.                      used. 
  10178.  
  10179.                      If you set the management class to be mgmt_class, a 
  10180.                      statement of the form: 
  10181.  
  10182.                                           INCLUDE * mgmt_class
  10183.                      is inserted into your ADSM options file. 
  10184.  
  10185.       Valid values   A valid ADSM management class name. 
  10186.  
  10187.       This keyword is optional.  If it is absent when creating the storage 
  10188.       device, the default management class for your node will be used, if it is 
  10189.       absent when updating the storage device, the management class name will 
  10190.       not be changed. 
  10191.  
  10192.       MAXOBJECTS 
  10193.  
  10194.       Meaning        When OS/2 Warp Server Backup/Restore is backing up objects 
  10195.                      to an ADSM server, several objects may be sent to ADSM in 
  10196.                      a single batch; each batch is a single ADSM transaction. 
  10197.                      Each object (file or directory) that you back up using 
  10198.                      OS/2 Warp Server Backup/Restore may actually be stored in 
  10199.                      ADSM as several ADSM objects. For example, if a file has 
  10200.                      extended attributes, the file and its extended attributes 
  10201.                      may actually be stored as two separate ADSM objects. You 
  10202.                      can use this setting to limit the number of OS/2 Warp 
  10203.                      Server Backup/Restore objects that are included in a batch 
  10204.                      (the corresponding number of ADSM objects may be greater). 
  10205.  
  10206.                      Note:  ADSM also has a limit on the number of its objects 
  10207.                      that can be stored in a single transaction. The number of 
  10208.                      OS/2 Warp Server Backup/Restore objects actually sent in a 
  10209.                      batch will be less than the number specified by MAXOBJECTS 
  10210.                      if the corresponding number of ADSM objects to be stored 
  10211.                      exceeds the limit set by ADSM. 
  10212.  
  10213.       Valid values   A non-zero numeric value. 
  10214.  
  10215.       This keyword is optional.  If it is absent when creating the storage 
  10216.       device, a default value will be used, if it is absent when updating the 
  10217.       storage device, the setting will not be changed. 
  10218.  
  10219.       PASSWORDLIFE 
  10220.  
  10221.       Meaning        If a password is required to access the services of ADSM, 
  10222.                      OS/2 Warp Server Backup/Restore will prompt you to enter 
  10223.                      your password the first time you attempt to use the 
  10224.                      services of ADSM in each use of OS/2 Warp Server 
  10225.                      Backup/Restore. If you use the services of ADSM more than 
  10226.                      once in a single use of OS/2 Warp Server Backup/Restore, 
  10227.                      OS/2 Warp Server Backup/Restore will not ask you to enter 
  10228.                      your password again until the number of minutes specified 
  10229.                      by PASSWORDLIFE has passed. 
  10230.  
  10231.       Valid values   A non-zero numeric value. 
  10232.  
  10233.       This keyword is optional.  If it is absent when creating the storage 
  10234.       device, a default value will be used, if it is absent when updating the 
  10235.       storage device, the setting will not be changed. 
  10236.  
  10237.       PASSWORDPROMPT 
  10238.  
  10239.       Meaning        Whether OS/2 Warp Server Backup/Restore should prompt for 
  10240.                      entry of the ADSM password when connecting to the ADSM 
  10241.                      server during unattended operation. 
  10242.  
  10243.                      Note:  If entry of the ADSM password is required during 
  10244.                      unattended operation and password prompting has been 
  10245.                      suppressed (PASSWORDPROMPT=NO), the operation will fail. 
  10246.                      The requirement for entry of the ADSM password can be 
  10247.                      avoided by using the option 'PASSWORDACCESS GENERATE' in 
  10248.                      the ADSM options file, or by setting the ADSM password by 
  10249.                      use of the PASSWORD keyword in the ADSM storage device 
  10250.                      configuration string. 
  10251.  
  10252.       Valid values   YES or NO 
  10253.  
  10254.       This keyword is optional.  If it is absent when creating the storage 
  10255.       device, prompting for the ADSM password during unattended operation will 
  10256.       not be suppressed, if it is absent when updating the storage device, the 
  10257.       setting will not be changed. 
  10258.  
  10259.       PASSWORD 
  10260.  
  10261.       Meaning        This keyword may be used to set the ADSM password for the 
  10262.                      current execution of the API server; the value will not be 
  10263.                      retained for future invocations of the server. 
  10264.       Valid value    The correct password for the ADSM node name associated 
  10265.                      with the ADSM storage device. 
  10266.  
  10267.       This keyword is optional.  If it is absent, no password will be set. 
  10268.  
  10269.       NEWPASSWORD 
  10270.  
  10271.       Meaning        This keyword may be used to change the ADSM password. 
  10272.  
  10273.                      Note:  The current password must also be specified by the 
  10274.                      PASSWORD keyword, unless the option 'PASSWORDACCESS 
  10275.                      GENERATE' is included in the ADSM options file and the 
  10276.                      current password is stored locally by ADSM (in encrypted 
  10277.                      form). 
  10278.  
  10279.       Valid value    A valid ADSM password. 
  10280.  
  10281.       This keyword is optional.  If it is absent, the password will not be 
  10282.       changed. 
  10283.  
  10284.       CONNECT 
  10285.  
  10286.       Meaning        Whether OS/2 Warp Server Backup/Restore should test the 
  10287.                      connection to the ADSM server. 
  10288.       Valid values   YES or NO 
  10289.  
  10290.       This keyword is optional.  If it is absent, the connection to the ADSM 
  10291.       server will not be tested. 
  10292.  
  10293.  For example: 
  10294.  
  10295.   PsnsSetStorageDeviceConfig ( handle, "ADSM",
  10296.                              "OPTIONSFILE=C:\\ADSM\\DSM.OPT;NODENAME=PSNSclient",
  10297.                              newname);
  10298.  
  10299.  
  10300. ΓòÉΓòÉΓòÉ 19.3.2. Updating the ADSM options file ΓòÉΓòÉΓòÉ
  10301.  
  10302. The ADSM storage device configuration string can contain special keywords (In 
  10303. addition to the standard OS/2 Warp Server Backup/Restore configuration string 
  10304. syntax) in order to add, change or delete options in the ADSM options file. 
  10305.  
  10306. ADSM options may be added or changed by including specifications of the form: 
  10307.  
  10308. +option value
  10309. where: 
  10310.  
  10311.  option    is the name of an ADSM option to be added to, or changed in the ADSM 
  10312.            options file. 
  10313.  value     is the value to be set for the ADSM option. 
  10314.  
  10315.   or: 
  10316.  
  10317.   -option
  10318.  where: 
  10319.  
  10320.  option    is the name of an ADSM option to be deleted from the ADSM options 
  10321.            file. 
  10322.  
  10323.  Note:  No validation of the ADSM option name or value is performed. 
  10324.  
  10325.  For example: 
  10326.  
  10327.   PsnsSetStorageDeviceConfig ( handle, "ADSM",
  10328.                              "OPTIONSFILE=C:\\ADSM\\DSM.OPT;" \
  10329.                              "NEWOPTIONSFILE=C:\\ADSM\\PSNS.OPT;" \
  10330.                              "-verbose; +quiet;" \
  10331.                              "+PASSWORDACCESS GENERATE;-PASSWORDDIR;" \
  10332.                              "+COMMMETHOD TCPIP;" \
  10333.                              "+TCPPort 1500;" \
  10334.                              "+TCPServeraddress n.n.n.n;" \
  10335.                              "+TCPBuffsize 8;" \
  10336.                              "+TCPWindowsize 16",
  10337.                              newname);
  10338.  
  10339.  
  10340. ΓòÉΓòÉΓòÉ 19.3.3. Backup set configuration ΓòÉΓòÉΓòÉ
  10341.  
  10342. ADSM backup sets have no configurable settings. 
  10343.  
  10344.  
  10345. ΓòÉΓòÉΓòÉ 19.4. Hard disk and remote disk storage devices ΓòÉΓòÉΓòÉ
  10346.  
  10347. These sections describe configuration strings for hard disk and remote disk 
  10348. storage devices and backup sets. 
  10349.  
  10350.  
  10351. ΓòÉΓòÉΓòÉ 19.4.1. Storage device configuration ΓòÉΓòÉΓòÉ
  10352.  
  10353.       DRIVE 
  10354.  
  10355.       Meaning        The letter of the drive which the storage device is to use 
  10356.                      for backup. 
  10357.       Valid values   A drive letter. 
  10358.  
  10359.       This keyword must be supplied when creating a storage device. 
  10360.  
  10361.       PATH 
  10362.  
  10363.       Meaning        The name of the directory in which the storage device will 
  10364.                      store backed up data. 
  10365.       Valid values   A valid directory name. 
  10366.  
  10367.       This keyword is optional when creating a storage device.  If it is 
  10368.       absent, the directory PSNS5BKP will be used. 
  10369.  
  10370.  For example: 
  10371.  
  10372.   PsnsCreateStorageDevice( handle, "Hard Disk", "DRIVE=D;PATH=BACKUP", newname);
  10373.  
  10374.  Hard and remote disk storage devices cannot be reconfigured. 
  10375.  
  10376.  
  10377. ΓòÉΓòÉΓòÉ 19.4.2. Backup set configuration ΓòÉΓòÉΓòÉ
  10378.  
  10379. The following keyword is supported: 
  10380.  
  10381.       PATH 
  10382.  
  10383.       Meaning        The subdirectory of the storage device's directory in 
  10384.                      which the backup set will store data. 
  10385.       Valid values   A valid directory name. 
  10386.  
  10387.       This keyword is optional when creating a backup set.  If it is absent, a 
  10388.       name will be generated from the name of the backup set. 
  10389.  
  10390.  For example: 
  10391.  
  10392.   PsnsCreateBackupSet( handle, bksName, devName, "PATH=LLAMA");
  10393.  
  10394.  Hard and remote disk backup sets cannot be reconfigured. 
  10395.  
  10396.  
  10397. ΓòÉΓòÉΓòÉ 19.5. LAN alias storage devices ΓòÉΓòÉΓòÉ
  10398.  
  10399. These sections describe configuration strings for LAN alias storage devices and 
  10400. backup sets. 
  10401.  
  10402.  
  10403. ΓòÉΓòÉΓòÉ 19.5.1. Storage device configuration ΓòÉΓòÉΓòÉ
  10404.  
  10405. The following keywords are supported: 
  10406.  
  10407.       SERVER 
  10408.  
  10409.       Meaning        The name of the LAN server on which the device is to store 
  10410.                      data. 
  10411.       Valid values   The name of a LAN server 
  10412.  
  10413.       This keyword must be supplied when creating a storage device. 
  10414.  
  10415.       ALIAS 
  10416.  
  10417.       Meaning        The name of the alias on the server in which the device is 
  10418.                      to store data. 
  10419.       Valid values   A LAN server alias. 
  10420.  
  10421.       This keyword must be supplied when creating a storage device. 
  10422.  
  10423.       PATH 
  10424.  
  10425.       Meaning        The name of the directory in which the storage device will 
  10426.                      store backed up data. 
  10427.       Valid values   A valid directory name. 
  10428.  
  10429.       This keyword is optional when creating a storage device.  If it is 
  10430.       absent, the directory PSNS5BKP will be used. 
  10431.  
  10432.  For example: 
  10433.  
  10434.   PsnsCreateStorageDevice( handle, "Lan Drive", "SERVER=WDGSRV;ALIAS=PSNS", newname);
  10435.  
  10436.  LAN alias storage devices cannot be reconfigured. 
  10437.  
  10438.  
  10439. ΓòÉΓòÉΓòÉ 19.5.2. Backup set configuration ΓòÉΓòÉΓòÉ
  10440.  
  10441. The following keyword is supported: 
  10442.  
  10443.       PATH 
  10444.  
  10445.       Meaning        The subdirectory of the storage device's directory in 
  10446.                      which the backup set will store data. 
  10447.       Valid values   A valid directory name. 
  10448.  
  10449.       This keyword is optional when creating a backup set.  If it is absent, a 
  10450.       name will be generated from the name of the backup set. 
  10451.  
  10452.  For example: 
  10453.  
  10454.   PsnsCreateBackupSet( handle, bksName, devName, "PATH=LLAMA");
  10455.  
  10456.  LAN alias backup sets cannot be reconfigured. 
  10457.  
  10458.  
  10459. ΓòÉΓòÉΓòÉ 19.6. Removable drive storage device ΓòÉΓòÉΓòÉ
  10460.  
  10461. These sections describe configuration strings for the removable drive storage 
  10462. device and backup sets. 
  10463.  
  10464.  
  10465. ΓòÉΓòÉΓòÉ 19.6.1. Storage device configuration ΓòÉΓòÉΓòÉ
  10466.  
  10467.       DRIVE 
  10468.  
  10469.       Meaning        The letter of the drive which the storage device is to use 
  10470.                      for backup. 
  10471.       Valid values   A drive letter. 
  10472.  
  10473.       This keyword must be supplied when creating a storage device. 
  10474.  
  10475.       PATH 
  10476.  
  10477.       Meaning        The name of the directory in which the storage device will 
  10478.                      store backed up data. 
  10479.       Valid values   A valid directory name. 
  10480.  
  10481.       This keyword is optional when creating a storage device.  If it is 
  10482.       absent, the directory PSNS6BKP will be used. 
  10483.  
  10484.  For example: 
  10485.  
  10486.   PsnsCreateStorageDevice( handle, "Removable Drive", "DRIVE=D;PATH=BACKUP", newname);
  10487.  
  10488.  Removable Drive storage devices cannot be reconfigured. 
  10489.  
  10490.  
  10491. ΓòÉΓòÉΓòÉ 19.6.2. Backup set configuration ΓòÉΓòÉΓòÉ
  10492.  
  10493. The following keywords are supported: 
  10494.  
  10495.       BACKUPINDEX 
  10496.  
  10497.       Meaning        If you select this option, OS/2 Warp Server Backup/Restore 
  10498.                      will automatically back up its Index Files for the Backup 
  10499.                      Set every time you perform a backup. 
  10500.  
  10501.                      Warning: If the Back up index files option is not selected 
  10502.                      then no back ups are made of the Index Files. This is 
  10503.                      strongly discouraged, as it means your data will be 
  10504.                      impossible to retrieve if the Index Files on Hard Disk are 
  10505.                      lost. 
  10506.       Valid values   YES or NO 
  10507.  
  10508.       This keyword is optional when creating a backup set.  If it is absent, 
  10509.       index files will be backed up. 
  10510.  
  10511.       BEEP 
  10512.  
  10513.       Meaning        Whether OS/2 Warp Server Backup/Restore should make a 
  10514.                      noise when it asks for a removable drive to be inserted. 
  10515.       Valid values   YES or NO 
  10516.  
  10517.       This keyword is optional when creating a backup set.  If it is absent, a 
  10518.       noise will be made. 
  10519.  
  10520.       VERIFY 
  10521.  
  10522.       Meaning        Whether OS/2 Warp Server Backup/Restore should confirm 
  10523.                      that the data written to the removable drive is correct. 
  10524.       Valid values   YES or NO 
  10525.  
  10526.       This keyword is optional when creating a backup set.  If it is absent, 
  10527.       backups will not be verified. 
  10528.  
  10529.  For example: 
  10530.  
  10531.   PsnsSetBackupSetConfig( handle, bksName, "BEEP=NO;VERIFY=YES");
  10532.  
  10533.  Removable drive backup sets can be reconfigured. 
  10534.  
  10535.  
  10536. ΓòÉΓòÉΓòÉ 19.7. Virtual storage device ΓòÉΓòÉΓòÉ
  10537.  
  10538. There are no configuration strings for the virtual storage device or backup 
  10539. sets.