Package org.itsnat.comp

Examples of org.itsnat.comp.ItsNatComponent


        return removeItsNatComponent(node,false);
    }

    public ItsNatComponent removeItsNatComponent(Node node,boolean dispose)
    {
        ItsNatComponent comp = findItsNatComponent(node);
        if (comp == null) return null;
        removeItsNatComponent(comp,dispose);
        return comp;
    }
View Full Code Here


        Element element = (Element)node;

        if (componentType == null) // Esto incluye el caso de creaci�n expl�cita del usuario pero no especifica el componentType, pero sin embargo est� en el HTML
            componentType = getCompTypeAttribute(element);   // Puede ser null

        ItsNatComponent comp = null;
        boolean doFilters = hasBeforeAfterCreateItsNatComponentListener();
        if (doFilters) comp = processBeforeCreateItsNatComponentListener(node,componentType,artifacts);

        if (comp == null)
        {
View Full Code Here

        return false;
    }

    public ItsNatComponent processBeforeCreateItsNatComponentListener(Node node,String componentType,NameValue[] artifacts)
    {
        ItsNatComponent comp = null;
        Iterator<CreateItsNatComponentListener> createCompIterator = null;

        ItsNatDocumentTemplateImpl docTemplate = itsNatDoc.getItsNatDocumentTemplateImpl();
        ItsNatServletImpl servlet = docTemplate.getItsNatServletImpl();
View Full Code Here

        return comp;
    }

    public ItsNatComponent processBeforeCreateItsNatComponentListener(Iterator<CreateItsNatComponentListener> it,Node node,String componentType,NameValue[] artifacts)
    {
        ItsNatComponent comp = null;

        // Permitimos as� que el usuario pueda crear sus propios componentes
        // que ser�n instanciados cuando sea llamado este m�todo
        // incluso podr�a substituir a los que hay por defecto segun el nodo
        // No deber�a a�adirse nuevos listeners cuando ya haya documentos cargados
View Full Code Here

        {
            if (findItsNatComponent(node) != null) // para evitar a�adir dos veces
                return null;
        }

        ItsNatComponent component = createItsNatComponent(node,componentType,artifacts,autoBuildMode); // puede ser null
        if (component != null)
        {
            ItsNatComponent oldComp = addItsNatComponent(component)// Si es null no hace nada
            if (oldComp != null)
                throw new ItsNatDOMException("A component is already associated to this node",node);
        }
        return component; // puede ser null
    }
View Full Code Here

    public LinkedList<ItsNatComponent> buildItsNatComponents(Node node,LinkedList<ItsNatComponent> listComp)
    {
        // Primero procesamos el propio nodo pues si es un componente
        // puede crear y eliminar nodos hijo, luego procesamos los hijos tal y como ha quedado

        ItsNatComponent comp = addItsNatComponent(node,null,null,true); // Si no puede ser un componente no hace nada
        if (comp != null)
        {
            if (listComp == null)
                listComp = new LinkedList<ItsNatComponent>(); // Se crea cuando se necesita
            listComp.add(comp);
View Full Code Here

        {
            ItsNatComponent[] listRes = new ItsNatComponent[components.size()];
            int i = 0;
            for (Map.Entry<Node,ItsNatComponent> entry : components.entrySet())
            {
                ItsNatComponent comp = entry.getValue();
                if (dispose) comp.dispose();
                listRes[i] = comp;
                i++;
            }
            components.clear();
            return listRes;
View Full Code Here

        {
            removeItsNatComponents(child,dispose,listComp);
            child = child.getNextSibling();
        }

        ItsNatComponent comp = removeItsNatComponent(node,dispose);
        if ((comp != null)&&(listComp != null))
            listComp.add(comp);
    }
View Full Code Here

                Element cellContentElem = cellInfo.getCellContentElement();
                Object value = dataModel.getValueAt(row,column);
                boolean isSelected = table.isCellSelected(row,column);
                beforeShow(cellContentElem);
                ItsNatTableCellEditor cellEditor = getItsNatTableCellEditor();
                ItsNatComponent compEditor = cellEditor.getTableCellEditorComponent(table,row,column,value,isSelected,cellContentElem);
                afterShow(compEditor);
            }
        }
    }
View Full Code Here

            Object dataNode = path.getLastPathComponent();
            boolean isLeaf = dataModel.isLeaf(dataNode);
            boolean expanded = cellInfo.isExpanded();
            beforeShow(labelElem);
            ItsNatTreeCellEditor cellEditor = getItsNatTreeCellEditor();
            ItsNatComponent compEditor = cellEditor.getTreeCellEditorComponent(tree,row,dataNode,isSelected, expanded,isLeaf,labelElem);
            afterShow(compEditor);
        }
    }
View Full Code Here

TOP

Related Classes of org.itsnat.comp.ItsNatComponent

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.