-- | Builds the webGraph of a given pool of pages
buildWebGraph :: [(URI,HTMLDoc,[URI])] -> WG.WebG
buildWebGraph  = g0 WG.empty . map (\(uri,doc,links) -> (uri,fetchKeywords doc ranks,links))
  where
    g0 webG [] = webG
    g0 webG ((uri,kw,links):rest) = g0 (WG.insert uri kw links webG) rest
   

-- | Fetches all the keywords of a page and assigns them a value 
buildWebGraph :: [(URI,HTMLDoc,[URI])] -> WG.WebG
buildWebGraph  = g0 WG.empty . map (\(uri,doc,links) -> (uri,fetchKeywords doc ranks,links))
  where
    g0 webG [] = webG
    g0 webG ((uri,kw,links):rest) = g0 (WG.insert uri kw links webG) rest
   

-- | Fetches all the keywords of a page and assigns them a value 
buildWebGraph  = g0 WG.empty . map (\(uri,doc,links) -> (uri,fetchKeywords doc ranks,links))
  where
    g0 webG [] = webG
    g0 webG ((uri,kw,links):rest) = g0 (WG.insert uri kw links webG) rest
   

-- | Fetches all the keywords of a page and assigns them a value 