Author: bugman Date: Tue Sep 30 17:53:55 2008 New Revision: 7463 URL: http://svn.gna.org/viewcvs/relax?rev=7463&view=rev Log: Shifted the reset() functional code to generic_fns. Added: branches/pipe_refs/generic_fns/reset.py - copied, changed from r7451, branches/pipe_refs/prompt/reset.py Modified: branches/pipe_refs/prompt/reset.py Copied: branches/pipe_refs/generic_fns/reset.py (from r7451, branches/pipe_refs/prompt/reset.py) URL: http://svn.gna.org/viewcvs/relax/branches/pipe_refs/generic_fns/reset.py?p2=branches/pipe_refs/generic_fns/reset.py&p1=branches/pipe_refs/prompt/reset.py&r1=7451&r2=7463&rev=7463&view=diff ============================================================================== --- branches/pipe_refs/prompt/reset.py (original) +++ branches/pipe_refs/generic_fns/reset.py Tue Sep 30 17:53:55 2008 @@ -1,6 +1,6 @@ ############################################################################### # # -# Copyright (C) 2003-2004, 2006-2007 Edward d'Auvergne # +# Copyright (C) 2003-2004, 2006-2008 Edward d'Auvergne # # # # This file is part of the program relax. # # # @@ -24,22 +24,8 @@ from data import Relax_data_store; ds = Relax_data_store() -# The relax data storage object. +def reset(): + """Reset relax.""" - -class Reset: - def __init__(self, relax): - """Class containing the function for reinitialising the relax data storage object.""" - - self.relax = relax - - - def reset(self): - """Reset relax. - - All of the data of the relax data storage object will be erased and hence relax will return - to its initial state. - """ - - # Run the relax data storage object reset method. - ds.__reset__() + # Run the relax data storage object reset method. + ds.__reset__() Modified: branches/pipe_refs/prompt/reset.py URL: http://svn.gna.org/viewcvs/relax/branches/pipe_refs/prompt/reset.py?rev=7463&r1=7462&r2=7463&view=diff ============================================================================== --- branches/pipe_refs/prompt/reset.py (original) +++ branches/pipe_refs/prompt/reset.py Tue Sep 30 17:53:55 2008 @@ -1,6 +1,6 @@ ############################################################################### # # -# Copyright (C) 2003-2004, 2006-2007 Edward d'Auvergne # +# Copyright (C) 2003-2004, 2006-2008 Edward d'Auvergne # # # # This file is part of the program relax. # # # @@ -21,10 +21,7 @@ ############################################################################### # relax module imports. -from data import Relax_data_store; ds = Relax_data_store() - - -# The relax data storage object. +import generic_fns class Reset: @@ -41,5 +38,5 @@ to its initial state. """ - # Run the relax data storage object reset method. - ds.__reset__() + # Execute the functional code. + generic_fns.reset.reset()