Package org.apache.tapestry5.ioc.internal.util

Examples of org.apache.tapestry5.ioc.internal.util.TapestryException


        try
        {
            return factory.newBinding(interner.intern(description), container, component, subexpression, location);
        } catch (Exception ex)
        {
            throw new TapestryException(String.format("Could not convert '%s' into a component parameter binding: %s", expression, InternalUtils.toMessage(ex)), location, ex);
        }
    }
View Full Code Here


        String childId = child.getId();

        for (ComponentPageElement existing : children)
        {
            if (existing.getId().equalsIgnoreCase(childId))
                throw new TapestryException(StructureMessages.duplicateChildComponent(this, childId), child,
                        new TapestryException(StructureMessages.originalChildComponent(this, childId,
                                existing.getLocation()), existing, null));
        }

        children.add(child);
    }
View Full Code Here

    public Component getMixinByClassName(String mixinClassName)
    {
        Component result = mixinForClassName(mixinClassName);

        if (result == null)
            throw new TapestryException(StructureMessages.unknownMixin(completeId, mixinClassName), getLocation(), null);

        return result;
    }
View Full Code Here

                if (callback.isEventAborted())
                    return;
            }
        } catch (RuntimeException ex)
        {
            throw new TapestryException(ex.getMessage(), getLocation(), ex);
        }
    }
View Full Code Here

            addUnboundParameterNames(name, unbound, mixinIdToComponentResources.get(name));
        }

        if (!unbound.isEmpty())
        {
            throw new TapestryException(StructureMessages.missingParameters(unbound, this), this, null);
        }
    }
View Full Code Here

    {
        if (blocks == null)
            blocks = NamedSet.create();

        if (!blocks.putIfNew(blockId, block))
            throw new TapestryException(StructureMessages.duplicateBlock(this, blockId), block, null);
    }
View Full Code Here

            tokenStream.parse();

            return toDynamicTemplate(root());
        } catch (Exception ex)
        {
            throw new TapestryException(String.format("Failure parsing dynamic template %s: %s", resource,
                    InternalUtils.toMessage(ex)), tokenStream.getLocation(), ex);
        }
    }
View Full Code Here

                    Block block = delegate.getBlock(blockId);

                    queue.push((RenderCommand) block);
                } catch (Exception ex)
                {
                    throw new TapestryException(String.format(
                            "Exception rendering block '%s' as part of dynamic template: %s", blockId,
                            InternalUtils.toMessage(ex)), location, ex);
                }
            }
        };
View Full Code Here

                    Object boundValue = binding.get();

                    return boundValue == null ? null : boundValue.toString();
                } catch (Throwable t)
                {
                    throw new TapestryException(InternalUtils.toMessage(t), location, t);
                }
            }
        };
    }
View Full Code Here

            }
            // This used to be RuntimeException, but with TAP5-1508 changes to RenderPhaseMethodWorker, we now
            // let ordinary exceptions bubble up as well.
            catch (Exception ex)
            {
                throw new TapestryException(ex.getMessage(), getLocation(), ex);
            }

        }
View Full Code Here

TOP

Related Classes of org.apache.tapestry5.ioc.internal.util.TapestryException

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.