Drag[en]gine Script Module DragonScript Script API  1.0
FileWriter Class Reference

File writer. More...

Inheritance diagram for FileWriter:

Public Member Functions

Constructors
FileWriter new (String filename)
 Create file writer writing to virtual file system file. More...
 
Management
String getFilename ()
 File name. More...
 
int getStreamVersion ()
 Stream version used by writeToFile of native classes. More...
 
void setStreamVersion (int version)
 Set stream version used by writeToFile of native classes. More...
 
void writeChar (int value)
 Write one byte (1 byte). More...
 
void writeByte (int value)
 Write one unsigned byte (1 byte). More...
 
void writeShort (int value)
 Write one short (2 bytes). More...
 
void writeUShort (int value)
 Write one unsigned short (2 bytes). More...
 
void writeInt (int value)
 Write one int (4 bytes). More...
 
void writeUInt (int value)
 Write one unsigned int (4 bytes). More...
 
void writeFloat (float value)
 Write one float (4 bytes). More...
 
void writeString8 (String string)
 Write a string prefixed by a 1-byte length field. More...
 
void writeString16 (String string)
 Write a string prefixed by a 2-byte2 length field. More...
 
void writeString (String data)
 Write string without length field. More...
 
void writeData (FileReader reader, int size)
 Write data from file reader. More...
 

Detailed Description

File writer.

This is a native class.

Author
Roland Pl├╝ss
Version
1.0
Date
2015

Member Function Documentation

◆ getFilename()

String getFilename ( )

File name.

◆ getStreamVersion()

int getStreamVersion ( )

Stream version used by writeToFile of native classes.

◆ new()

FileWriter new ( String  filename)

Create file writer writing to virtual file system file.

◆ setStreamVersion()

void setStreamVersion ( int  version)

Set stream version used by writeToFile of native classes.

◆ writeByte()

void writeByte ( int  value)

Write one unsigned byte (1 byte).

◆ writeChar()

void writeChar ( int  value)

Write one byte (1 byte).

◆ writeData()

void writeData ( FileReader  reader,
int  size 
)

Write data from file reader.

◆ writeFloat()

void writeFloat ( float  value)

Write one float (4 bytes).

◆ writeInt()

void writeInt ( int  value)

Write one int (4 bytes).

◆ writeShort()

void writeShort ( int  value)

Write one short (2 bytes).

◆ writeString()

void writeString ( String  data)

Write string without length field.

◆ writeString16()

void writeString16 ( String  string)

Write a string prefixed by a 2-byte2 length field.

◆ writeString8()

void writeString8 ( String  string)

Write a string prefixed by a 1-byte length field.

◆ writeUInt()

void writeUInt ( int  value)

Write one unsigned int (4 bytes).

◆ writeUShort()

void writeUShort ( int  value)

Write one unsigned short (2 bytes).


The documentation for this class was generated from the following file: