JHotDraw 6.0b1

org.jhotdraw.contrib.html
Class FigureDataContentProducer

java.lang.Object
  extended by org.jhotdraw.contrib.html.AbstractContentProducer
      extended by org.jhotdraw.contrib.html.FigureDataContentProducer
All Implemented Interfaces:
java.io.Serializable, ContentProducer, Storable
Direct Known Subclasses:
AttributeFigureContentProducer, ColorContentProducer, URLContentProducer

public class FigureDataContentProducer
extends AbstractContentProducer
implements java.io.Serializable

FigureDataContentProducer produces content on behalf of Figures.
It supports the basic information common to all figures. It can only be used as a generic producer, getting information from any figure passed to the getContents method.

See Also:
Serialized Form

Field Summary
 
Fields inherited from interface org.jhotdraw.contrib.html.ContentProducer
ENTITY_ARROW_MODE, ENTITY_FIGURE_HEIGHT, ENTITY_FIGURE_POSX, ENTITY_FIGURE_POSY, ENTITY_FIGURE_WIDTH, ENTITY_FILL_COLOR, ENTITY_FONT_NAME, ENTITY_FONT_SIZE, ENTITY_FONT_STYLE, ENTITY_FRAME_COLOR
 
Constructor Summary
FigureDataContentProducer()
          Constructor for the FigureContentProducer object
 
Method Summary
 java.lang.Object getContent(ContentProducerContext context, java.lang.String ctxAttrName, java.lang.Object ctxAttrValue)
          Produces the contents for the figure
 void read(StorableInput dr)
          Writes the storable
 void write(StorableOutput dw)
          Writes the storable
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FigureDataContentProducer

public FigureDataContentProducer()
Constructor for the FigureContentProducer object

Method Detail

getContent

public java.lang.Object getContent(ContentProducerContext context,
                                   java.lang.String ctxAttrName,
                                   java.lang.Object ctxAttrValue)
Produces the contents for the figure

Specified by:
getContent in interface ContentProducer
Parameters:
context - the calling client context
ctxAttrName - the attribute name
ctxAttrValue - the figure
Returns:
The string value for the requested entity name

write

public void write(StorableOutput dw)
Writes the storable

Specified by:
write in interface Storable
Overrides:
write in class AbstractContentProducer
Parameters:
dw - the storable output

read

public void read(StorableInput dr)
          throws java.io.IOException
Writes the storable

Specified by:
read in interface Storable
Overrides:
read in class AbstractContentProducer
Parameters:
dr - the storable input
Throws:
java.io.IOException - thrown by called methods

JHotDraw 6.0b1