42 |
42 |
43 def read(self, fileNameOrDevice): |
43 def read(self, fileNameOrDevice): |
44 """ |
44 """ |
45 Public method to read a Netscape HTML bookmark file. |
45 Public method to read a Netscape HTML bookmark file. |
46 |
46 |
47 @param fileNameOrDevice name of the file to read (string) |
47 @param fileNameOrDevice name of the file to read |
|
48 @type str |
48 or reference to the device to read (QIODevice) |
49 or reference to the device to read (QIODevice) |
49 @return reference to the root node (BookmarkNode) |
50 @return reference to the root node |
|
51 @rtype BookmarkNode |
50 """ |
52 """ |
51 if isinstance(fileNameOrDevice, QIODevice): |
53 if isinstance(fileNameOrDevice, QIODevice): |
52 dev = fileNameOrDevice |
54 dev = fileNameOrDevice |
53 else: |
55 else: |
54 f = QFile(fileNameOrDevice) |
56 f = QFile(fileNameOrDevice) |