Subversion Repositories Kolibri OS

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
3618 hidnplayr 1
;;================================================================================================;;
2
;;//// libio.inc //// (c) mike.dld, 2007-2008 ////////////////////////////////////////////////////;;
3
;;================================================================================================;;
4
;;                                                                                                ;;
5
;; This file is part of Common development libraries (Libs-Dev).                                  ;;
6
;;                                                                                                ;;
7
;; Libs-Dev is free software: you can redistribute it and/or modify it under the terms of the GNU ;;
8
;; Lesser General Public License as published by the Free Software Foundation, either version 2.1 ;;
9
;; of the License, or (at your option) any later version.                                         ;;
10
;;                                                                                                ;;
11
;; Libs-Dev is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without  ;;
12
;; even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU  ;;
13
;; Lesser General Public License for more details.                                                ;;
14
;;                                                                                                ;;
15
;; You should have received a copy of the GNU Lesser General Public License along with Libs-Dev.  ;;
16
;; If not, see .                                                    ;;
17
;;                                                                                                ;;
18
;;================================================================================================;;
19
 
20
 
21
O_BINARY = 00000000b
22
O_READ   = 00000001b
23
O_WRITE  = 00000010b
24
O_CREATE = 00000100b
25
O_SHARE  = 00001000b
26
O_TEXT   = 00010000b
27
 
28
SEEK_SET = 0
29
SEEK_CUR = 1
30
SEEK_END = 2
31
 
32
struct FileDateTime
33
  union
34
    time    dd ?
35
    struct
36
      sec   db ?
37
      min   db ?
38
      hour  db ?
39
    ends
40
  ends
41
  union
42
    date    dd ?
43
    struct
44
      day   db ?
45
      month db ?
46
      year  dw ?
47
    ends
48
  ends
49
ends
50
 
51
struct FileInfoBlock
52
  Function   dd ?
53
  Position   dd ?
54
  Flags      dd ?
55
  Count      dd ?
56
  Buffer     dd ?
57
             db ?
58
  FileName   dd ?
59
ends
60
 
61
struct FileInfoHeader
62
  Version    dd ?
63
  FilesRead  dd ?
64
  FilesCount dd ?
65
             rd 5
66
ends
67
 
68
struct FileInfoA
69
  Attributes   dd ?
70
  Flags        dd ?
71
  DateCreate   FileDateTime
72
  DateAccess   FileDateTime
73
  DateModify   FileDateTime
74
  union
75
    FileSize   dq ?
76
    struct
77
      FileSizeLow  dd ?
78
      FileSizeHigh dd ?
79
    ends
80
  ends
81
  FileName     rb 264
82
ends
83
 
84
struct FileInfoW
85
  Attributes   dd ?
86
  Flags        dd ?
87
  DateCreate   FileDateTime
88
  DateAccess   FileDateTime
89
  DateModify   FileDateTime
90
  union
91
    FileSize   dq ?
92
    struct
93
      FileSizeLow  dd ?
94
      FileSizeHigh dd ?
95
    ends
96
  ends
97
  FileName     rw 264
98
ends
99
 
100
virtual at 0
101
         FileInfo            FileInfoA
102
         FileInfo fix        FileInfoA
103
  sizeof.FileInfo fix sizeof.FileInfoA
104
end virtual
105
 
106
FA_READONLY = 00000001b
107
FA_HIDDEN   = 00000010b
108
FA_SYSTEM   = 00000100b
109
FA_LABEL    = 00001000b
110
FA_FOLDER   = 00010000b
111
FA_ARCHIVED = 00100000b
112
FA_NORMAL   = 01000000b
113
FA_ANY      = 01111111b