From 4d30bf280dbdb68ad72e01e911bf039b48ccb869 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ra=C3=BAl=20Benencia?= Date: Thu, 2 Aug 2012 18:06:23 -0300 Subject: Completed XML parsing --- model.py | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) (limited to 'model.py') diff --git a/model.py b/model.py index f63cbd6..fbba248 100644 --- a/model.py +++ b/model.py @@ -1,19 +1,20 @@ class Network(): """A simple network definition""" - def __init__(self, name): - self.name = name - self.domain = [] + def __init__(self): + self.name = "" + self.domains = [] + self.admins = [] self.ip_blocks = [] self.data = {} class Domain(): """A simple domain definition""" - def __init__(self, name, domain): - self.name = name - self.domain = domain + def __init__(self): + self.name = "" self.admins = [] + self.data = {} def add_admin(self, admin): """Add an administrator for this network""" @@ -23,10 +24,11 @@ class Domain(): class Person(): """A simple person definition""" - def __init__(self, name, surname, email): - self.name = name - self.surname = surname - self.email = email + def __init__(self): + self.name = "" + self.surname = "" + self.email = "" + self.data = {} class Data(): """Abstract class for storing and getting information""" -- cgit v1.2.3