[SVN] Bundle commit 472

Brad Miller bonelake at mac.com
Tue Mar 15 02:34:24 UTC 2005


Kumar,

I've been thinking more about how to do the sorting and have methods 
associated with the right classes.
The general idea :
    create a dictionary keyed by class names.
    The values for each key in this dictionary will be a list of the 
methods that we find in that class.

Now we've got two different regular expressions we want to match for:
   1. the outer level typically going to be class I guess
   2. the inner level methods and functions.

The trick is figuring out an elegant way to fit that into your handler 
classes.

Brad

On Mar 14, 2005, at 2:59 PM, Brad Miller wrote:

> Hi Kumar,
> No problem.
>
> I know exactly what you are talking about with the sorting.  
> Personally, I don't think I'll use sorting, I kind keep a mental model 
> of the file in my head so I typically know what order my methods and 
> classes are defined in, seeing them sorted is actually harder for me.  
> I only took on the sorting project because Eric requested it and 
> hacking Python was more exiting to work on than writing my data 
> structures exam. :-)
>
> I think I have an idea of how we could keep the the methods sorted 
> with the classes  and present the classes in alphabetical order.  
> Since the data structures exam is ready to go, I should have some time 
> tonight to try a prototype.
>
> Brad
>
> On Mar 14, 2005, at 2:51 PM, Kumar McMillan wrote:
>
>> Hey Brad -- thanks for adding the sort logic.  I shifted some things
>> around came up with a separate SortableEntities interface.  see
>> revision 480.  The only thing I couldn't figure out (since I am new to
>> Python) is how to sort recursively through the groups of matched line
>> parts.  For example, PHP functions should be sorted but kept grouped
>> within their class (same goes for Python).  Take a look and let me
>> know if you have some ideas.  I can send you PHP code examples, but
>> running the Entity Nav on the entitynav.py file is a good way to see
>> what I am talking about.
>>
>> K
>
> Brad Miller, Ph.D.
> Assistant Professor, Computer Science
> Luther College
> http://www.cs.luther.edu/~bmiller
> _______________________________________________
> textmate-dev mailing list
> textmate-dev at lists.macromates.com
> http://lists.macromates.com/mailman/listinfo/textmate-dev
>
Brad Miller, PhD
Assistant Professor
Luther College
http://www.cs.luther.edu/~bmiller
jabber:  bnmnetp at jabber.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: text/enriched
Size: 2475 bytes
Desc: not available
URL: <http://lists.macromates.com/textmate-dev/attachments/20050314/173fe340/attachment.bin>


More information about the textmate-dev mailing list