Package com.lightcrafts.mediax.jai.util

Examples of com.lightcrafts.mediax.jai.util.CaselessStringKey


    // Return only those names which exist in thisNames but not in otherNames
    private Vector removeAll(Hashtable thisHash, Hashtable otherHash) {

  Vector v = new Vector();
  CaselessStringKey thisNameKey;
  for (Enumeration i=thisHash.keys(); i.hasMoreElements(); ) {
      thisNameKey = (CaselessStringKey)i.nextElement();
      if (otherHash.containsKey(thisNameKey))
    continue;
      else
    v.add(thisNameKey.toString());
  }

  return v;
    }
View Full Code Here


  return v;
    }

    private int getIndex(Hashtable h, String s) {
  return ((Integer)h.get(new CaselessStringKey(s))).intValue();
    }
View Full Code Here

    private Vector commonElements(Hashtable thisHash,
          Hashtable otherHash) {

  Vector v = new Vector();
  CaselessStringKey thisNameKey;
  for (Enumeration i=thisHash.keys(); i.hasMoreElements(); ) {
      thisNameKey = (CaselessStringKey)i.nextElement();
      if (otherHash.containsKey(thisNameKey))
    v.add(thisNameKey.toString());
  }

  return v;
    }
View Full Code Here

    private Hashtable hashNames(String paramNames[]) {

  Hashtable h = new Hashtable();
        if (paramNames != null) {
      for (int i=0; i<paramNames.length; i++) {
          h.put(new CaselessStringKey(paramNames[i]), new Integer(i));
      }
        }

        return h;
    }
View Full Code Here

    private Hashtable hashNames(Vector paramNames) {

  Hashtable h = new Hashtable();
        if (paramNames != null) {
      for (int i=0; i<paramNames.size(); i++) {
          h.put(new CaselessStringKey((String)(paramNames.elementAt(i))),
          new Integer(i));
      }
        }

        return h;
View Full Code Here

    private Hashtable hashNames(String paramNames[]) {

        Hashtable h = new Hashtable();
        if (paramNames != null) {
            for (int i=0; i<paramNames.length; i++) {
                h.put(new CaselessStringKey(paramNames[i]), new Integer(i));
            }
        }

        return h;
    }
View Full Code Here

        return h;
    }

    private int getIndex(Hashtable h, String s) {
        return ((Integer)h.get(new CaselessStringKey(s))).intValue();
    }
View Full Code Here

    }

    // A case insensitive containsAll for Hashtables containing Strings
    private boolean containsAll(Hashtable thisHash, Hashtable otherHash) {

        CaselessStringKey thisNameKey;
        for (Enumeration i=thisHash.keys(); i.hasMoreElements(); ) {
            thisNameKey = (CaselessStringKey)i.nextElement();
            if (otherHash.containsKey(thisNameKey) == false)
                return false;
        }
View Full Code Here

                    HashSet wpsNameSet = null;
                    String[] wpsNames = wps.getPropertyNames();
                    if(wpsNames != null) {
                        wpsNameSet = new HashSet();
                        for(int j = 0; j < wpsNames.length; j++) {
                            wpsNameSet.add(new CaselessStringKey(wpsNames[j]));
                        }
                    }

                    // Copy any properties not already defined by the rendering.
                    for(int j = 0; j < propertyNames.length; j++) {
                        String name = propertyNames[j];
                        if(wpsNameSet == null ||
                           !wpsNameSet.contains(new CaselessStringKey(name))) {
                            Object value = getProperty(name);
                            if(value != null &&
                               value != java.awt.Image.UndefinedProperty) {
                                wps.setProperty(name, value);
                            }
View Full Code Here

        }

        synchronized(properties) {
            // Check whether a value mapping exists.
            boolean isMapped =
                properties.containsKey(new CaselessStringKey(propertyName));

            // Retrieve the value.
            Object value = super.getProperty(propertyName);

            // Fire an event if necessary, i.e., if there is an event manager
View Full Code Here

TOP

Related Classes of com.lightcrafts.mediax.jai.util.CaselessStringKey

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.