|
1 <!DOCTYPE html> |
|
2 <html><head> |
|
3 <title>eric6.Utilities.MimeTypes</title> |
|
4 <meta charset="UTF-8"> |
|
5 <style> |
|
6 body { |
|
7 background: #EDECE6; |
|
8 margin: 0em 1em 10em 1em; |
|
9 color: black; |
|
10 } |
|
11 |
|
12 h1 { color: white; background: #85774A; } |
|
13 h2 { color: white; background: #85774A; } |
|
14 h3 { color: white; background: #9D936E; } |
|
15 h4 { color: white; background: #9D936E; } |
|
16 |
|
17 a { color: #BA6D36; } |
|
18 |
|
19 </style> |
|
20 </head> |
|
21 <body><a NAME="top" ID="top"></a> |
|
22 <h1>eric6.Utilities.MimeTypes</h1> |
|
23 <p> |
|
24 Module implementing mimetype dependent functions. |
|
25 </p> |
|
26 <h3>Global Attributes</h3> |
|
27 <table> |
|
28 <tr><td>None</td></tr> |
|
29 </table> |
|
30 <h3>Classes</h3> |
|
31 <table> |
|
32 <tr><td>None</td></tr> |
|
33 </table> |
|
34 <h3>Functions</h3> |
|
35 <table> |
|
36 <tr> |
|
37 <td><a href="#isTextFile">isTextFile</a></td> |
|
38 <td>Function to test, if the given file is a text (i.e.</td> |
|
39 </tr><tr> |
|
40 <td><a href="#mimeType">mimeType</a></td> |
|
41 <td>Function to get the mime type of a file.</td> |
|
42 </tr> |
|
43 </table> |
|
44 <hr /><hr /> |
|
45 <a NAME="isTextFile" ID="isTextFile"></a> |
|
46 <h2>isTextFile</h2> |
|
47 <b>isTextFile</b>(<i>filename</i>) |
|
48 <p> |
|
49 Function to test, if the given file is a text (i.e. editable) file. |
|
50 </p><dl> |
|
51 <dt><i>filename</i></dt> |
|
52 <dd> |
|
53 name of the file to be checked (string) |
|
54 </dd> |
|
55 </dl><dl> |
|
56 <dt>Returns:</dt> |
|
57 <dd> |
|
58 flag indicating an editable file (boolean) |
|
59 </dd> |
|
60 </dl> |
|
61 <div align="right"><a href="#top">Up</a></div> |
|
62 <hr /><hr /> |
|
63 <a NAME="mimeType" ID="mimeType"></a> |
|
64 <h2>mimeType</h2> |
|
65 <b>mimeType</b>(<i>filename</i>) |
|
66 <p> |
|
67 Function to get the mime type of a file. |
|
68 </p><dl> |
|
69 <dt><i>filename</i></dt> |
|
70 <dd> |
|
71 name of the file to be checked (string) |
|
72 </dd> |
|
73 </dl><dl> |
|
74 <dt>Returns:</dt> |
|
75 <dd> |
|
76 mime type of the file (string) |
|
77 </dd> |
|
78 </dl> |
|
79 <div align="right"><a href="#top">Up</a></div> |
|
80 <hr /> |
|
81 </body></html> |