code: def deallocate(self):
          
          if self._domain is not None:
              self._domain_delete()
          if self._network is not None and 'network' in self.configuration:
              self._network_delete()
          if self._hypervisor is not None:
              self._hypervisor_delete()
docs: Releases all resources.