|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.tapestry.spec.BaseLocatable org.apache.tapestry.AbstractComponent org.apache.tapestry.BaseComponent sf.net.kayestry.KayaBaseComponent sf.net.kayestry.components.menu.MenuComponent
public abstract class MenuComponent
Genera un menu con JavaScript. El menu esta compuesto de items, que pueden
tener items hijos (submenues) o no. Soporta control de acceso en cada item. Y
el menu se lee desde menu.xml, desde el raiz del classpath.
Un menu de
ejemplo para ver la estructura del xml es el siguiente:
<?xml version="1.0"?> <root> <item id="0" name="Inicio" pageName="Home"/> <item id="1" name="Administracion"> <item name="Beneficiarios" pageName="BeneficiarioBrowse"> <allowed-roles> <role>admin</role> </allowed-roles> </item> </item> <item id="2" name="Reportes"> <allowed-roles> <role>usuario</role> </allowed-roles> </item> ... </root>Los roles permitidos son los que existan en la aplicacion, utilizando el esquema de seguridad que ofrece kommons. Estos roles no se heredan en los subitems. El id del menu debe ser unico en toda la definicion. Este id es utilizado para establecer el nombre del elemento que contiene el item.
Constructor Summary | |
---|---|
MenuComponent()
|
Method Summary | |
---|---|
protected abstract java.lang.String |
getDefinition()
|
java.util.Collection |
getMenu()
|
MenuItem |
getMenuItem()
|
MenuItem |
getMenuSubItem()
|
protected abstract boolean |
getShowLogin()
|
void |
setCurrentMenuItem(MenuItem value)
|
void |
setCurrentMenuSubItem(MenuItem value)
|
Methods inherited from class sf.net.kayestry.KayaBaseComponent |
---|
getVisit |
Methods inherited from class org.apache.tapestry.BaseComponent |
---|
addOuter, finishLoad, renderComponent |
Methods inherited from class org.apache.tapestry.AbstractComponent |
---|
addAsset, addBody, addComponent, cleanupAfterRender, finishLoad, fireObservedChange, fireObservedChange, fireObservedChange, fireObservedChange, fireObservedChange, fireObservedChange, fireObservedChange, fireObservedChange, fireObservedChange, format, format, format, format, formatString, formatString, formatString, formatString, generateAttributes, getAsset, getAssets, getBeans, getBinding, getBindingNames, getBindings, getBody, getBodyCount, getChangeObserver, getComponent, getComponents, getContainer, getExtendedId, getId, getIdPath, getListeners, getMessage, getMessages, getNamespace, getPage, getProperty, getSpecification, getString, pageEndRender, prepareForRender, render, renderBody, renderInformalParameters, setBinding, setContainer, setId, setNamespace, setPage, setProperty, setSpecification, toString |
Methods inherited from class org.apache.tapestry.spec.BaseLocatable |
---|
getLocation, setLocation |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.apache.tapestry.ILocationHolder |
---|
setLocation |
Methods inherited from interface org.apache.tapestry.ILocatable |
---|
getLocation |
Constructor Detail |
---|
public MenuComponent()
Method Detail |
---|
protected abstract java.lang.String getDefinition()
protected abstract boolean getShowLogin()
public java.util.Collection getMenu()
public void setCurrentMenuItem(MenuItem value)
public void setCurrentMenuSubItem(MenuItem value)
public MenuItem getMenuSubItem()
public MenuItem getMenuItem()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |