Code example for LinkedHashSet

Methods: addAll, size, toArray

0
    final AuthenticationData data = localStorage.get(url);
    if (data == null)
    { 
      return backend.getDefinedOptions(url);
    } 
    final LinkedHashSet<String> keys = new LinkedHashSet<String>();
    keys.addAll(Arrays.asList(backend.getDefinedOptions(url)));
    keys.addAll(Arrays.asList(data.getDefinedOptions()));
    return keys.toArray(new String[keys.size()]);
  } 
 
  public String[] getKnownURLs()
  { 
    final LinkedHashSet<String> keys = new LinkedHashSet<String>();
    keys.addAll(Arrays.asList(backend.getKnownURLs()));
    keys.addAll(Arrays.asList(localStorage.keySet().toArray(new String[localStorage.size()])));
    return keys.toArray(new String[keys.size()]);
  } 
 
 
  public void addCredentials(final String url,