Package org.apache.wicket.resource.loader

Examples of org.apache.wicket.resource.loader.ComponentStringResourceLoader


   * @param application
   */
  public ResourceSettings(final Application application)
  {
    this.application = application;
    stringResourceLoaders.add(new ComponentStringResourceLoader());
    stringResourceLoaders.add(new PackageStringResourceLoader());
    stringResourceLoaders.add(new ClassStringResourceLoader(application.getClass()));
    stringResourceLoaders.add(new ValidatorStringResourceLoader());
    stringResourceLoaders.add(new InitializerStringResourceLoader(application.getInitializers()));
  }
View Full Code Here


   * @param application
   */
  public ResourceSettings(final Application application)
  {
    this.application = application;
    stringResourceLoaders.add(new ComponentStringResourceLoader());
    stringResourceLoaders.add(new PackageStringResourceLoader());
    stringResourceLoaders.add(new ClassStringResourceLoader(application.getClass()));
    stringResourceLoaders.add(new ValidatorStringResourceLoader());
    stringResourceLoaders.add(new JarStringResourceLoader());
  }
View Full Code Here

   */
  public Settings(final Application application)
  {
    this.application = application;
    this.markupParserFactory = new MarkupParserFactory(application);
    stringResourceLoaders.add(new ComponentStringResourceLoader());
    stringResourceLoaders.add(new ClassStringResourceLoader(this.application.getClass()));
  }
View Full Code Here

   * @param application
   */
  public ResourceSettings(final Application application)
  {
    this.application = application;
    stringResourceLoaders.add(new ComponentStringResourceLoader());
    stringResourceLoaders.add(new PackageStringResourceLoader());
    stringResourceLoaders.add(new ClassStringResourceLoader(application.getClass()));
    stringResourceLoaders.add(new ValidatorStringResourceLoader());
    stringResourceLoaders.add(new InitializerStringResourceLoader(application.getInitializers()));
  }
View Full Code Here

   *            The application that these settings are for
   */
  public Settings(final Application application)
  {
    this.application = application;
    stringResourceLoaders.add(new ComponentStringResourceLoader());
    stringResourceLoaders.add(new PackageStringResourceLoader());
    stringResourceLoaders.add(new ClassStringResourceLoader(this.application.getClass()));
  }
View Full Code Here

   *            The application that these settings are for
   */
  public Settings(final Application application)
  {
    this.application = application;
    stringResourceLoaders.add(new ComponentStringResourceLoader());
    stringResourceLoaders.add(new ClassStringResourceLoader(this.application.getClass()));
  }
View Full Code Here

   * Create and return the loader instance
   * @return The loader instance to test
   */
  protected IStringResourceLoader createLoader()
  {
    return new ComponentStringResourceLoader();
  }
View Full Code Here

    {
      private static final long serialVersionUID = 1L;
    };
    DummyPage page = new DummyPage();
    page.add(c);
    IStringResourceLoader loader = new ComponentStringResourceLoader();
    Assert.assertNull("Missing resource should return null", loader.loadStringResource(c.getClass(), "test.string.bad",
        Locale.getDefault(), null));
  }
View Full Code Here

    DummyPage p = new DummyPage();
    Panel panel = new Panel("panel");
    p.add(panel);
    DummyComponent c = new DummyComponent("hello", application);
    panel.add(c);
    IStringResourceLoader loader = new ComponentStringResourceLoader();
    Assert.assertEquals("Valid resourse string should be found", "Component string", loader
        .loadStringResource(c.getClass(), "component.string", Locale.getDefault(), null));
  }
View Full Code Here

   *
   */
  public void testLoadDirectFromPage()
  {
    DummyPage p = new DummyPage();
    IStringResourceLoader loader = new ComponentStringResourceLoader();
    Assert.assertEquals("Valid resourse string should be found", "Another string", loader.loadStringResource(
        p.getClass(), "another.test.string", Locale.getDefault(), null));
  }
View Full Code Here

TOP

Related Classes of org.apache.wicket.resource.loader.ComponentStringResourceLoader

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.