AminetAminet
Search:
84721 packages online
About
Recent
Browse
Search
Upload
Setup
Services

util/shell/fileop.i386-aros.zip

Mirror:Random
Showing:m68k-amigaosppc-amigaosppc-morphosi386-arosi386-amithlonppc-warpupppc-powerupgeneric
No screenshot available
Short:file operations under shell.
Author:Azvareth
Uploader:hasse andersson gmail com (Azvareth)
Type:util/shell
Version:0.1
Requires:AROS
Architecture:i386-aros
Date:2014-03-10
Download:http://aminet.net/util/shell/fileop.i386-aros.zip - View contents
Readme:http://aminet.net/util/shell/fileop.i386-aros.readme
Downloads:577

 Programname: fileOP
 Description: file operations under shell.
      Author: Azvareth
Target group: Those who need to manipulate content of a file without resorting
            : to developer tools, or to those who need to view how to access
            : DOS.library functions from FreePascal.

WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING 
WARNING - on invalid handle your computer will most likely crash      - WARNING
WARNING -                                                             - WARNING
WARNING - I take no responsibility, I have tried to make it secure    - WARNING
WARNING - within the limitations... Usage is on own risk.             - WARNING
WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING 

: OPEN <mode> <filename>
: CLOSE <handle>
: READ <handle> <length> <fromPos>
: WRITE <handle> <fromPos> <string>
: SEEK <handle> <position> <offset mode>

fileOP USAGE:

  fileOP: OPEN <mode> <filename>               -  Open a file and return a
handle for file.
    set fh `fileOP OPEN NEW "text"`            -  
    modes are NEW, OLD, READWRITE              -  
                                           NEW - a new file is created, if a
file exists it is erased
                                           OLD - an existing file is opened
                                     READWRITE - an existing file is opened
otherwise a new one is created

  fileOP: CLOSE <handle>                       -  close a file referenced by
handle retrived from
    fileOP CLOSE $fh                           -  OPEN

  fileOP: READ <handle> <length>               -  read from file referenced by
handle, number of
    set sin `fileOP READ $fh 3`                -  chars actually read
                                               -  will set fopResult to number
of chars read
                                               -  will write string to Shell
CON:

  fileOP: WRITE <handle> <string>              -  write to file referenced by
handle, string to be
    fileOP WRITE $fh "the new fox in town..."  -  be written
                                               -  will set fopResult to number
of chars written
                                               -  will write number of chars
written to Shell CON:

  fileOP: SEEK <handle> <pos> <offs>           -  change the current position in
file and reads
                                               -  the current position, return
position in file
                                               -  before SEEK was called,
position may be positive
                                               -  or negative. Offset modes are
CURRENT, BEGINNING
                                               -  END.
  fileOP: SEEK $fh 0 "CURRENT"
    will return current position in file


  Notes
      1: in case of an error fileOP <COMMAND> will set fopResult to -1, if not
stated otherwise (or forgotten)
      2: fopResult is only valid until next fileOP call, when it may be
overwritten



License License License License License License License License License License
License License License


All rights
Yea! I guess I need to tell you all rights I might have here...

I do not have any, every code I publish or every line of text I write is public,
that means everyone have the right to use and or missuse it...

I however add this few lines that will make an exception to the public rule:
This might not be likely but it may state my opinion!


1. The code or text may NOT be used in any way that contributes to war
(real, civil or any kind of military like action against other humans)

2. The code or text may NOT  be used in anyway that threaten earths life,
that is trees, animals by pollution or greed... exception to this rule is
normal use of earth resources to live and function.

3. The code or text may under no way be used by people that believe that
one human race is less worth than another race, it may not be used by anyone
that believe (may be political or religious) that they have more rights and
therefore oppress someone else...




Uploaded using: archives.aros-exec.org


Contents of util/shell/fileop.i386-aros.zip
Archive:  /home/aminet/aminet_root/doc//util/shell/fileop.i386-aros.zip
 Length   Method    Size  Cmpr    Date    Time   CRC-32   Name
--------  ------  ------- ---- ---------- ----- --------  ----
  678290  Defl:N   196918  71% 2014-03-07 14:50 437d380b  fileOP
    6915  Defl:N     2005  71% 2014-03-07 15:18 7bd28a62  fileOP.pas
    4145  Defl:N     1427  66% 2014-03-07 15:28 5ef427de  fileOP.txt
--------          -------  ---                            -------
  689350           200350  71%                            3 files

Page generated in 0.04 seconds
Aminet © 1992-2024 Urban Müller and the Aminet team. Aminet contact address: <aminetaminet net>