// Collection of code snippets by Arne Vajhøj 
// (from articles on eksperten.dk / vajhoej.dk written sometime between 2004 and now) 
import dk.vajhoej.record.Alignment;
import dk.vajhoej.record.Endian;
import dk.vajhoej.record.FieldType;
import dk.vajhoej.record.Struct;
import dk.vajhoej.record.StructField;

@Struct(endianess=Endian.LITTLE, alignment=Alignment.ALIGN1)
public class TrailerAssetISAM extends AssetISAM {
    @StructField(n=3, type=FieldType.INT4)
    private int ownWeight;
    @StructField(n=4, type=FieldType.INT4)
    private int maxCargo;
    @StructField(n=5, type=FieldType.INT4)
    private int roof;
    public TrailerAssetISAM() {
        this(0, "", 0, 0, 0);
    }
    public TrailerAssetISAM(int id, String description, int ownWeight, int maxCargo, int roof) {
        super(id, description, 2);
        this.ownWeight = ownWeight;
        this.maxCargo = maxCargo;
        this.roof = roof;
    }
    public int getOwnWeight() {
        return ownWeight;
    }
    public void setOwnWeight(int ownWeight) {
        this.ownWeight = ownWeight;
    }
    public int getMaxCargo() {
        return maxCargo;
    }
    public void setMaxCargo(int maxCargo) {
        this.maxCargo = maxCargo;
    }
    public int getRoof() {
        return roof;
    }
    public void setRoof(int roof) {
        this.roof = roof;
    }
}
