Package org.apache.tapestry

Examples of org.apache.tapestry.Block


        return _overrideSource.hasDisplayBlock(datatype) || _masterSource.hasDisplayBlock(datatype);
    }

    public Block getDisplayBlock(String datatype)
    {
        Block result = _overrideSource.getDisplayBlock(datatype);

        if (result == null)
            result = _masterSource.getDisplayBlock(datatype);

        if (result == null)
View Full Code Here


        return result;
    }

    public Block getEditBlock(String datatype)
    {
        Block result = _overrideSource.getEditBlock(datatype);

        if (result == null)
            result = _masterSource.getEditBlock(datatype);

        if (result == null)
View Full Code Here

     * Invoked from subclasses to do the rendering. The subclass controls the naming convention for locating an
     * overriding Block parameter (it is the name of the property possibly suffixed with a value).
     */
    protected Object renderPropertyValue(MarkupWriter writer, String overrideBlockId)
    {
        Block override = _overrides.getBlockParameter(overrideBlockId);

        if (override != null) return override;

        String datatype = _model.getDataType();

View Full Code Here

    }


    public Block getBlockForColumn()
    {
        Block override = _overrides.getBlockParameter(_columnModel.getId() + "Header");

        if (override != null) return override;

        return _standardHeader;
    }
View Full Code Here

        _propertyEditModel = _model.get(propertyName);

        _blockForProperty = null;

        Block override = _resources.getBlockParameter(_propertyEditModel.getId());

        if (override != null)
        {
            _blockForProperty = override;
            return;
View Full Code Here

    private boolean _mustPopEnvironment;

    Object beginRender(MarkupWriter writer)
    {
        Block override = _resources.getBlockParameter(_model.getId() + "Cell");

        if (override != null) return override;

        String datatype = _model.getDataType();

        if (_beanBlockSource.hasDisplayBlock(datatype))
        {
            PropertyDisplayContext context = new PropertyDisplayContext()
            {
                public Messages getContainerMessages()
                {
                    return GridCell.this.getContainerMessages();
                }

                public Object getPropertyValue()
                {
                    return readPropertyForRow();
                }
            };

            _environment.push(PropertyDisplayContext.class, context);
            _mustPopEnvironment = true;

            return _beanBlockSource.getDisplayBlock(datatype);
        }

        Block block = _gridCellResources.findBlock(datatype);

        if (block != null) return block;

        Object value = _model.getConduit().get(_row);
View Full Code Here

        queue.push(this);
    }

    public Block getBlock(String id)
    {
        Block result = findBlock(id);

        if (result == null)
            throw new BlockNotFoundException(StructureMessages.blockNotFound(_completeId, id),
                    getLocation());
View Full Code Here

TOP

Related Classes of org.apache.tapestry.Block

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.