Author: bugman Date: Wed Aug 19 17:45:24 2009 New Revision: 9345 URL: http://svn.gna.org/viewcvs/relax?rev=9345&view=rev Log: Renamed the pipe.list() user function to pipe.display(). Modified: 1.3/generic_fns/pipes.py 1.3/prompt/pipe.py Modified: 1.3/generic_fns/pipes.py URL: http://svn.gna.org/viewcvs/relax/1.3/generic_fns/pipes.py?rev=9345&r1=9344&r2=9345&view=diff ============================================================================== --- 1.3/generic_fns/pipes.py (original) +++ 1.3/generic_fns/pipes.py Wed Aug 19 17:45:24 2009 @@ -129,6 +129,17 @@ ds.current_pipe = None +def display(): + """Print the details of all the data pipes.""" + + # Heading. + print("%-20s%-20s" % ("Data pipe name", "Data pipe type")) + + # Loop over the data pipes. + for pipe_name in ds: + print("%-20s%-20s" % (pipe_name, get_type(pipe_name))) + + def get_pipe(name=None): """Return a data pipe. @@ -184,17 +195,6 @@ return False -def list(): - """Print the details of all the data pipes.""" - - # Heading. - print("%-20s%-20s" % ("Data pipe name", "Data pipe type")) - - # Loop over the data pipes. - for pipe_name in ds: - print("%-20s%-20s" % (pipe_name, get_type(pipe_name))) - - def pipe_loop(name=False): """Generator function for looping over and yielding the data pipes. Modified: 1.3/prompt/pipe.py URL: http://svn.gna.org/viewcvs/relax/1.3/prompt/pipe.py?rev=9345&r1=9344&r2=9345&view=diff ============================================================================== --- 1.3/prompt/pipe.py (original) +++ 1.3/prompt/pipe.py Wed Aug 19 17:45:24 2009 @@ -200,6 +200,26 @@ pipes.delete(pipe_name=pipe_name) + def display(self): + """Print a list of all the data pipes. + + Examples + ~~~~~~~~ + + To run the user function, type: + + relax> pipe.display() + """ + + # Function intro text. + if self.__relax__.interpreter.intro: + text = sys.ps3 + "pipe.display()" + print(text) + + # Execute the functional code. + pipes.display() + + def hybridise(self, hybrid=None, pipes=None): """Create a hybrid data pipe by fusing a number of other data pipes. @@ -256,26 +276,6 @@ hybrid_obj.hybridise(hybrid=hybrid, pipe_list=pipes) - def list(self): - """Print a list of all the data pipes. - - Examples - ~~~~~~~~ - - To run the user function, type: - - relax> pipe.list() - """ - - # Function intro text. - if self.__relax__.interpreter.intro: - text = sys.ps3 + "pipe.list()" - print(text) - - # Execute the functional code. - pipes.list() - - def switch(self, pipe_name=None): """Function for switching between data pipes.