Package barrysoft.web

Examples of barrysoft.web.WebDownloader


  public final String postSite = "http://www.snee.com/xml/crud/posttest.cgi";
 
  @Test
  public void testPost() {
   
    WebDownloader downloader = new WebDownloader();
    downloader.addFormElement("fname", "Masked");
    downloader.addFormElement("lname", "Man");
    downloader.setMethod(WebDownloader.METHOD_POST);
   
    try {
      downloader.setUrl(postSite);
      String source = new String(downloader.download());
     
      if (source.contains("First name: \"Masked\""))
        assertTrue(true);
      else
        fail("Can't find the string:\n\n"+source);
View Full Code Here


    archiveHandlers = ArchiveHandlerManager.getDefaultHandlers();
    updateValidators = UpdateValidatorsManager.getDefaultValidators();
   
    updatesExecutor = Executors.newSingleThreadExecutor();
   
    downloader = new WebDownloader();
    downloader.addProgressListener(this);
   
    ResourcesManager.setResources(new UpdaterResources());
  }
View Full Code Here

TOP

Related Classes of barrysoft.web.WebDownloader

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.