Changeset 243 for trunk/packages
- Timestamp:
- Nov 12, 2007, 5:05:26 AM (17 years ago)
- Location:
- trunk/packages/sipb-xen-database/sipb-xen-database
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/packages/sipb-xen-database/sipb-xen-database/debian/changelog
r241 r243 1 sipb-xen-database (10.2) unstable; urgency=low 2 3 * Add MachineAccess to __all__ so it can be imported 4 * Remove unnecessary constructors for database objects 5 6 -- Quentin Smith <quentin@sipb-xen-dev.mit.edu> Mon, 12 Nov 2007 04:53:47 -0500 7 1 8 sipb-xen-database (10.1) unstable; urgency=low 2 9 -
trunk/packages/sipb-xen-database/sipb-xen-database/sipb_xen_database/models.py
r238 r243 7 7 'ctx', 8 8 'machine_table', 9 'machine_access_table', 9 10 'nic_table', 10 11 'disk_table', … … 12 13 'cdroms_table', 13 14 'Machine', 15 'MachineAccess', 14 16 'NIC', 15 17 'Disk', … … 70 72 71 73 class NIC(object): 72 def __init__(self, machine_id, mac_addr, ip, hostname):73 self.machine_id = machine_id74 self.mac_addr = mac_addr75 self.ip = ip76 self.hostname = hostname77 74 def __repr__(self): 78 75 return "<NIC: mac='%s' machine='%s' ip='%s' hostname='%s'>" % (self.mac_addr, self.machine_id, self.ip, self.hostname) 79 76 80 77 class Disk(object): 81 def __init__(self, machine_id, guest, size):82 self.machine_id = machine_id83 self.guest_device_name = guest84 self.size = size85 78 def __repr__(self): 86 79 return "<Disk: machine=%s device=%s size=%s>" % (self.machine_id, self.guest_device_name, self.size) … … 91 84 92 85 class CDROM(object): 93 def __init__(self, cdrom_id, description):94 self.cdrom_id = cdrom_id95 self.description = description96 86 def __repr__(self): 97 87 return "<CDROM %s: %s>" % (self.cdrom_id, self.description)
Note: See TracChangeset
for help on using the changeset viewer.