com.inet.html.views
Class ObjectView

java.lang.Object
  extended by javax.swing.text.View
      extended by com.inet.html.views.BoxView
          extended by com.inet.html.views.ControlView
              extended by com.inet.html.views.ObjectView
All Implemented Interfaces:
ILayouted, java.awt.event.ContainerListener, java.util.EventListener, javax.swing.SwingConstants

public class ObjectView
extends ControlView
implements java.awt.event.ContainerListener

An ObjectView is basically equal to a HTML form control. It displays some kind of component depending on it's parameters. This ObjectView is limited to the basic functionality of the HTML OBJECT specification. It supports the classid and codebase parameter as well as simple string parameters. It does not support stacked OBJECT Tags.


Field Summary
 
Fields inherited from class com.inet.html.views.ControlView
TYPE_BUTTON, TYPE_CHECKBOX, TYPE_HIDDEN, TYPE_MENU, TYPE_RADIOBUTTON, TYPE_SELECT, TYPE_TEXTAREA, TYPE_TEXTFIELD
 
Fields inherited from class com.inet.html.views.BoxView
BASELINE, STATUS_REQ_LAYOUT, STATUS_REQ_PRELAYOUT, STATUS_UPTODATE
 
Fields inherited from class javax.swing.text.View
BadBreakWeight, ExcellentBreakWeight, ForcedBreakWeight, GoodBreakWeight, X_AXIS, Y_AXIS
 
Fields inherited from interface javax.swing.SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
 
Constructor Summary
ObjectView(javax.swing.text.Element elem)
          For Factory-Use only!
 
Method Summary
 void componentAdded(java.awt.event.ContainerEvent e)
          
 void componentRemoved(java.awt.event.ContainerEvent e)
          
 boolean init()
          Create the internal display components
 boolean isSubmit()
          returns true if this control can submit a form
 boolean isSuccessful(ControlView activator)
          Determines the current success status for a submit.
 
Methods inherited from class com.inet.html.views.ControlView
getControl, getControlHeight, getControlPanel, getControlWidth, getFirstLineBaseLine, getLayout, getName, getPreferredSpan, getType, getValue, isReset, modelToView, paint, performLayout, performLayoutVAlign, performLayoutWidth, performPreLayout, predictWidth, setParent, toString, viewToModel
 
Methods inherited from class com.inet.html.views.BoxView
addBoxPainter, factoryPreset, forceLayout, forceLayout, getAlignment, getAutoMarginJustify, getBackgroundValue, getBorderBottomColor, getBorderLeftColor, getBorderRightColor, getBorderTopColor, getBottomInset, getBox, getBoxPainter, getClear, getCompleteHight, getContentHeight, getContentVerticalOffset, getContentWidth, getDirection, getDisplay, getEndOffset, getFloat, getFontSize, getHeightUnit, getHTMLRoot, getJustification, getLeftInset, getLineHeight, getMargins, getOuterHeight, getOuterWidth, getOverflow, getPainter, getPosition, getRenderContext, getResizeWeight, getRightInset, getSpan, getStartOffset, getStatus, getSwingAlign, getTopInset, getUnicodeBidi, getViewForPosition, getViewIndex, getViewIndex, getVisibility, getWhiteSpace, getWidthUnit, isAbsolutePositioned, isBlock, isBreak, isBreakable, isFloating, isInFlow, isListItemWithMarker, isLTR, isMarker, isNativeLTR, isTableCell, isWidthSet, setBackgroundValue, setBorderBottomColor, setBorderLeftColor, setBorderRightColor, setBorderTopColor, setContentVerticalOffset, setContentWidth, setFirstLineBaseLine, setIsNativeLTR, setJustification, setMarker, setPainter, setRoot, setSize, setSizeContent, setStartAndEndOffset, setStatus, setStatusLocal
 
Methods inherited from class javax.swing.text.View
append, breakView, changedUpdate, createFragment, getAttributes, getBreakWeight, getChildAllocation, getContainer, getDocument, getElement, getGraphics, getMaximumSpan, getMinimumSpan, getNextVisualPositionFrom, getParent, getToolTipText, getView, getViewCount, getViewFactory, getViewIndex, insert, insertUpdate, isVisible, modelToView, modelToView, preferenceChanged, remove, removeAll, removeUpdate, replace, viewToModel
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ObjectView

public ObjectView(javax.swing.text.Element elem)
For Factory-Use only!

Parameters:
elem - the Element, which defines the object
Method Detail

init

public boolean init()
Create the internal display components

Returns:
true, if everything is up and ready, false otherwise

isSubmit

public boolean isSubmit()
returns true if this control can submit a form

Overrides:
isSubmit in class ControlView
Returns:
returns true if this control can submit a form

isSuccessful

public boolean isSuccessful(ControlView activator)
Determines the current success status for a submit. If a control is successful it's name and value should be included in the submission data.

Overrides:
isSuccessful in class ControlView
Parameters:
activator - the current button, which submitted the form
Returns:
true, if the control is successful
See Also:
http://www.w3.org/TR/REC-html40/interact/forms.html#successful-controls

componentAdded

public void componentAdded(java.awt.event.ContainerEvent e)

Specified by:
componentAdded in interface java.awt.event.ContainerListener

componentRemoved

public void componentRemoved(java.awt.event.ContainerEvent e)

Specified by:
componentRemoved in interface java.awt.event.ContainerListener