FileDocCategorySizeDatePackage
AxisOptionsRecord.javaAPI DocApache Poi 3.0.116052Mon Jan 01 12:39:40 GMT 2007org.apache.poi.hssf.record

AxisOptionsRecord

public class AxisOptionsRecord extends Record
The axis options record provides unit information and other various tidbits about the axis. NOTE: This source is automatically generated please do not modify this file. Either subclass or remove the record in src/records/definitions.
author
Andrew C. Oliver(acoliver at apache.org)

Fields Summary
public static final short
sid
private short
field_1_minimumCategory
private short
field_2_maximumCategory
private short
field_3_majorUnitValue
private short
field_4_majorUnit
private short
field_5_minorUnitValue
private short
field_6_minorUnit
private short
field_7_baseUnit
private short
field_8_crossingPoint
private short
field_9_options
private BitField
defaultMinimum
private BitField
defaultMaximum
private BitField
defaultMajor
private BitField
defaultMinorUnit
private BitField
isDate
private BitField
defaultBase
private BitField
defaultCross
private BitField
defaultDateSettings
Constructors Summary
public AxisOptionsRecord()



     
    

    
public AxisOptionsRecord(RecordInputStream in)
Constructs a AxisOptions record and sets its fields appropriately.

param
id id must be 0x1062 or an exception will be throw upon validation
param
size size the size of the data area of the record
param
data data of the record (should not contain sid/len)

        super(in);
    
    
Methods Summary
public java.lang.Objectclone()

        AxisOptionsRecord rec = new AxisOptionsRecord();
    
        rec.field_1_minimumCategory = field_1_minimumCategory;
        rec.field_2_maximumCategory = field_2_maximumCategory;
        rec.field_3_majorUnitValue = field_3_majorUnitValue;
        rec.field_4_majorUnit = field_4_majorUnit;
        rec.field_5_minorUnitValue = field_5_minorUnitValue;
        rec.field_6_minorUnit = field_6_minorUnit;
        rec.field_7_baseUnit = field_7_baseUnit;
        rec.field_8_crossingPoint = field_8_crossingPoint;
        rec.field_9_options = field_9_options;
        return rec;
    
protected voidfillFields(org.apache.poi.hssf.record.RecordInputStream in)

        field_1_minimumCategory        = in.readShort();
        field_2_maximumCategory        = in.readShort();
        field_3_majorUnitValue         = in.readShort();
        field_4_majorUnit              = in.readShort();
        field_5_minorUnitValue         = in.readShort();
        field_6_minorUnit              = in.readShort();
        field_7_baseUnit               = in.readShort();
        field_8_crossingPoint          = in.readShort();
        field_9_options                = in.readShort();
    
public shortgetBaseUnit()
Get the base unit field for the AxisOptions record.

        return field_7_baseUnit;
    
public shortgetCrossingPoint()
Get the crossing point field for the AxisOptions record.

        return field_8_crossingPoint;
    
public shortgetMajorUnit()
Get the major unit field for the AxisOptions record.

        return field_4_majorUnit;
    
public shortgetMajorUnitValue()
Get the major unit value field for the AxisOptions record.

        return field_3_majorUnitValue;
    
public shortgetMaximumCategory()
Get the maximum category field for the AxisOptions record.

        return field_2_maximumCategory;
    
public shortgetMinimumCategory()
Get the minimum category field for the AxisOptions record.

        return field_1_minimumCategory;
    
public shortgetMinorUnit()
Get the minor unit field for the AxisOptions record.

        return field_6_minorUnit;
    
public shortgetMinorUnitValue()
Get the minor unit value field for the AxisOptions record.

        return field_5_minorUnitValue;
    
public shortgetOptions()
Get the options field for the AxisOptions record.

        return field_9_options;
    
public intgetRecordSize()
Size of record (exluding 4 byte header)

        return 4  + 2 + 2 + 2 + 2 + 2 + 2 + 2 + 2 + 2;
    
public shortgetSid()

        return sid;
    
public booleanisDefaultBase()
use the default base unit

return
the default base field value.

        return defaultBase.isSet(field_9_options);
    
public booleanisDefaultCross()
use the default crossing point

