Copyright © 2011 Citra Technologies. All Rights Reserved.

com.citra.pivot.table.context
Class DateColumnContext.DateContext

java.lang.Object
  extended by com.citra.pivot.table.context.DateColumnContext.DateContext
All Implemented Interfaces:
Serializable
Enclosing class:
DateColumnContext

public static class DateColumnContext.DateContext
extends Object
implements Serializable

DateContext is a class that holds the fields of a Calendar object. Fields can be assigned/retrieved with the setCalendarField, getCalendarField methods respectively.

See Also:
Serialized Form

Field Summary
protected  int[] fields
          the field values strored in an int array
 
Constructor Summary
DateColumnContext.DateContext(Calendar calendar)
          Constructs a DateInfo from a calendar object.
DateColumnContext.DateContext(Calendar calendar, int[] fields)
          Constructs a DateInfo from a calendar object, storing only fields in the int array.
 
Method Summary
 int getCalendarField(int field)
          Retrieves a field's value as previously stored.
 void setCalendarField(int field, int value)
          Assigns a field value.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

fields

protected int[] fields
the field values strored in an int array

Constructor Detail

DateColumnContext.DateContext

public DateColumnContext.DateContext(Calendar calendar)
Constructs a DateInfo from a calendar object.


DateColumnContext.DateContext

public DateColumnContext.DateContext(Calendar calendar,
                                     int[] fields)
Constructs a DateInfo from a calendar object, storing only fields in the int array.

Method Detail

getCalendarField

public int getCalendarField(int field)
Retrieves a field's value as previously stored.

Parameters:
field - the field to retrieve
Returns:
the field's value

setCalendarField

public void setCalendarField(int field,
                             int value)
Assigns a field value.

Parameters:
field - the field for which a value is assigned
value - the value to assign

Copyright © 2011 Citra Technologies. All Rights Reserved.