//AUTOMATICALLY GENERATED BY genfields.pl.
//DO NOT EDIT!!!!

package vrml.field;
import vrml.*;
import java.io.BufferedReader;
import java.io.PrintWriter;
import java.io.IOException;

public class SFInt32 extends Field {
     int value;

    public SFInt32() { }

    public SFInt32(int value) {
	        this.value = value;
    }

    public int getValue() {
        __updateRead();
        return value;
    }

    public void setValue(int value) {
        this.value = value;
        __updateWrite();
    }


    public void setValue(ConstSFInt32 sfInt32) {
        sfInt32.__updateRead();
        value = sfInt32.value;
        __updateWrite();
    }

    public void setValue(SFInt32 sfInt32) {
        sfInt32.__updateRead();
        value = sfInt32.value;
        __updateWrite();
    }


    public String toString() {
        __updateRead();
        return String.valueOf(value);
    }

    public void __fromPerl(BufferedReader in)  throws IOException {

	//System.out.println ("fromPerl, Int32");
		value = Integer.parseInt(in.readLine());
    }

    public void __toPerl(PrintWriter out)  throws IOException {
        out.print(value);
	//out.println();
    }
    //public void setOffset(String offs) { this.offset = offs; } //JAS2
    //public String getOffset() { return this.offset; } //JAS2
}