return
the default cross field value.

        return defaultCross.isSet(field_9_options);
    
public booleanisDefaultDateSettings()
use default date setttings for this axis

return
the default date settings field value.

        return defaultDateSettings.isSet(field_9_options);
    
public booleanisDefaultMajor()
use the default major unit

return
the default major field value.

        return defaultMajor.isSet(field_9_options);
    
public booleanisDefaultMaximum()
use the default maximum category

return
the default maximum field value.

        return defaultMaximum.isSet(field_9_options);
    
public booleanisDefaultMinimum()
use the default minimum category

return
the default minimum field value.

        return defaultMinimum.isSet(field_9_options);
    
public booleanisDefaultMinorUnit()
use the default minor unit

return
the default minor unit field value.

        return defaultMinorUnit.isSet(field_9_options);
    
public booleanisIsDate()
this is a date axis

return
the isDate field value.

        return isDate.isSet(field_9_options);
    
public intserialize(int offset, byte[] data)

        int pos = 0;

        LittleEndian.putShort(data, 0 + offset, sid);
        LittleEndian.putShort(data, 2 + offset, (short)(getRecordSize() - 4));

        LittleEndian.putShort(data, 4 + offset + pos, field_1_minimumCategory);
        LittleEndian.putShort(data, 6 + offset + pos, field_2_maximumCategory);
        LittleEndian.putShort(data, 8 + offset + pos, field_3_majorUnitValue);
        LittleEndian.putShort(data, 10 + offset + pos, field_4_majorUnit);
        LittleEndian.putShort(data, 12 + offset + pos, field_5_minorUnitValue);
        LittleEndian.putShort(data, 14 + offset + pos, field_6_minorUnit);
        LittleEndian.putShort(data, 16 + offset + pos, field_7_baseUnit);
        LittleEndian.putShort(data, 18 + offset + pos, field_8_crossingPoint);
        LittleEndian.putShort(data, 20 + offset + pos, field_9_options);

        return getRecordSize();
    
public voidsetBaseUnit(short field_7_baseUnit)
Set the base unit field for the AxisOptions record.

        this.field_7_baseUnit = field_7_baseUnit;
    
public voidsetCrossingPoint(short field_8_crossingPoint)
Set the crossing point field for the AxisOptions record.

        this.field_8_crossingPoint = field_8_crossingPoint;
    
public voidsetDefaultBase(boolean value)
Sets the default base field value. use the default base unit

        field_9_options = defaultBase.setShortBoolean(field_9_options, value);
    
public voidsetDefaultCross(boolean value)
Sets the default cross field value. use the default crossing point

        field_9_options = defaultCross.setShortBoolean(field_9_options, value);
    
public voidsetDefaultDateSettings(boolean value)
Sets the default date settings field value. use default date setttings for this axis

        field_9_options = defaultDateSettings.setShortBoolean(field_9_options, value);
    
public voidsetDefaultMajor(boolean value)
Sets the default major field value. use the default major unit

        field_9_options = defaultMajor.setShortBoolean(field_9_options, value);
    
public voidsetDefaultMaximum(boolean value)
Sets the default maximum field value. use the default maximum category

        field_9_options = defaultMaximum.setShortBoolean(field_9_options, value);
    
public voidsetDefaultMinimum(boolean value)
Sets the default minimum field value. use the default minimum category

        field_9_options = defaultMinimum.setShortBoolean(field_9_options, value);
    
public voidsetDefaultMinorUnit(boolean value)
Sets the default minor unit field value. use the default minor unit

        field_9_options = defaultMinorUnit.setShortBoolean(field_9_options, value);
    
public voidsetIsDate(boolean value)
Sets the isDate field value. this is a date axis

        field_9_options = isDate.setShortBoolean(field_9_options, value);
    
public voidsetMajorUnit(short field_4_majorUnit)
Set the major unit field for the AxisOptions record.

        this.field_4_majorUnit = field_4_majorUnit;
    
public voidsetMajorUnitValue(short field_3_majorUnitValue)
Set the major unit value field for the AxisOptions record.

        this.field_3_majorUnitValue = field_3_majorUnitValue;
    
