#!/usr/bin/env python
# -*- coding: utf-8 -*-
#
# auto_types.py
#
# This file is autogenerated from the bacula sources.
# 
#from auto_types import *
# $Id: auto_types.py 12290 2011-02-10 14:02:38Z pstorz $
from command import *

    
msg_types = [ 'info',  'all',  'skipped',  'notsaved',  'saved',  'mount',  'terminate',  'alert',  'abort',  'error',  'debug',  'security',  'fatal',  'warning',  'restored',  'volmgmt',  ]
jobtypes = [ 'restore',  'admin',  'verify',  'migrate',  'copy',  'backup',  ]
joblevels = [ 'Volume To Catalog',  'Full',  'Incremental',  'Since',  'Disk To Catalog',  'Init Catalog',  'Catalog',  'Base',  'Differential',  'Virtual Full',  'Data',  ]
#joblevels = [ 'volumetocatalog',  'full',  'incremental',  'since',  'disktocatalog',  'initcatalog',  'catalog',  'base',  'differential',  'virtualfull',  'data',  ]
migtypes = [ 'sqlquery',  'pooltime',  'oldestvolume',  'smallestvolume',  'volume',  'job',  'client',  'pooluncopiedjobs',  'pooloccupancy',  ]
ReplaceOptions = [ 'always',  'ifolder',  'ifnewer',  'never',  ]
FS_option_kw = { 'basejob' : ['Yes', 'No'] ,
'portable' : ['Yes', 'No'] ,
'accurate' : ['Yes', 'No'] ,
'replace' : ['Always', 'If Newer', 'never'] ,
'ignorecase' : ['Yes', 'No'] ,
'honornodumpflag' : ['Yes', 'No'] ,
'exclude' : ['Yes', 'No'] ,
'enhancedwild' : ['Yes', 'No'] ,
'compression' : ['gzip', 'gzip1', 'gzip2', 'gzip3', 'gzip4', 'gzip5', 'gzip6', 'gzip7', 'gzip8', 'gzip9'] ,
'strippath' : ['Yes', 'No'] ,
'encryption' : ['Blowfish', '3DES'] ,
'hardlinks' : ['Yes', 'No'] ,
'onefs' : ['Yes', 'No'] ,
'xattrsupport' : ['Yes', 'No'] ,
'hfsplussupport' : ['Yes', 'No'] ,
'aclsupport' : ['Yes', 'No'] ,
'checkfilechanges' : ['Yes', 'No'] ,
'keepatime' : ['Yes', 'No'] ,
'verify' : ['Yes', 'No'] ,
'readfifo' : ['Yes', 'No'] ,
'recurse' : ['Yes', 'No'] ,
'sparse' : ['Yes', 'No'] ,
'signature' : ['md5', 'sha1', 'sha256', 'sha512'] ,
'mtimeonly' : ['Yes', 'No'] ,
'noatime' : ['Yes', 'No'] ,
}

