def __init__(self, rack_position, molecule_design_pool, stock_tube_barcodes): """ :param rack_position: The source rack position in the source rack. :type rack_position: :class:`thelma.entities.rack.RackPosition` :param molecule_design_pool: A molecule design pool to generate. :type molecule_design_pool: :class:`thelma.entities.moleculedesign.MoleculeDesignPool` :param stock_tube_barcodes: The stock tube barcodes for the single molecule design tubes used to generate this pool. :type stock_tube_barcodes: :class:`list` """ MoleculeDesignPoolPosition.__init__(self, rack_position=rack_position, molecule_design_pool=molecule_design_pool, position_type=FIXED_POSITION_TYPE) if not isinstance(stock_tube_barcodes, list): msg = 'The stock tube barcodes must be a list (obtained: %s).' \ % (stock_tube_barcodes.__class__.__name__) raise TypeError(msg) #: A list of molecules contained in the pool (ordered by ID). self.molecule_designs = [] for md in molecule_design_pool.molecule_designs: self.molecule_designs.append(md) self.molecule_designs.sort() #: The stock tube barcodes for the single molecule design tubes #: used to generate this pool self.stock_tube_barcodes = sorted(stock_tube_barcodes)
def __init__(self, rack_position, molecule_design_pool=None, position_type=None, iso_concentration=None, iso_volume=None): """ Constructor: :param rack_position: The rack position. :type rack_position: :class:`thelma.entities.rack.RackPosition`. :param molecule_design_pool: The molecule design pool for this position or a valid placeholder. :type molecule_design_pool: :class:`thelma.entities.moleculedesign.MoleculeDesignPool` or :class:`basestring` :param position_type: influences valid values for other parameters :type position_type: :class:`str :param iso_concentration: The concentration requested from the stock. :type iso_concentration: positive number :param iso_volume: The volume requested by the stock. :type iso_volume: positive number """ MoleculeDesignPoolPosition.__init__(self, rack_position=rack_position, molecule_design_pool=molecule_design_pool, position_type=position_type) #: The concentration requested by the stock management. self.iso_concentration = get_converted_number(iso_concentration) #: The volume requested by the stock management. self.iso_volume = get_converted_number(iso_volume) self.__check_values_for_position_type()
def __init__(self, rack_position, molecule_design_pool, stock_tube_barcodes): """ :param rack_position: The source rack position in the source rack. :type rack_position: :class:`thelma.entities.rack.RackPosition` :param molecule_design_pool: A molecule design pool to generate. :type molecule_design_pool: :class:`thelma.entities.moleculedesign.MoleculeDesignPool` :param stock_tube_barcodes: The stock tube barcodes for the single molecule design tubes used to generate this pool. :type stock_tube_barcodes: :class:`list` """ MoleculeDesignPoolPosition.__init__( self, rack_position=rack_position, molecule_design_pool=molecule_design_pool, position_type=FIXED_POSITION_TYPE) if not isinstance(stock_tube_barcodes, list): msg = 'The stock tube barcodes must be a list (obtained: %s).' \ % (stock_tube_barcodes.__class__.__name__) raise TypeError(msg) #: A list of molecules contained in the pool (ordered by ID). self.molecule_designs = [] for md in molecule_design_pool.molecule_designs: self.molecule_designs.append(md) self.molecule_designs.sort() #: The stock tube barcodes for the single molecule design tubes #: used to generate this pool self.stock_tube_barcodes = sorted(stock_tube_barcodes)
def __init__(self, rack_position, molecule_design_pool=None, position_type=None, iso_concentration=None, iso_volume=None): """ Constructor: :param rack_position: The rack position. :type rack_position: :class:`thelma.entities.rack.RackPosition`. :param molecule_design_pool: The molecule design pool for this position or a valid placeholder. :type molecule_design_pool: :class:`thelma.entities.moleculedesign.MoleculeDesignPool` or :class:`basestring` :param position_type: influences valid values for other parameters :type position_type: :class:`str :param iso_concentration: The concentration requested from the stock. :type iso_concentration: positive number :param iso_volume: The volume requested by the stock. :type iso_volume: positive number """ MoleculeDesignPoolPosition.__init__( self, rack_position=rack_position, molecule_design_pool=molecule_design_pool, position_type=position_type) #: The concentration requested by the stock management. self.iso_concentration = get_converted_number(iso_concentration) #: The volume requested by the stock management. self.iso_volume = get_converted_number(iso_volume) self.__check_values_for_position_type()