Package java.util

Examples of java.util.Hashtable.keys()


      try {
        Hashtable l = getActiveLocalTunnels();

        ByteArrayWriter msg = new ByteArrayWriter();
        msg.writeInt(l.size());
        for (Enumeration e = l.keys(); e.hasMoreElements();) {
          msg.writeInt(((Integer) e.nextElement()).intValue());
        }

        request.setRequestData(msg.toByteArray());
        return true;
View Full Code Here


            // Iterate through all the profiles and load the proxy infos from
            // the prefs.js file

            File prefsJS;
            String profileName;
            for (Enumeration e = profiles.keys(); e.hasMoreElements();) {
                profileName = (String) e.nextElement();
                prefsJS = new File((File) profiles.get(profileName), "prefs.js"); //$NON-NLS-1$
                Properties props = new Properties();
                reader = null;
                try {
View Full Code Here

            long catid = storeCategory(confoid, categoryName);
            oldCategories.remove(new Long(catid));
            storeProperties(catid, configuration.getCategory(categoryName));
        }
        // Delete old Categories rested in oldCategories
        Enumeration enumCat = oldCategories.keys();
        while (enumCat.hasMoreElements()) {
            Long catid = (Long)enumCat.nextElement();
            deleteCategory(catid.longValue(),oldCategories.get(catid).toString());
        }
       
View Full Code Here

        for (int i = 0; i < variableNameArray.length; i++) {
            String variableName = variableNameArray[i];
            long varoid= storeVariable(confoid, variableName, configuration.getVariable(variableName));
            oldVariables.remove(new Long(varoid));
        }
        Enumeration enumVar = oldVariables.keys();
        while (enumVar.hasMoreElements()) {
            Long varoid = (Long)enumVar.nextElement();
            deleteVariable(varoid.longValue(),oldVariables.get(varoid).toString());
        }
       
View Full Code Here

        while(enm.hasMoreElements()) {
            String propertyName = (String)enm.nextElement();
            long propoid = storeProperty(catid, propertyName, category.getProperty(propertyName));
            oldProperties.remove(new Long(propoid));
        }
        Enumeration enumeration = oldProperties.keys();
       
        while (enumeration.hasMoreElements()) {
            Long propoid = (Long)enumeration.nextElement();
            deleteProperty(propoid.longValue(),oldProperties.get(propoid).toString());
        }
View Full Code Here

    if (null!=attributePropertyPrefix) {
      int       prefixLength = attributePropertyPrefix.length();
      Project   project      = getProject();
      Manifest.Section mainS = mf.getMainSection();
      Hashtable properties   = project.getProperties();
      for (Enumeration pe = properties.keys(); pe.hasMoreElements();) {
        String key = (String) pe.nextElement();
        if (key.startsWith(attributePropertyPrefix)) {
          String attrName  = key.substring(prefixLength);
          String attrValue = (String) properties.get(key);
          if(!BUNDLE_EMPTY_STRING.equals(attrValue)) {
View Full Code Here

                  + "are valid.");
        } finally {
          if (!valid) {
            // Rollback. E.g., configCollection = rollBack;
            synchronized (configCollection) {
              for (Enumeration keys = rollBack.keys(); keys.hasMoreElements();) {
                final Object key = keys.nextElement();
                final Object value = rollBack.remove(key);
                configCollection.put(key, value);
              }
            }
View Full Code Here

      // way should not be needed, since the body may contain UTF-8
      // chars as long as the correct character encoding has been used
      // for the post.
      Hashtable p = HttpUtils.parseQueryString(paramData);
      // Merge posted paramters with URL parameters.
      Enumeration e = p.keys();
      while (e.hasMoreElements()) {
        String key = (String) e.nextElement();
        String[] val = (String[]) p.get(key);
        String[] valArray;
        String oldVals[] = (String[]) parameters.get(key);
View Full Code Here

          throw new Exception(res.getErrorMessage());
        }

        // insert vat rows in sale vat register...
        ArrayList vatRows = new ArrayList();
        Enumeration en = vats.keys();
        while(en.hasMoreElements())
          vatRows.add(vats.get(en.nextElement()));
        res = vatRegisterAction.insertVatRows(vatRows,serverLanguageId,username);
        if (res.isError()) {
          throw new Exception(res.getErrorMessage());
View Full Code Here

      }
      en = actsTaxableIncomeRows.keys();
      while(en.hasMoreElements()) {
        taxableIncomeRows.add( actsTaxableIncomeRows.get(en.nextElement()) );
      }
      en = chargesTaxableIncomeRows.keys();
      while(en.hasMoreElements()) {
        taxableIncomeRows.add( chargesTaxableIncomeRows.get(en.nextElement()) );
      }

      return new VOListResponse(taxableIncomeRows,false,taxableIncomeRows.size());
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.