Gentee Programming Language > Documentation > Libraries Download documentation

Buffer - binary data

It is possible to use variables of the buf type for working with memory. This type can be defined in the language as binary data.

  • Operations
  • Methods

    Operations

    Operations defined for the variable of buf type are listed below. The second column contains possible statements where typename is a variable or an expression of the specified type.
     
    OperationSyntaxReturn typeComments
    Variable descriptionbuf name[i]-allocate a memory block of i bytes during initialization and initiate it with zeros.
    []buf[i]byteGetting byte i from the buffer.
    ** bufuintGet the size of the memory being used.
    =buf = bufbufCopying data from one buffer into another.
    +=buf += buf
    buf += byte
    buf += sbyte
    buf += short
    buf += ushort
    buf += int
    buf += uint
    buf += str
    buf += ulong
    buf += long
    bufAdding data to the buffer.
    +buf + bufbufPutting two buffers together and creating a resulting buffer.
    ==buf == bufuintComparison operations.
    !=buf != bufuint-
    <buf < bufuint-
    >buf > bufuint-
    <=buf <= bufuint-
    >=buf >= bufuint-

    Methods

    buf.allocMemory allocation
    buf.appendData addition
    buf.clearClearing data
    buf.copyCopying
    buf.crcCalculating the checksum
    buf.delData deletion
    buf.expandExpansion
    buf.freeMemory deallocation
    buf.getmultistrGetting data from a string array
    buf.insertData insertion
    buf.readReading from a file
    buf.replaceOverwriting data
    buf.setmultistrWriting data into a string array
    buf.writeWriting to a file
    buf.writeappendAppending data to a file
    Initializing the search patternCreating data search pattern
    Data searchSearching through the buffer for the specified data


     Copyright © 2004-2006 Gentee Inc. All rights reserved.