def configure_decorator(configure_impl): if self.configure_impl: raise OperationAlreadyDefinedError(Op.VIRTUAL_CONFIGURE) self.configure_impl = v.check_function(configure_impl, Op.VIRTUAL_CONFIGURE) return configure_impl
def initialize_decorator(initialize_impl): if self.initialize_impl: raise OperationAlreadyDefinedError(Op.VIRTUAL_INITIALIZE) self.initialize_impl = v.check_function(initialize_impl, Op.VIRTUAL_INITIALIZE) return initialize_impl
def mount_specification_decorator(mount_specification_impl): if self.mount_specification_impl: raise OperationAlreadyDefinedError(Op.VIRTUAL_MOUNT_SPEC) self.mount_specification_impl = v.check_function( mount_specification_impl, Op.VIRTUAL_MOUNT_SPEC) return mount_specification_impl
def worker_decorator(worker_impl): if self.worker_impl: raise OperationAlreadyDefinedError(Op.LINKED_WORKER) self.worker_impl = v.check_function(worker_impl, Op.LINKED_WORKER) return worker_impl
def status_decorator(status_impl): if self.status_impl: raise OperationAlreadyDefinedError(Op.VIRTUAL_STATUS) self.status_impl = v.check_function(status_impl, Op.VIRTUAL_STATUS) return status_impl
def post_snapshot_decorator(post_snapshot_impl): if self.post_snapshot_impl: raise OperationAlreadyDefinedError(Op.LINKED_POST_SNAPSHOT) self.post_snapshot_impl = v.check_function(post_snapshot_impl, Op.LINKED_POST_SNAPSHOT) return post_snapshot_impl
def stop_staging_decorator(stop_staging_impl): if self.stop_staging_impl: raise OperationAlreadyDefinedError(Op.LINKED_STOP_STAGING) self.stop_staging_impl = v.check_function(stop_staging_impl, Op.LINKED_STOP_STAGING) return stop_staging_impl
def snapshot_decorator(snapshot_impl): std_mig_id = self.__migration_id_set.add( migration_id, snapshot_impl.__name__) self.snapshot_id_to_impl[std_mig_id] = v.check_function( snapshot_impl, Op.UPGRADE_SNAPSHOT) return snapshot_impl
def virtual_source_decorator(virtual_source_impl): std_mig_id = self.__migration_id_set.add( migration_id, virtual_source_impl.__name__) self.virtual_source_id_to_impl[std_mig_id] = v.check_function( virtual_source_impl, Op.UPGRADE_VIRTUAL_SOURCE) return virtual_source_impl
def linked_source_decorator(linked_source_impl): std_mig_id = self.__migration_id_set.add( migration_id, linked_source_impl.__name__) self.linked_source_id_to_impl[std_mig_id] = v.check_function( linked_source_impl, Op.UPGRADE_LINKED_SOURCE) return linked_source_impl
def source_config_decorator(source_config_impl): std_mig_id = self.__migration_id_set.add( migration_id, source_config_impl.__name__) self.source_config_id_to_impl[std_mig_id] = v.check_function( source_config_impl, Op.UPGRADE_SOURCE_CONFIG) return source_config_impl
def repository_decorator(repository_impl): std_mig_id = self.__migration_id_set.add( migration_id, repository_impl.__name__) self.repository_id_to_impl[std_mig_id] = v.check_function( repository_impl, Op.UPGRADE_REPOSITORY) return repository_impl