Author: bugman Date: Sun May 4 11:44:58 2008 New Revision: 6063 URL: http://svn.gna.org/viewcvs/relax?rev=6063&view=rev Log: Renamed all the 'rename' and 'renumber' fns to 'name' and 'number'. Modified: branches/mol_res_spin_module_rename/generic_fns/molecule.py branches/mol_res_spin_module_rename/generic_fns/residue.py branches/mol_res_spin_module_rename/generic_fns/spin.py Modified: branches/mol_res_spin_module_rename/generic_fns/molecule.py URL: http://svn.gna.org/viewcvs/relax/branches/mol_res_spin_module_rename/generic_fns/molecule.py?rev=6063&r1=6062&r2=6063&view=diff ============================================================================== --- branches/mol_res_spin_module_rename/generic_fns/molecule.py (original) +++ branches/mol_res_spin_module_rename/generic_fns/molecule.py Sun May 4 11:44:58 2008 @@ -33,38 +33,7 @@ """ -def display_molecule(mol_id=None): - """Function for displaying the information associated with the molecule. - - @param mol_id: The molecule identifier string. - @type mol_id: str - """ - - # Split up the selection string. - mol_token, res_token, spin_token = tokenise(mol_id) - - # Disallowed selections. - if res_token != None: - raise RelaxResSelectDisallowError - if spin_token != None: - raise RelaxSpinSelectDisallowError - - # The molecule selection string. - if mol_token: - mol_sel = '#' + mol_token - else: - mol_sel = None - - # Print a header. - print "\n\n%-15s %-15s" % ("Molecule", "Number of residues") - - # Molecule loop. - for mol in molecule_loop(mol_sel): - # Print the molecule data. - print "%-15s %-15s" % (mol.name, `len(mol.res)`) - - -def rename_molecule(mol_id, new_name=None): +def name_molecule(mol_id, new_name=None): """Function for renaming molecules. @param mol_id: The identifier string for the molecule to rename. Modified: branches/mol_res_spin_module_rename/generic_fns/residue.py URL: http://svn.gna.org/viewcvs/relax/branches/mol_res_spin_module_rename/generic_fns/residue.py?rev=6063&r1=6062&r2=6063&view=diff ============================================================================== --- branches/mol_res_spin_module_rename/generic_fns/residue.py (original) +++ branches/mol_res_spin_module_rename/generic_fns/residue.py Sun May 4 11:44:58 2008 @@ -33,29 +33,7 @@ """ -def display_residue(res_id=None): - """Function for displaying the information associated with the residue. - - @param res_id: The molecule and residue identifier string. - @type res_id: str - """ - - # Split up the selection string. - mol_token, res_token, spin_token = tokenise(res_id) - - # Disallow spin selections. - if spin_token != None: - raise RelaxSpinSelectDisallowError - - # Print a header. - print "\n\n%-15s %-15s %-15s %-15s" % ("Molecule", "Res number", "Res name", "Number of spins") - - # Residue loop. - for res, mol_name in residue_loop(res_id, full_info=True): - print "%-15s %-15s %-15s %-15s" % (mol_name, `res.num`, res.name, `len(res.spin)`) - - -def rename_residue(res_id, new_name=None): +def name_residue(res_id, new_name=None): """Function for renaming residues. @param res_id: The identifier string for the residue(s) to rename. @@ -81,7 +59,7 @@ res.name = new_name -def renumber_residue(res_id, new_number=None): +def number_residue(res_id, new_number=None): """Function for renumbering residues. @param res_id: The identifier string for the residue to renumber. Modified: branches/mol_res_spin_module_rename/generic_fns/spin.py URL: http://svn.gna.org/viewcvs/relax/branches/mol_res_spin_module_rename/generic_fns/spin.py?rev=6063&r1=6062&r2=6063&view=diff ============================================================================== --- branches/mol_res_spin_module_rename/generic_fns/spin.py (original) +++ branches/mol_res_spin_module_rename/generic_fns/spin.py Sun May 4 11:44:58 2008 @@ -31,22 +31,6 @@ This touches part of the molecule-residue-spin data structure. """ - - -def display_spin(spin_id=None): - """Function for displaying the information associated with the spin. - - @param spin_id: The molecule and residue identifier string. - @type spin_id: str - """ - - # Print a header. - print "\n\n%-15s %-15s %-15s %-15s %-15s" % ("Molecule", "Res number", "Res name", "Spin number", "Spin name") - - # Spin loop. - for spin, mol_name, res_num, res_name in spin_loop(spin_id, full_info=True): - # Print the residue data. - print "%-15s %-15s %-15s %-15s %-15s" % (mol_name, `res_num`, res_name, `spin.num`, spin.name) def name_spin(spin_id=None, name=None):