rwlogo
Rogue Wave Views 5.6

Rogue Wave Views
Foundation Package API Reference Guide

Product Documentation:

Rogue Wave Views
Documentation Home

IlvQuarterTimeScaleRow Class Reference

Time scale row class. More...

#include <ilviews/graphics/timescalerow.h>

Inheritance diagram for IlvQuarterTimeScaleRow:
IlvTimeScaleRow

List of all members.

Public Member Functions

 IlvQuarterTimeScaleRow (IlvTimeScale *parent)
 Constructor.
virtual IlString computeDateText (IlDate dateval) const
 Returns the text that should be drawn for the interval beginning at the specified date.
virtual IlvTimeScaleRowcopy () const
 Returns a copy of the current time scale row.
IlString getQuarterLongString () const
 Returns the string that is used when year mode is not set.
IlString getQuarterShortString () const
 Returns the string that is used when year mode is set.
virtual
IlvTimeScaleRowFactory::rowtype 
getType () const
 Returns the type of the IlvTimeScaleRow.
virtual IlDate incrementTime (IlDate dateval)
 Increments the specified date by one quarter.
IlBoolean isYearMode ()
 Returns whether the displayed label contains the year or not.
virtual IlDate previousUnitTime (IlDate dateval)
 Returns the previous unit time value of the quarter relative to the specified date.
virtual void read (IlvInputFile &)
 Reads the time scale row description from an input file.
void setQuarterLongString (IlString str)
 Sets the string that is used when the year mode is not set.
void setQuarterShortString (IlString str)
 Sets the string that will be used when the year mode is set.
void setYearMode (IlBoolean val)
 Sets or unsets the year mode used to display labels.
virtual void write (IlvOutputFile &) const
 Saves the time scale row in an output file.

Protected Member Functions

virtual IlvTimeScaleRowcloneType (IlvTimeScale *) const
 Returns an object of the same type.

Detailed Description

Time scale row class.

Library: views

This class implements methods from the parent class IlvTimeScaleRow to provide a complete scale displaying quarter intervals. By default, each quarter interval is displayed with a text partly formatted using a java.text.SimpleDateFormat created with the "yyyy" string. The exact result depends on the year mode and on the string chosen to display the "Quarter" text. For example, by default, if year mode is set, the result will be "Qtr. 1 2002" for January 2002.

See also:
setYearMode
setQuarterShortString
setQuarterLongString

Constructor & Destructor Documentation

IlvQuarterTimeScaleRow::IlvQuarterTimeScaleRow ( IlvTimeScale parent  ) 

Constructor.

Creates and initializes an IlvQuarterTimeScaleRow object.


Member Function Documentation

virtual IlvTimeScaleRow* IlvQuarterTimeScaleRow::cloneType ( IlvTimeScale scale  )  const [protected, virtual]

Returns an object of the same type.

This method should be implemented by subclasses. It must return an object of the same type as the object on which the method is called, attached to the given IlvTimeScale.

Parameters:
scale The IlvTimeScale on which the row is attached.
Returns:
A newly allocated object of the same type as the object on which the method is called.

Implements IlvTimeScaleRow.

virtual IlString IlvQuarterTimeScaleRow::computeDateText ( IlDate  dateval  )  const [virtual]

Returns the text that should be drawn for the interval beginning at the specified date.

The current DateFormat of the time scale row is used to format the time. invalidateDateTextCache must be invoked whenever a row property changes which affects how this method formats the text.

Parameters:
dateval The date.
Returns:
The text string to display.

Reimplemented from IlvTimeScaleRow.

IlString IlvQuarterTimeScaleRow::getQuarterLongString (  )  const

Returns the string that is used when year mode is not set.

See also:
setQuarterLongString
IlString IlvQuarterTimeScaleRow::getQuarterShortString (  )  const

Returns the string that is used when year mode is set.

See also:
setQuarterShortString
virtual IlvTimeScaleRowFactory::rowtype IlvQuarterTimeScaleRow::getType (  )  const [virtual]

Returns the type of the IlvTimeScaleRow.

Returns:
The type of the IlvTimeScaleRow.

Implements IlvTimeScaleRow.

virtual IlDate IlvQuarterTimeScaleRow::incrementTime ( IlDate  dateval  )  [virtual]

Increments the specified date by one quarter.

For example, the incremented date of January 14th, 2002, 8:12:34 is April 14th, 2002, 8:12:34.

Parameters:
dateval The date to increment.

Implements IlvTimeScaleRow.

IlBoolean IlvQuarterTimeScaleRow::isYearMode (  ) 

Returns whether the displayed label contains the year or not.

Returns:
The year mode.
See also:
setYearMode
virtual IlDate IlvQuarterTimeScaleRow::previousUnitTime ( IlDate  dateval  )  [virtual]

Returns the previous unit time value of the quarter relative to the specified date.

For example, the previous unit time of January 14th, 2002, is January 1st, 2002.

Parameters:
dateval The date to floor.

Implements IlvTimeScaleRow.

virtual void IlvQuarterTimeScaleRow::read ( IlvInputFile infile  )  [virtual]

Reads the time scale row description from an input file.

Parameters:
infile The input file.

Reimplemented from IlvTimeScaleRow.

void IlvQuarterTimeScaleRow::setQuarterLongString ( IlString  str  ) 

Sets the string that is used when the year mode is not set.

The default string is "Quarter ".

Parameters:
str The string to display.
See also:
setYearMode
void IlvQuarterTimeScaleRow::setQuarterShortString ( IlString  str  ) 

Sets the string that will be used when the year mode is set.

The default string is "Qtr. ".

Parameters:
str The string to display.
See also:
setYearMode
void IlvQuarterTimeScaleRow::setYearMode ( IlBoolean  val  ) 

Sets or unsets the year mode used to display labels.

The year mode is used to display labels.

If the year mode is set, the labels are displayed as follows: Qtr. 1 2002

If the year mode is unset and the labels are displayed as follows : Quarter 1

Parameters:
val IlTrue to set the year mode and IlFalse to unset it.
See also:
setQuarterShortString
setQuarterLongString
virtual void IlvQuarterTimeScaleRow::write ( IlvOutputFile outfile  )  const [virtual]

Saves the time scale row in an output file.

Parameters:
outfile The output file.

Reimplemented from IlvTimeScaleRow.

 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

© Copyright 2012, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.