diff options
author | Andrew Bartlett <abartlet@samba.org> | 2008-05-28 08:11:05 +1000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2008-05-28 08:11:05 +1000 |
commit | 51ae2302a68033b1b79a4ebc8d4cbab64adcf843 (patch) | |
tree | d8b1af54efe4ec70607ef2bcbd873c2cd667d894 /source4/param/param.py | |
parent | 5d0d239d1ab826c91839a603f93d2c0061658888 (diff) | |
parent | 52b230141b5ad9f317f97e7d257703614bab3985 (diff) | |
download | samba-51ae2302a68033b1b79a4ebc8d4cbab64adcf843.tar.gz samba-51ae2302a68033b1b79a4ebc8d4cbab64adcf843.tar.xz samba-51ae2302a68033b1b79a4ebc8d4cbab64adcf843.zip |
Merge branch 'v4-0-test' of ssh://git.samba.org/data/git/samba into 4-0-abartlet
It seems the format of main.mk changed in my sleep...
Conflicts:
source/main.mk
(This used to be commit 56f2288e4f4f1aa70d11fc5f118458baf5803627)
Diffstat (limited to 'source4/param/param.py')
-rw-r--r-- | source4/param/param.py | 74 |
1 files changed, 74 insertions, 0 deletions
diff --git a/source4/param/param.py b/source4/param/param.py index 0419c75bfa..46c75cef97 100644 --- a/source4/param/param.py +++ b/source4/param/param.py @@ -3,6 +3,10 @@ # # Don't modify this file, modify the SWIG interface instead. +""" +Parsing and writing Samba configuration files. +""" + import _param import new new_instancemethod = new.instancemethod @@ -62,6 +66,48 @@ class LoadParm(object): __repr__ = _swig_repr def __init__(self, *args, **kwargs): _param.LoadParm_swiginit(self,_param.new_LoadParm(*args, **kwargs)) + def load(*args, **kwargs): + """ + S.load(filename) -> None + Load specified file. + """ + return _param.LoadParm_load(*args, **kwargs) + + def load_default(*args, **kwargs): + """ + S.load_default() -> None + Load default smb.conf file. + """ + return _param.LoadParm_load_default(*args, **kwargs) + + def configfile(*args, **kwargs): + """ + S.configfile() -> string + Return name of last config file that was loaded. + """ + return _param.LoadParm_configfile(*args, **kwargs) + + def is_mydomain(*args, **kwargs): + """ + S.is_mydomain(domain_name) -> bool + Check whether the specified name matches our domain name. + """ + return _param.LoadParm_is_mydomain(*args, **kwargs) + + def is_myname(*args, **kwargs): + """ + S.is_myname(netbios_name) -> bool + Check whether the specified name matches one of our netbios names. + """ + return _param.LoadParm_is_myname(*args, **kwargs) + + def set(*args, **kwargs): + """ + S.set(name, value) -> bool + Change a parameter. + """ + return _param.LoadParm_set(*args, **kwargs) + __swig_destroy__ = _param.delete_LoadParm LoadParm.default_service = new_instancemethod(_param.LoadParm_default_service,None,LoadParm) LoadParm.load = new_instancemethod(_param.LoadParm_load,None,LoadParm) @@ -92,6 +138,34 @@ class ParamFile(object): __repr__ = _swig_repr def __init__(self, *args, **kwargs): _param.ParamFile_swiginit(self,_param.new_ParamFile(*args, **kwargs)) + def add_section(*args, **kwargs): + """ + S.add_section(name) -> section + Add a new section. + """ + return _param.ParamFile_add_section(*args, **kwargs) + + def first_section(*args, **kwargs): + """ + S.first_section() -> section + Find first section + """ + return _param.ParamFile_first_section(*args, **kwargs) + + def next_section(*args, **kwargs): + """ + S.next_section(prev) -> section + Find next section + """ + return _param.ParamFile_next_section(*args, **kwargs) + + def read(*args, **kwargs): + """ + S.read(filename) -> bool + Read a filename. + """ + return _param.ParamFile_read(*args, **kwargs) + def __getitem__(self, name): ret = self.get_section(name) if ret is None: |