private static void scrapeLink(String episodeURL,int episodeNum,Series series){
  StringBuilder episodeTextBuffer=new StringBuilder("Episode Number: " + episodeNum + "<br>");
  String episodeText;
  URL url;
  InputStream is=null;
  BufferedReader br;
  String line;
  try {
    url=new URL(episodeURL);
    is=url.openStream();
    br=new BufferedReader(new InputStreamReader(is));
    while ((line=br.readLine()) != null) {
      episodeTextBuffer.append(line);
      episodeTextBuffer.append(" ");
    }
  }
 catch (  IOException ioe) {
    ioe.printStackTrace();
  }
 finally {
    try {
      if (is != null)       is.close();
    }
 catch (    IOException ioe) {
    }
  }
  episodeText=episodeTextBuffer.toString();
  episodeText=episodeText.replaceAll("\\n","");
  episodeText=episodeText.replaceAll("<br>","\n");
  episodeText=episodeText.replaceAll("</div>(.*\n)*.*","\n");
  episodeText=episodeText.replaceAll("<[^>]*>","\n");
  episodeText=episodeText.replace("&nbsp","");
  episodeText=episodeText.replaceAll("\\n+\\s*","\n");
  episodeText=episodeText.replaceAll("\\n{2,}","\n");
  episodeText=episodeText.replaceAll(":;",": ");
  saveEpisode(episodeText,episodeNum,series);
}

private static void scrapeLink ( String episodeURL , int episodeNum , Series series ) { StringBuilder episodeTextBuffer = new StringBuilder ( "Episode Number: " + episodeNum + "<br>" ) ; String episodeText ; URL url ; InputStream is = null ; BufferedReader br ; String line ; try { url = new URL ( episodeURL ) ; is = url . openStream ( ) ; br = new BufferedReader ( new InputStreamReader ( is ) ) ; while ( ( line = br . readLine ( ) ) != null ) { episodeTextBuffer . append ( line ) ; episodeTextBuffer . append ( " " ) ; } } catch ( IOException ioe ) { ioe . printStackTrace ( ) ; } finally { try { if ( is != null ) is . close ( ) ; } catch ( IOException ioe ) { } } episodeText = episodeTextBuffer . toString ( ) ; episodeText = episodeText . replaceAll ( "\\n" , "" ) ; episodeText = episodeText . replaceAll ( "<br>" , "\n" ) ; episodeText = episodeText . replaceAll ( "</div>(.*\n)*.*" , "\n" ) ; episodeText = episodeText . replaceAll ( "<[^>]*>" , "\n" ) ; episodeText = episodeText . replace ( "&nbsp" , "" ) ; episodeText = episodeText . replaceAll ( "\\n+\\s*" , "\n" ) ; episodeText = episodeText . replaceAll ( "\\n{2,}" , "\n" ) ; episodeText = episodeText . replaceAll ( ":;" , ": " ) ; saveEpisode ( episodeText , episodeNum , series ) ; }
scrape the given episode using the provided information
