Changeset 34172 in project


Ignore:
Timestamp:
06/06/17 21:55:30 (6 months ago)
Author:
sjamaan
Message:

man/5: Update docs for new set-file-times! procedure

File:
1 edited

Legend:

Unmodified
Added
Removed
  • wiki/man/5/Module (chicken file posix)

    r34094 r34172  
    231231==== file-access-time
    232232==== file-change-time
     233==== file-modification-time
    233234<procedure>(file-access-time FILE)</procedure><br>
    234235<procedure>(file-change-time FILE)</procedure><br>
    235 
    236 Returns time (in seconds) of the last access or change of
    237 {{FILE}}. {{FILE}} may be a filename or a file-descriptor. If the file
    238 does not exist, an error is signaled.
    239 
    240 {{file-access-time}} and {{file-change-time}} also accept a port object as their argument.
    241 
    242 ==== file-modification-time
    243 
    244236<procedure>(file-modification-time FILE)</procedure>
    245 <procedure>(set! (file-modification-time FILE) SECONDS)</procedure>
    246 
    247 Returns time (in seconds) of the last modification of
    248 {{FILE}}. {{FILE}} may be a filename or a file-descriptor. If the file
    249 does not exist, an error is signaled.
    250 
    251 {{file-modification-time}} also accepts a port object as its argument.
    252 
    253 {{(set! (file-modification-time FILE) SECONDS)}} sets the access- and
    254 modification time of {{FILE}} to {{SECONDS}}.
     237
     238Returns time (in seconds) of the last access, inode change or content
     239modification of {{FILE}}, respectively. {{FILE}} may be a filename, a
     240file-descriptor or a file-backed port. If the file does not exist, an
     241error is signaled.
     242
     243==== set-file-times!
     244
     245<procedure>(set-file-times! FILE [MTIME [ATIME]])</procedure>
     246
     247Sets the time of last modification {{MTIME}} and/or time of last
     248access {{ATIME}} (in seconds) for {{FILE}}. {{FILE}} may be a
     249filename, a file-descriptor or a file-backed port. If the file does
     250not exist, an error is signaled.
     251
     252If neither {{MTIME}} nor {{ATIME}} is supplied, the current time is
     253used.  If only {{MTIME}} is supplied, {{ATIME}} will be set to the
     254same value.  If an argument is {{#f}}, it will not be changed.
     255
     256Consequently, if only {{MTIME}} is passed and it is {{#f}}, {{ATIME}}
     257is assumed to be {{#f}} as well and neither will be changed.
    255258
    256259
Note: See TracChangeset for help on using the changeset viewer.