src/eric7/QtHelpInterface/QtHelpSchemeHandler.py

branch
eric7
changeset 10431
64157aeb0312
parent 9686
2eee7a645cba
child 10439
21c28b0f9e41
equal deleted inserted replaced
10430:e440aaf179ce 10431:64157aeb0312
191 191
192 def readData(self, maxlen): 192 def readData(self, maxlen):
193 """ 193 """
194 Public method to retrieve data from the reply object. 194 Public method to retrieve data from the reply object.
195 195
196 @param maxlen maximum number of bytes to read (integer) 196 @param maxlen maximum number of bytes to read
197 @return string containing the data (bytes) 197 @type int
198 @return string containing the data
199 @rtype bytes
198 """ 200 """
199 with EricMutexLocker(self.__mutex): 201 with EricMutexLocker(self.__mutex):
200 return self.__buffer.read(maxlen) 202 return self.__buffer.read(maxlen)
201 203
202 def close(self): 204 def close(self):
208 210
209 def __mimeFromUrl(self, url): 211 def __mimeFromUrl(self, url):
210 """ 212 """
211 Private method to guess the mime type given an URL. 213 Private method to guess the mime type given an URL.
212 214
213 @param url URL to guess the mime type from (QUrl) 215 @param url URL to guess the mime type from
214 @return mime type for the given URL (string) 216 @type QUrl
217 @return mime type for the given URL
218 @rtype str
215 """ 219 """
216 path = url.path() 220 path = url.path()
217 ext = os.path.splitext(path)[1].lower() 221 ext = os.path.splitext(path)[1].lower()
218 if ext in ExtensionMap: 222 if ext in ExtensionMap:
219 return ExtensionMap[ext] 223 return ExtensionMap[ext]

eric ide

mercurial