1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-10 01:18:15 +03:00

gpo: Remove unused gp_ext_setter code

Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>

Autobuild-User(master): David Mulder <dmulder@samba.org>
Autobuild-Date(master): Thu Aug  6 18:01:49 UTC 2020 on sn-devel-184
This commit is contained in:
David Mulder 2020-07-08 14:50:27 -06:00 committed by David Mulder
parent 627fb5471b
commit d512b1a4bd
2 changed files with 1 additions and 32 deletions

View File

@ -16,7 +16,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
import os.path
from samba.gpclass import gp_ext_setter, gp_inf_ext
from samba.gpclass import gp_inf_ext
from samba.auth import system_session
from samba.compat import get_string
try:

View File

@ -322,37 +322,6 @@ class gp_ext(object):
return {}
class gp_ext_setter(object):
__metaclass__ = ABCMeta
def __init__(self, logger, gp_db, lp, creds, attribute, val):
self.logger = logger
self.attribute = attribute
self.val = val
self.lp = lp
self.creds = creds
self.gp_db = gp_db
def explicit(self):
return self.val
def update_samba(self):
(upd_sam, value) = self.mapper().get(self.attribute)
upd_sam(value())
@abstractmethod
def mapper(self):
pass
def delete(self):
upd_sam, _ = self.mapper().get(self.attribute)
upd_sam(self.val)
@abstractmethod
def __str__(self):
pass
class gp_inf_ext(gp_ext):
def read(self, data_file):
policy = open(data_file, 'rb').read()