commands = {'.actiononpurge': command('.actiononpurge','aopcmd','','NULL','true'),
 '.api': command('.api','api_cmd','','NULL','false'),
 '.backups': command('.backups','backupscmd','','NULL','false'),
 '.bvfs_lsdirs': command('.bvfs_lsdirs','dot_bvfs_lsdirs','','NULL','true'),
 '.bvfs_lsfiles': command('.bvfs_lsfiles','dot_bvfs_lsfiles','','NULL','true'),
 '.bvfs_update': command('.bvfs_update','dot_bvfs_update','','NULL','true'),
 '.clients': command('.clients','clientscmd','','NULL','true'),
 '.defaults': command('.defaults','defaultscmd','','NULL','false'),
 '.die': command('.die','admin_cmds','','NULL','false'),
 '.dump': command('.dump','admin_cmds','','NULL','false'),
 '.exit': command('.exit','admin_cmds','','NULL','false'),
 '.filesets': command('.filesets','filesetscmd','','NULL','false'),
 '.help': command('.help','dot_help_cmd','','NULL','false'),
 '.jobs': command('.jobs','jobscmd','','NULL','true'),
 '.levels': command('.levels','levelscmd','','NULL','false'),
 '.locations': command('.locations','locationscmd','','NULL','true'),
 '.media': command('.media','mediacmd','','NULL','true'),
 '.mediatypes': command('.mediatypes','mediatypescmd','','NULL','true'),
 '.messages': command('.messages','getmsgscmd','','NULL','false'),
 '.msgs': command('.msgs','msgscmd','','NULL','false'),
 '.pools': command('.pools','poolscmd','','NULL','true'),
 '.quit': command('.quit','dot_quit_cmd','','NULL','false'),
 '.sql': command('.sql','sql_cmd','','NULL','false'),
 '.status': command('.status','dot_status_cmd','','NULL','false'),
 '.storage': command('.storage','storagecmd','','NULL','true'),
 '.types': command('.types','typescmd','','NULL','false'),
 '.volstatus': command('.volstatus','volstatuscmd','','NULL','true'),
 'add': command('add','add_cmd','Add media to a pool','pool=<pool-name> storage=<storage> jobid=<JobId>','false'),
 'autodisplay': command('autodisplay','autodisplay_cmd','Autodisplay console messages','on | off','false'),
 'automount': command('automount','automount_cmd','Automount after label','on | off','false'),
 'cancel': command('cancel','cancel_cmd','Cancel a job','jobid=<number> job=<job-name> ujobid=<unique-jobid>','false'),
 'create': command('create','create_cmd','Create DB Pool from resource','pool=<pool-name>','false'),
 'delete': command('delete','delete_cmd','Delete volume, pool or job','volume=<vol-name> pool=<pool-name> jobid=<id>','true'),
 'disable': command('disable','disable_cmd','Disable a job','job=<name>','true'),
 'enable': command('enable','enable_cmd','Enable a job','job=<name>','true'),
 'estimate': command('estimate','estimate_cmd','Performs FileSet estimate, listing gives full listing','fileset=<fs> client=<cli> accurate=<yes/no> job=<job> listing','true'),
 'exit': command('exit','quit_cmd','Terminate Bconsole session','','false'),
 'gui': command('gui','gui_cmd','Non-interactive gui mode','on | off','false'),
 'help': command('help','help_cmd','Print help on specific command','add autodisplay automount cancel create delete disable\n\tenable estimate exit gui label list llist       \n\tmessages memory mount prune purge python quit query\n\trestore relabel release reload run status       \n\tsetdebug setip show sqlquery time trace unmount umount\n\tupdate use var version wait','false'),
 'label': command('label','label_cmd','Label a tape','storage=<storage> volume=<vol> pool=<pool>','false'),
 'list': command('list','list_cmd','List objects from catalog','pools | jobs | jobtotals | volume | media <pool=pool-name> | files jobid=<nn> | copies jobid=<nn>','true'),
 'llist': command('llist','llist_cmd','Full or long list like list command','pools | jobs | jobtotals | media <pool=pool-name> | files jobid=<nn> | copies jobid=<nn>','true'),
 'memory': command('memory','memory_cmd','Print current memory usage','','true'),
 'messages': command('messages','messagescmd','Display pending messages','','false'),
 'mount': command('mount','mount_cmd','Mount storage','storage=<storage-name> slot=<num> drive=<num> [ jobid=<id> | job=<job-name> ]','false'),
 'prune': command('prune','prunecmd','Prune expired records from catalog','files | jobs | pool=<pool> | client=<client-name> | volume=<volume-name> ','true'),
 'purge': command('purge','purgecmd','Purge records from catalog','files jobs volume=<vol> [action=<action> devicetype=<type> pool=<pool> allpools storage=<st> drive=<num>]','true'),
 'python': command('python','python_cmd','Python control commands','','false'),
 'query': command('query','querycmd','Query catalog','','false'),
 'quit': command('quit','quit_cmd','Terminate Bconsole session','','false'),
 'relabel': command('relabel','relabel_cmd','Relabel a tape','storage=<storage-name> oldvolume=<old-volume-name>\n\tvolume=<newvolume-name> pool=<pool>','false'),
 'release': command('release','release_cmd','Release storage','storage-name','false'),
 'reload': command('reload','reload_cmd','Reload conf file','','true'),
 'restore': command('restore','restore_cmd','Restore files','where=</path> client=<client> storage=<storage> bootstrap=<file>       \n\tcomment=<text> jobid=<jobid> done select all','false'),
 'run': command('run','run_cmd','Run a job','job=<job-name> client=<client-name>\n\tfileset=<FileSet-name> level=<level-keyword>\n\tstorage=<storage-name>       where=<directory-prefix>\n\twhen=<universal-time-specification>\n\tcomment=<text> yes','false'),
 'setdebug': command('setdebug','setdebug_cmd','Sets debug level','level=<nn> trace=0/1 client=<client-name> | dir | storage=<storage-name> | all','true'),
 'setip': command('setip','setip_cmd','Sets new client address -- if authorized','','false'),
 'show': command('show','show_cmd','Show resource records','job=<xxx> |  pool=<yyy> | fileset=<aaa> schedule=<sss> | client=<zzz> | disabled | all','true'),
 'sqlquery': command('sqlquery','sqlquerycmd','Use SQL to query catalog','','false'),
 'status': command('status','status_cmd','Report status','all | dir=<dir-name> | director | client=<client-name> | storage=<storage-name> slots | days=nnn','true'),
 'time': command('time','time_cmd','Print current time','','true'),
 'trace': command('trace','trace_cmd','Turn on/off trace to file','on | off','true'),
 'umount': command('umount','unmount_cmd','Umount - for old-time Unix guys, see unmount','storage=<storage-name> [ drive=<num> ] | jobid=<id> | job=<job-name>','false'),
 'unmount': command('unmount','unmount_cmd','Unmount storage','storage=<storage-name> [ drive=<num> ] | jobid=<id> | job=<job-name>','false'),
 'update': command('update','update_cmd','Update volume, pool or stats','stats\n\tpool=<poolname>\n\tslots storage=<storage> scan       \n\tvolume=<volname> volstatus=<status> volretention=<time-def>       \n\t pool=<pool> recycle=<yes/no> slot=<number>\n\t inchanger=<yes/no>       \n\t maxvolbytes=<size> maxvolfiles=<nb> maxvoljobs=<nb>       \n\t enable=<yes/no> recyclepool=<pool> actiononpurge=<action>','true'),
 'use': command('use','use_cmd','Use catalog xxx','','false'),
 'var': command('var','var_cmd','Does variable expansion','','false'),
 'version': command('version','version_cmd','Print Director version','','true'),
 'wait': command('wait','wait_cmd','Wait until no jobs are running','jobname=<name> | jobid=<nnn> | ujobid=<complete_name>','false')}

