Package java.util

Examples of java.util.TreeSet.toArray()


      }
      newsb.append(cl);
    }// end of for
    newsb.append(" ) ");
    String finalSql = " Select " + primaryType + " from ";
    Object[] objArray = globalSet.toArray();
    for (int j = 0; j < objArray.length; j++)
    {
      finalSql = finalSql + " " + (String)objArray[j];
      if (j < objArray.length - 1)
      {
View Full Code Here


                    throw new Error(errorMessage);
                }
            }
        }

        return (BeanProperty[]) propSet.toArray(new BeanProperty[0]);
    }

    public PkMetadata collectPkHierarchy(JavaClass javaClass) {
        PkMetadata retVal = null;
View Full Code Here

            tree.add(adds[i].getName());
        }
        for (int i = 0; i < keeps.length; i++) {
            tree.add(keeps[i].getName());
        }
        String[] refs = (String[])tree.toArray(new String[tree.size()]);
       
        // replace private method to return binding classes blob
        m_factoryClass.deleteMethod(CLASSLIST_METHOD_NAME,
            CLASSLIST_METHOD_SIGNATURE);
        MethodBuilder mb = new ExceptionMethodBuilder(CLASSLIST_METHOD_NAME,
View Full Code Here

      log.info("retreiving '" + files.length + "' manual transferred data files from directory '" + subDir.getAbsolutePath() + "'");
      // alphabetical order guarantees correct sequence.
      TreeSet set = new TreeSet();
      for (int i=0; i < files.length; i++)
         set.add(files[i]);
      files = (String[])set.toArray(new String[set.size()]);
     
      for (int i=0; i < files.length; i++) {
         File file = new File(subDir, files[i]);
         if (!file.exists())
            throw new Exception("The entry nr. '" + i + "': file '" + file.getAbsolutePath() + "' does not exist");
View Full Code Here

    SortedSet set = new TreeSet(Util.bundleIdComparator);
    for(int i = 0; i < bl.length; i++) {
      set.add(bl[i]);
    }

    set.toArray(bl);

    return bl;
  }

View Full Code Here

            }
        });

        collect_interfaces(s, c);
        remote_interfaces = new Class[s.size()];
        s.toArray(remote_interfaces);
        return remote_interfaces;
    }

    /** Read an instance of this value from a CDR stream */
    public Object read(org.omg.CORBA.portable.InputStream in) {
View Full Code Here

           
            if("tags".equals(pageRequest.getContext())) {
                key.append("/tags/");
                if(pageRequest.getTags() != null && pageRequest.getTags().size() > 0) {
                    Set ordered = new TreeSet(pageRequest.getTags());
                    String[] tags = (String[]) ordered.toArray(new String[ordered.size()]);
                    key.append(Utilities.stringArrayToString(tags,"+"));
                }
            }
        }
       
View Full Code Here

            key.append("/").append(cat);
        }
       
        if(feedRequest.getTags() != null && feedRequest.getTags().size() > 0) {
          Set ordered = new TreeSet(feedRequest.getTags());
          String[] tags = (String[]) ordered.toArray(new String[ordered.size()])
          key.append("/tags/").append(Utilities.stringArrayToString(tags,"+"));
        }       
       
        if(feedRequest.getLocale() != null) {
            key.append("/").append(feedRequest.getLocale());
View Full Code Here

        } else {
            log.debug("Sending notification email only to weblog owner");
        }
       
        // Form array of commenter addrs
        String[] commenterAddrs = (String[])subscribers.toArray(new String[0]);
       
        //------------------------------------------
        // --- Form the messages to be sent -
        // Build separate owner and commenter (aka subscriber) messages
       
View Full Code Here

                        localeSet.add( name );
                    }
                }
            }

            locales = ( String[] ) localeSet.toArray( new String[localeSet.size()] );
        }

        return ( locales.length == 0 ) ? null : locales;
    }
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.