NuSphere Forums Forum Index
NuSphere Forums
Reply to topic
Display a single class var


Joined: 15 Jun 2005
Posts: 46
Reply with quote
Sample source:

$this->Name = 'Test';
$this->City = 'NY';

When in debug mode i position the cursor on $this->Name the debug shows all the vars of the class.
With a few vars this is not a problem, but when a class has a lot of vars I've to fallback on the debug windows to find the value for the class var.

Is there a way/option just to show the var the cusor is on instead of the whole class?


Scub.
View user's profileFind all posts by ScubaticusSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
If you positioned mouse on $this, debugger displays ~ top 30 values and shows that there are more. If you need only $this->Name evaluated, just select whole this text it and position mouse over it.
Alternatively you may type $this->Name then hit Enter in Immediate window or you may add this expression into Watch window.
View user's profileFind all posts by dmitriSend private messageVisit poster's website


Joined: 15 Jun 2005
Posts: 46
Reply with quote
I did not know it could be done this way ...
You could asked yourself however if you're really intereseted in the whole class object when you put the cursor over the var.
Whats wrong by showing the value immediately instead of marking the field first or go to immediate?

Every extra action just to show a single classvar is slowing down the debugging process the way you suggest ....

Perhaps I expect to much Wink

Regards, Scub.
View user's profileFind all posts by ScubaticusSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
If cursor is put over $this, whole the class is supposed to be shown.
If cursor is put over its member, for example, $this->somevar, I'd expect only this somevar to be shown. On the other hand, it's unclear what to do with $this->somemethod($args). If you select this method with arguments, debugger will call this method and show you the results. I'm not sure if it's good to have this done without any additional actions (text selection).
View user's profileFind all posts by dmitriSend private messageVisit poster's website
Display a single class var
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT - 5 Hours  
Page 1 of 1  

  
  
 Reply to topic