public voidsetMaximumCategory(short field_2_maximumCategory)
Set the maximum category field for the AxisOptions record.

        this.field_2_maximumCategory = field_2_maximumCategory;
    
public voidsetMinimumCategory(short field_1_minimumCategory)
Set the minimum category field for the AxisOptions record.

        this.field_1_minimumCategory = field_1_minimumCategory;
    
public voidsetMinorUnit(short field_6_minorUnit)
Set the minor unit field for the AxisOptions record.

        this.field_6_minorUnit = field_6_minorUnit;
    
public voidsetMinorUnitValue(short field_5_minorUnitValue)
Set the minor unit value field for the AxisOptions record.

        this.field_5_minorUnitValue = field_5_minorUnitValue;
    
public voidsetOptions(short field_9_options)
Set the options field for the AxisOptions record.

        this.field_9_options = field_9_options;
    
public java.lang.StringtoString()

        StringBuffer buffer = new StringBuffer();

        buffer.append("[AXCEXT]\n");
        buffer.append("    .minimumCategory      = ")
            .append("0x").append(HexDump.toHex(  getMinimumCategory ()))
            .append(" (").append( getMinimumCategory() ).append(" )");
        buffer.append(System.getProperty("line.separator")); 
        buffer.append("    .maximumCategory      = ")
            .append("0x").append(HexDump.toHex(  getMaximumCategory ()))
            .append(" (").append( getMaximumCategory() ).append(" )");
        buffer.append(System.getProperty("line.separator")); 
        buffer.append("    .majorUnitValue       = ")
            .append("0x").append(HexDump.toHex(  getMajorUnitValue ()))
            .append(" (").append( getMajorUnitValue() ).append(" )");
        buffer.append(System.getProperty("line.separator")); 
        buffer.append("    .majorUnit            = ")
            .append("0x").append(HexDump.toHex(  getMajorUnit ()))
            .append(" (").append( getMajorUnit() ).append(" )");
        buffer.append(System.getProperty("line.separator")); 
        buffer.append("    .minorUnitValue       = ")
            .append("0x").append(HexDump.toHex(  getMinorUnitValue ()))
            .append(" (").append( getMinorUnitValue() ).append(" )");
        buffer.append(System.getProperty("line.separator")); 
        buffer.append("    .minorUnit            = ")
            .append("0x").append(HexDump.toHex(  getMinorUnit ()))
            .append(" (").append( getMinorUnit() ).append(" )");
        buffer.append(System.getProperty("line.separator")); 
        buffer.append("    .baseUnit             = ")
            .append("0x").append(HexDump.toHex(  getBaseUnit ()))
            .append(" (").append( getBaseUnit() ).append(" )");
        buffer.append(System.getProperty("line.separator")); 
        buffer.append("    .crossingPoint        = ")
            .append("0x").append(HexDump.toHex(  getCrossingPoint ()))
            .append(" (").append( getCrossingPoint() ).append(" )");
        buffer.append(System.getProperty("line.separator")); 
        buffer.append("    .options              = ")
            .append("0x").append(HexDump.toHex(  getOptions ()))
            .append(" (").append( getOptions() ).append(" )");
        buffer.append(System.getProperty("line.separator")); 
        buffer.append("         .defaultMinimum           = ").append(isDefaultMinimum()).append('\n"); 
        buffer.append("         .defaultMaximum           = ").append(isDefaultMaximum()).append('\n"); 
        buffer.append("         .defaultMajor             = ").append(isDefaultMajor()).append('\n"); 
        buffer.append("         .defaultMinorUnit         = ").append(isDefaultMinorUnit()).append('\n"); 
        buffer.append("         .isDate                   = ").append(isIsDate()).append('\n"); 
        buffer.append("         .defaultBase              = ").append(isDefaultBase()).append('\n"); 
        buffer.append("         .defaultCross             = ").append(isDefaultCross()).append('\n"); 
        buffer.append("         .defaultDateSettings      = ").append(isDefaultDateSettings()).append('\n"); 

        buffer.append("[/AXCEXT]\n");
        return buffer.toString();
    
protected voidvalidateSid(short id)
Checks the sid matches the expected side for this record

param
id the expected sid.

        if (id != sid)
        {
            throw new RecordFormatException("Not a AxisOptions record");
        }