Package org.apache.myfaces.tobago.internal.context

Examples of org.apache.myfaces.tobago.internal.context.StringValue


    if (bundle != null && propertyKey != null) {
      ClientPropertiesKey clientKey = ClientPropertiesKey.get(facesContext);
      PropertyCacheKey cacheKey = new PropertyCacheKey(clientKey, bundle, propertyKey);
     
      StringValue result = propertyCache.get(cacheKey);
      if (result == null) {
        List properties = getPaths(clientKey, "", PROPERTY, bundle, "", false, true, false, propertyKey, true, false);
        if (properties != null) {
          result = new StringValue((String) properties.get(0));
        } else {
          result = StringValue.NULL;
        }
        propertyCache.put(cacheKey, result);
      }
      return result.getValue();
    }
    return null;
  }
View Full Code Here


    if (bundle != null && propertyKey != null) {

      ClientPropertiesKey clientKey = ClientPropertiesKey.get(FacesContext.getCurrentInstance());
      PropertyCacheKey cacheKey = new PropertyCacheKey(clientKey, bundle, propertyKey);

      StringValue result = propertyCache.get(cacheKey);
      if (result == null) {
        List properties = getPaths(clientKey, "", PROPERTY, bundle, "", false, true, false, propertyKey, true, true);
        if (properties != null) {
          result = new StringValue((String) properties.get(0));
        } else {
          result = StringValue.NULL;
        }
        propertyCache.put(cacheKey, result);
      }
      return result.getValue();
    }
    return null;
  }
View Full Code Here

      }

      ClientPropertiesKey clientKey = ClientPropertiesKey.get(facesContext);
      ImageCacheKey cacheKey = new ImageCacheKey(clientKey, name);

      StringValue result = imageCache.get(cacheKey);
      if (result == null) {
        List paths = getPaths(clientKey, "", null, name.substring(0, dot),
            name.substring(dot), false, true, true, null, true, ignoreMissing);
        if (paths != null) {
          result = new StringValue((String) paths.get(0));
        } else {
          result = StringValue.NULL;
        }
        imageCache.put(cacheKey, result);
      }
      if (LOG.isDebugEnabled()) {
        if (result.getValue() == null) {
          LOG.debug("Can't find image for \"{}\"", name);
        }
      }

      return result.getValue();
    }

    return null;
  }
View Full Code Here

TOP

Related Classes of org.apache.myfaces.tobago.internal.context.StringValue

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.