471,350 Members | 1,589 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,350 software developers and data experts.

Better way to searching.

my code is here:

__________________________________________________ _______________________

def Globing(self, dir, extension, nop, inputDepth):
'It creates a basic glob function that needed in other classes'
self.exop = '*.'
self.opr = '*/'
self.counter = ''
self.files = []
self.path = ''
for i in range (inputDepth):
self.path = dir + self.opr * i + self.exop * nop + extension
#like this: */*/*.*.mpg
self.counter = glob.glob(self.path)
self.files += self.counter
return self.files
__________________________________________________ __________________________

Is there any better and faster way to do this?
Dec 14 '07 #1
1 883
thanks, I'll try it.
Dec 14 '07 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

14 posts views Thread by Sean C. | last post: by
39 posts views Thread by bazad | last post: by
3 posts views Thread by Jay | last post: by
8 posts views Thread by Gordon Knote | last post: by
10 posts views Thread by Paul | last post: by
33 posts views Thread by Geoff Jones | last post: by
5 posts views Thread by CoreyWhite | last post: by
204 posts views Thread by Masood | last post: by
reply views Thread by XIAOLAOHU | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.