Examples of IPropertiesFactory


Examples of org.apache.wicket.resource.IPropertiesFactory

    {
      return null;
    }

    // Load the properties associated with the path
    IPropertiesFactory propertiesFactory = Application.get()
      .getResourceSettings()
      .getPropertiesFactory();

    while (true)
    {
      Package pkg = clazz.getPackage();
      String packageName = (pkg == null) ? "" : pkg.getName();
      packageName = packageName.replace('.', '/');

      do
      {
        // Create the base path
        String path = filename;
        if (packageName.length() > 0)
        {
          path = packageName + "/" + path;
        }

        // Iterator over all the combinations
        ResourceNameIterator iter = newResourceNameIterator(path, locale, style, variation);
        while (iter.hasNext())
        {
          String newPath = iter.next();

          Properties props = propertiesFactory.load(clazz, newPath);
          if (props != null)
          {
            // Lookup the value
            String value = props.getString(key);
            if (value != null)
View Full Code Here

Examples of org.apache.wicket.resource.IPropertiesFactory

      log.debug("key: '" + key + "'; class: '" + clazz.getName() + "'; locale: '" + locale +
        "'; Style: '" + style + "'; Variation: '" + variation + '\'');
    }

    // Load the properties associated with the path
    IPropertiesFactory propertiesFactory = getPropertiesFactory();
    while (true)
    {
      // Create the base path
      String path = clazz.getName().replace('.', '/');

      // Iterator over all the combinations
      ResourceNameIterator iter = newResourceNameIterator(path, locale, style, variation);
      while (iter.hasNext())
      {
        String newPath = iter.next();

        Properties props = propertiesFactory.load(clazz, newPath);
        if (props != null)
        {
          // Lookup the value
          String value = props.getString(key);
          if (value != null)
View Full Code Here

Examples of org.apache.wicket.resource.IPropertiesFactory

      log.debug("key: '" + key + "'; class: '" + clazz.getName() + "'; locale: '" + locale +
        "'; Style: '" + style + "'; Variation: '" + variation + '\'');
    }

    // Load the properties associated with the path
    IPropertiesFactory propertiesFactory = getPropertiesFactory();
    while (true)
    {
      // Create the base path
      String path = clazz.getName().replace('.', '/');

      // Iterator over all the combinations
      IResourceNameIterator iter = newResourceNameIterator(path, locale, style, variation);
      while (iter.hasNext())
      {
        String newPath = iter.next();

        Properties props = propertiesFactory.load(clazz, newPath);
        if (props != null)
        {
          // Lookup the value
          String value = props.getString(key);
          if (value != null)
View Full Code Here

Examples of org.apache.wicket.resource.IPropertiesFactory

      log.debug("key: '" + key + "'; class: '" + clazz.getName() + "'; locale: '" + locale +
        "'; Style: '" + style + "'");
    }

    // Load the properties associated with the path
    IPropertiesFactory propertiesFactory = getPropertiesFactory();
    while (true)
    {
      // Create the base path
      String path = clazz.getName().replace('.', '/');

      // Iterator over all the combinations
      ResourceNameIterator iter = new ResourceNameIterator(path, style, locale, null);
      while (iter.hasNext())
      {
        String newPath = iter.next();

        final Properties props = propertiesFactory.load(clazz, newPath);
        if (props != null)
        {
          // Lookup the value
          String value = props.getString(key);
          if (value != null)
View Full Code Here

Examples of org.apache.wicket.resource.IPropertiesFactory

    {
      return null;
    }

    // Load the properties associated with the path
    IPropertiesFactory propertiesFactory = Application.get()
      .getResourceSettings()
      .getPropertiesFactory();

    while (true)
    {
      Package pkg = clazz.getPackage();
      String packageName = (pkg == null) ? "" : pkg.getName();
      packageName = packageName.replace('.', '/');

      do
      {
        // Create the base path
        String path = filename;
        if (packageName.length() > 0)
        {
          path = packageName + "/" + path;
        }

        // Iterator over all the combinations
        ResourceNameIterator iter = newResourceNameIterator(path, locale, style, variation);
        while (iter.hasNext())
        {
          String newPath = iter.next();

          Properties props = propertiesFactory.load(clazz, newPath);
          if (props != null)
          {
            // Lookup the value
            String value = props.getString(key);
            if (value != null)
View Full Code Here

Examples of org.apache.wicket.resource.IPropertiesFactory

      log.debug("key: '" + key + "'; class: '" + clazz.getName() + "'; locale: '" + locale +
        "'; Style: '" + style + "'; Variation: '" + variation + "'");
    }

    // Load the properties associated with the path
    IPropertiesFactory propertiesFactory = getPropertiesFactory();
    while (true)
    {
      // Create the base path
      String path = clazz.getName().replace('.', '/');

      // Iterator over all the combinations
      ResourceNameIterator iter = newResourceNameIterator(path, locale, style, variation);
      while (iter.hasNext())
      {
        String newPath = iter.next();

        Properties props = propertiesFactory.load(clazz, newPath);
        if (props != null)
        {
          // Lookup the value
          String value = props.getString(key);
          if (value != null)
View Full Code Here

Examples of org.apache.wicket.resource.IPropertiesFactory

   */
  public void testRenderHomePage_2() throws Exception
  {
    // Avoid the conflict by limiting the search for properties files
    // to *.properties
    IPropertiesFactory myFac = new MyPropertiesFactory(tester.getApplication());
    tester.getApplication().getResourceSettings().setPropertiesFactory(myFac);

    executeTest(TestPage_1.class, "TestPageExpectedResult_1.xml");
  }
View Full Code Here

Examples of org.apache.wicket.resource.IPropertiesFactory

  /**
   * @throws Exception
   */
  public void testDisabledCache() throws Exception
  {
    IPropertiesFactory myFac = new DisabledCachePropertiesFactory(tester.getApplication());
    tester.getApplication().getResourceSettings().setPropertiesFactory(myFac);

    executeTest(TestPage_1.class, "TestPageExpectedResult_1.xml");

    myFac.clearCache();
  }
View Full Code Here

Examples of org.apache.wicket.resource.IPropertiesFactory

    String packageName = clazz.getPackage().getName();
    packageName = packageName.replace('.', '/');

    // Load the properties associated with the path
    IPropertiesFactory propertiesFactory = Application.get()
      .getResourceSettings()
      .getPropertiesFactory();

    while (packageName.length() > 0)
    {
      // Create the base path
      String path = packageName + "/" + filename;

      // Iterator over all the combinations
      ResourceNameIterator iter = new ResourceNameIterator(path, style, locale, null);
      while (iter.hasNext())
      {
        String newPath = iter.next();

        final Properties props = propertiesFactory.load(clazz, newPath);
        if (props != null)
        {
          // Lookup the value
          String value = props.getString(key);
          if (value != null)
View Full Code Here

Examples of org.apache.wicket.resource.IPropertiesFactory

    {
      return null;
    }

    // Load the properties associated with the path
    IPropertiesFactory propertiesFactory = Application.get()
      .getResourceSettings()
      .getPropertiesFactory();

    while (true)
    {
      // Create the base path
      String path = clazz.getName().replace('.', '/');

      // Iterator over all the combinations
      ResourceNameIterator iter = new ResourceNameIterator(path, style, locale,
        "properties,xml");
      while (iter.hasNext())
      {
        String newPath = (String)iter.next();

        final Properties props = propertiesFactory.load(clazz, newPath);
        if (props != null)
        {
          // Lookup the value
          String value = props.getString(key);
          if (value != null)
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.