Package FLOTF
Class NSNScrape
- java.lang.Object
-
- FLOTF.NSNScrape
-
public class NSNScrape extends java.lang.ObjectThis class holds the logic to webscrape NSNCenter.com for National Stock Numbers- Author:
- Bernard Chan, Sonali Loomba
-
-
Field Summary
Fields Modifier and Type Field Description private static java.util.ArrayList<java.lang.String[]>scrapedNSNsStores the scraped National Stock Number information
-
Constructor Summary
Constructors Constructor Description NSNScrape()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidclearNSNList()ClearsscrapedNSNsto enable cancel button functionality and the user to navigate back and forth in the GUI without the logic breakingstatic java.util.ArrayList<java.lang.String[]>getScrapedNSNs()GetsscrapedNSNsstatic voidwebScrape(Part part)Scrapes NSNCenter.com for a particular part and stores all the possible corresponding National Stock Numbers in the scrapedNSNs
-
-
-
Method Detail
-
webScrape
public static void webScrape(Part part) throws java.io.IOException
Scrapes NSNCenter.com for a particular part and stores all the possible corresponding National Stock Numbers in the scrapedNSNs- Parameters:
part- that is being looked for while webscraping- Throws:
java.io.IOException- if connecting to the webpage fails
-
clearNSNList
public static void clearNSNList()
ClearsscrapedNSNsto enable cancel button functionality and the user to navigate back and forth in the GUI without the logic breaking
-
getScrapedNSNs
public static java.util.ArrayList<java.lang.String[]> getScrapedNSNs()
GetsscrapedNSNs- Returns:
- an Arraylist specifying the scraped NSNs
-
-