#NEWLINE# @ typecheck ( Resource ) #NEWLINE# def list_experiment_instance_ids_by_resource( self , resource ) : #NEWLINE# #INDENT# client = self . _redis_maker ( ) #NEWLINE# experiment_instance_ids = [ ] #NEWLINE# weblab_resource_instance_experiments = ( WEBLAB_RESOURCE_INSTANCE_EXPERIMENTS % ( resource . resource_type , resource . resource_instance ) ) #NEWLINE# current_members = ( client . smembers ( weblab_resource_instance_experiments ) or [ ] ) #NEWLINE# for member in current_members : #NEWLINE# #INDENT# experiment_instance_id = ExperimentInstanceId . parse ( member ) #NEWLINE# experiment_instance_ids . append ( experiment_instance_id ) #NEWLINE# #UNINDENT# return experiment_instance_ids