|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--java.awt.Component
|
+--java.awt.Container
|
+--java.awt.Panel
|
+--java.applet.Applet
|
+--javax.swing.JApplet
|
+--org.objectweb.jac.aspects.gui.AppletView
This class allows the programmer to insert specialized object views defined as applets.
This is useful when views can be used by an Internet browser at client-side.
The programmer must subclass this class and overload the
init method.
init(),
Serialized Form| Field Summary | |
protected DisplayContext |
context
|
protected ViewFactory |
factory
|
protected String |
label
|
protected Object[] |
parameters
|
protected Object |
substance
|
protected String |
type
|
| Fields inherited from class javax.swing.JApplet |
accessibleContext, rootPane, rootPaneCheckingEnabled |
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
AppletView(ViewFactory factory,
DisplayContext context,
Object substance)
The AppletView's constructor. |
|
| Method Summary | |
void |
close(boolean validate)
Close this view. |
boolean |
equalsView(String type,
Object[] parameters)
|
boolean |
equalsView(ViewIdentity view)
Tells if a view is the same as another one, ie it has the same type and parameters. |
Border |
getBorder()
Get the value of border. |
DisplayContext |
getContext()
|
String |
getDescription()
Get the value of description. |
ViewFactory |
getFactory()
Gets the factory. |
String |
getLabel()
Gets the view's label (identifier). |
MethodItem |
getMessage()
Get the value of message. |
Object[] |
getParameters()
The parameters that were used to compile the view. |
View |
getParentView()
Get the value of parent. |
View |
getRootView()
Gets the ancestor view whose parent is null |
String |
getStyle()
Gets the user-defined style for this view. |
Object |
getSubstance()
|
String |
getType()
Gets the view type. |
Border |
getViewBorder()
Get the value of viewBorder. |
void |
init()
Initializes the applet view. |
boolean |
isClosed()
Tells if this view has been closed by the GUI or the user. |
boolean |
isDescendantOf(View ancestor)
Tells wether this view has a given view in its ancestors |
void |
setBorder(Border v)
Set the value of border. |
void |
setContext(DisplayContext context)
Sets the display context for this view. |
void |
setDescription(String v)
Set the value of description. |
void |
setFactory(ViewFactory factory)
Sets the factory for this view (WEB, SWING or other supported factory). |
void |
setFocus(FieldItem field,
Object option)
Focus a field of an object's view. |
void |
setHeight(int heigth)
Sets the prefered height for this view. |
void |
setLabel(String label)
Sets the label (the identifier) of the view. |
void |
setMessage(MethodItem v)
Set the value of message. |
void |
setParameters(Object[] parameters)
Sets the parameters that were used to construct the view. |
void |
setParentView(View v)
Set the value of parent. |
void |
setStyle(String style)
Sets the view style. |
void |
setSubstance(Object substance)
|
void |
setType(String type)
Set the view type. |
void |
setViewBorder(Border v)
Set the value of viewBorder. |
void |
setWidth(int width)
Sets the prefered width for this view. |
| Methods inherited from class javax.swing.JApplet |
addImpl, createRootPane, getAccessibleContext, getContentPane, getGlassPane, getJMenuBar, getLayeredPane, getRootPane, isRootPaneCheckingEnabled, paramString, remove, setContentPane, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, update |
| Methods inherited from class java.applet.Applet |
destroy, getAppletContext, getAppletInfo, getAudioClip, getAudioClip, getCodeBase, getDocumentBase, getImage, getImage, getLocale, getParameter, getParameterInfo, isActive, newAudioClip, play, play, resize, resize, setStub, showStatus, start, stop |
| Methods inherited from class java.awt.Panel |
addNotify |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
protected String label
protected DisplayContext context
protected ViewFactory factory
protected Object[] parameters
protected String type
protected Object substance
| Constructor Detail |
public AppletView(ViewFactory factory,
DisplayContext context,
Object substance)
factory - context - substance - the object that is represented by this view| Method Detail |
public Border getViewBorder()
getViewBorder in interface Viewpublic void setViewBorder(Border v)
setViewBorder in interface Viewv - Value to assign to viewBorder.public View getParentView()
getParentView in interface ViewCompositeViewpublic void setParentView(View v)
setParentView in interface Viewv - Value to assign to parent.CompositeViewpublic View getRootView()
View
getRootView in interface Viewpublic boolean isDescendantOf(View ancestor)
View
isDescendantOf in interface Viewancestor - the ancestorpublic void setStyle(String style)
View
setStyle in interface Viewpublic String getStyle()
View
getStyle in interface Viewpublic Border getBorder()
public void setBorder(Border v)
v - Value to assign to border.public String getDescription()
getDescription in interface Viewpublic void setDescription(String v)
setDescription in interface Viewv - Value to assign to description.View.setMessage(MethodItem)public void setLabel(String label)
View
setLabel in interface Viewlabel - a string that identifies the viewpublic String getLabel()
View
getLabel in interface Viewpublic MethodItem getMessage()
getMessage in interface Viewpublic void setMessage(MethodItem v)
setMessage in interface Viewv - Value to assign to message.View.setDescription(String)public void setContext(DisplayContext context)
ViewThe display context contains the factory that is used for this view.
setContext in interface Viewpublic DisplayContext getContext()
getContext in interface Viewpublic void setFactory(ViewFactory factory)
View
setFactory in interface Viewpublic ViewFactory getFactory()
View
getFactory in interface Viewpublic void setWidth(int width)
View
setWidth in interface Viewpublic void setHeight(int heigth)
View
setHeight in interface Viewpublic void setParameters(Object[] parameters)
ViewIdentity
setParameters in interface ViewIdentitypublic Object[] getParameters()
ViewIdentity
getParameters in interface ViewIdentitypublic void setType(String type)
ViewIdentity
setType in interface ViewIdentitypublic String getType()
ViewIdentity
getType in interface ViewIdentitypublic boolean equalsView(ViewIdentity view)
ViewIdentity
equalsView in interface ViewIdentity
public boolean equalsView(String type,
Object[] parameters)
equalsView in interface ViewIdentitypublic void close(boolean validate)
View
close in interface Viewpublic boolean isClosed()
View
isClosed in interface Viewpublic Object getSubstance()
public void setSubstance(Object substance)
public void setFocus(FieldItem field,
Object option)
View
setFocus in interface Viewfield - the field to focusoption - an extra optionpublic void init()
The programmer must overload this class and start the init
method code with super.init() so that the applet's
container initialization is done.
init in class Applet
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||