Example #1
0
 def splitext(self, path):
     idx = path.rfind('.')
     if idx == -1:
         idx = len(path)
     return (path[0:idx], path[idx:])
Example #2
0
 def split(self, path):
     idx = path.rfind(self.sep)
     if idx == -1:
         return ('', path)
     return (path[:idx], path[(idx + 1):])
Example #3
0
 def split(self, path):
     idx = path.rfind(self.sep)
     if idx == -1:
         return ('', path)
     return (path[:idx], path[(idx + 1):])
Example #4
0
 def splitext(self, path):
     idx = path.rfind('.')
     if idx == -1:
         idx = 0
     return (path[0:idx], path[idx:])
Example #5
0
 def splitext(self, path):
     idx = path.rfind(".")
     if idx == -1:
         idx = len(path)
     return (path[0:idx], path[idx:])