Package org.apache.hivemind

Examples of org.apache.hivemind.ClassResolver


     * descriptors for non-standard locations, you must create
     * a RegistryBuilder instance yourself.
     */
    public static Registry constructDefaultRegistry()
    {
        ClassResolver resolver = new DefaultClassResolver();
        RegistryBuilder builder = new RegistryBuilder();

        builder.processModules(resolver);

        return builder.constructRegistry(Locale.getDefault());
View Full Code Here


     * the master module descriptor (i.e., those visible on the classpath).
     * Files are resolved using {@link HiveMindTestCase#getResource(String)}.
     */
    protected Registry buildFrameworkRegistry(String[] files) throws Exception
    {
        ClassResolver resolver = new DefaultClassResolver();

        RegistryBuilder builder = new RegistryBuilder();

        for (int i = 0; i < files.length; i++)
        {
View Full Code Here

     * they have specific initialization needs, or have nonstandard
     * rules for finding HiveMind module deployment descriptors.
     */
    protected Registry constructRegistry(FilterConfig config)
    {
        ClassResolver resolver = new DefaultClassResolver();
        RegistryBuilder builder = new RegistryBuilder();

        builder.processModules(resolver);

        return builder.constructRegistry(getRegistryLocale());
View Full Code Here

    {
        if (_instanceClass == null)
        {
            try
            {
                ClassResolver resolver = _contributingModule.getClassResolver();

                _instanceClass = resolver.findClass(_instanceClassName);
            }
            catch (Exception ex)
            {
                throw new ApplicationRuntimeException(ex.getMessage(), getLocation(), ex);
            }
View Full Code Here

    protected Class extractClass(Module contributingModule, String inputValue)
    {
        if (HiveMind.isBlank(inputValue))
            return null;

        ClassResolver resolver = contributingModule.getClassResolver();

        return resolver.findClass(inputValue);
    }
View Full Code Here

        Module contributingModule,
        Class propertyType,
        String locator,
        Location location)
    {
        ClassResolver resolver = contributingModule.getClassResolver();

        Class instanceClass = resolver.findClass(locator);

        try
        {
            Object result = instanceClass.newInstance();
View Full Code Here

     * the {@link org.apache.hivemind.Location} of the element is assigned
     * to the object.
     */
    public void begin(SchemaProcessor processor, Element element)
    {
        ClassResolver resolver = processor.getContributingModule().getClassResolver();
        Object object = null;

        try
        {
            Class objectClass = resolver.findClass(_className);

            object = objectClass.newInstance();

        }
        catch (Exception ex)
View Full Code Here

        return _serviceInterface;
    }

    private Class lookupServiceInterface()
    {
        ClassResolver resolver = getModule().getClassResolver();
        Class result = null;

        try
        {
            result = resolver.findClass(_serviceInterfaceName);
        }
        catch (Exception ex)
        {
            throw new ApplicationRuntimeException(
                ImplMessages.badInterface(_serviceInterfaceName, getExtensionPointId()),
View Full Code Here

    protected IRequestCycle newCycle(IComponent component)
    {
        MockControl cyclec = newControl(IRequestCycle.class);
        IRequestCycle cycle = (IRequestCycle) cyclec.getMock();

        ClassResolver cr = (ClassResolver) newMock(ClassResolver.class);

        MockControl infrac = newControl(Infrastructure.class);
        Infrastructure infra = (Infrastructure) infrac.getMock();

        PageRenderSupport prs = (PageRenderSupport) newMock(PageRenderSupport.class);
View Full Code Here

    private IRequestCycle newCycle(IComponent component)
    {
        MockControl cyclec = newControl(IRequestCycle.class);
        IRequestCycle cycle = (IRequestCycle) cyclec.getMock();

        ClassResolver cr = (ClassResolver) newMock(ClassResolver.class);

        MockControl infrac = newControl(Infrastructure.class);
        Infrastructure infra = (Infrastructure) infrac.getMock();

        PageRenderSupport prs = (PageRenderSupport) newMock(PageRenderSupport.class);
View Full Code Here

TOP

Related Classes of org.apache.hivemind.ClassResolver

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.