DirectoryStream.st
changeset 25352 4b3e54307e32
parent 24870 55257b1ccb31
equal deleted inserted replaced
25351:30b332af1f33 25352:4b3e54307e32
     1 "{ Encoding: utf8 }"
       
     2 
       
     3 "
     1 "
     4  COPYRIGHT (c) 1989 by Claus Gittinger
     2  COPYRIGHT (c) 1989 by Claus Gittinger
     5 	      All Rights Reserved
     3 	      All Rights Reserved
     6 
     4 
     7  This software is furnished under a license and may be used
     5  This software is furnished under a license and may be used
   707     ok == true ifTrue:[
   705     ok == true ifTrue:[
   708         self registerForFinalization.
   706         self registerForFinalization.
   709         osPathname isNil ifTrue:[
   707         osPathname isNil ifTrue:[
   710             "UNIX: does not automatically provide the first entry"
   708             "UNIX: does not automatically provide the first entry"
   711 
   709 
   712             (StreamError,StreamIOError) handle:[:ex |
   710             StreamError handle:[:ex |
   713                 self close.
   711                 self close.
   714                 ex reject.
   712                 ex reject.
   715             ] do:[
   713             ] do:[
   716                 readAheadEntry := OperatingSystem nextLinkInfoFrom:self dirPointer:dirPointer.
   714                 readAheadEntry := OperatingSystem nextLinkInfoFrom:self dirPointer:dirPointer.
   717             ].
   715             ].
   718         ] ifFalse:[
   716         ] ifFalse:[
   719             "Windows already provides the first entry's info"
   717             "Windows already provides the first entry's info"
   720 
   718 
   721             readAheadEntry := OperatingSystem
   719             readAheadEntry := Win32OperatingSystem
   722                 linkInfoFor:osPathname
   720                 linkInfoFor:osPathname
   723                 fileSize:fileSize
   721                 fileSize:fileSize
   724                 fileAttributes:osFileAttributes
   722                 fileAttributes:osFileAttributes
   725                 osCrtTime:osCrtTime
   723                 osCrtTime:osCrtTime
   726                 osAccTime:osAccTime
   724                 osAccTime:osAccTime
   738         ^ self openError:error.
   736         ^ self openError:error.
   739     ].
   737     ].
   740     ^ nil
   738     ^ nil
   741 
   739 
   742     "Modified: / 09-04-2018 / 19:03:18 / stefan"
   740     "Modified: / 09-04-2018 / 19:03:18 / stefan"
   743     "Modified: / 22-11-2018 / 15:49:37 / Stefan Vogel"
       
   744     "Modified: / 29-05-2019 / 11:32:47 / Claus Gittinger"
   741     "Modified: / 29-05-2019 / 11:32:47 / Claus Gittinger"
       
   742     "Modified: / 01-04-2020 / 14:22:44 / Stefan Vogel"
   745 !
   743 !
   746 
   744 
   747 reOpen
   745 reOpen
   748     "USERS WILL NEVER INVOKE THIS METHOD
   746     "USERS WILL NEVER INVOKE THIS METHOD
   749      sent after snapin to reopen streams."
   747      sent after snapin to reopen streams."