From 59fb4f76d4954b0f20c988f799c7e4982d63472e Mon Sep 17 00:00:00 2001 From: devicerandom Date: Thu, 31 Jul 2008 16:45:20 +0000 Subject: [PATCH] (hooke_cli.py) Implemented info command --- hooke_cli.py | 14 ++++++++++++++ libhookecurve.py | 1 + 2 files changed, 15 insertions(+) diff --git a/hooke_cli.py b/hooke_cli.py index 460eccd..fb3e32e 100755 --- a/hooke_cli.py +++ b/hooke_cli.py @@ -891,6 +891,20 @@ Syntax: current def do_current(self,args): print self.current.path + def do_info(self,args): + ''' + INFO + ---- + Returns informations about the current curve. + ''' + print 'Path: ',self.current.path + print 'Experiment: ',self.current.curve.experiment + print 'Filetype: ',self.current.curve.filetype + for plot in self.current.curve.default_plots(): + for set in plot.vectors: + lengths=[len(item) for item in set] + print 'Data set size: ',lengths + def do_version(self,args): ''' VERSION diff --git a/libhookecurve.py b/libhookecurve.py index 099b19f..7683cf1 100755 --- a/libhookecurve.py +++ b/libhookecurve.py @@ -33,6 +33,7 @@ class Driver: ''' def __init__(self): self.experiment='' + self.filetype='' def is_me(self): ''' -- 2.26.2