Module util
[hide private]
[frames] | no frames]

Module util

source code

This module has utility functions that work over the database

Functions [hide private]
 
SearengineQueries() source code
 
__calcWeekDates__()
A funtion made for the internal use.
source code
 
deadLinks(hostname)
Gives list of dead links at hostname in tuple(linked_by,linked_to) format
source code
 
getHitsByPage(page)
Gives the list of number of hits to the particular page in the log file in last ten weeks
source code
 
lastRecordDate()
Get the date of most recent entry in the logfile
source code
 
topHits(count=10)
Returns list of top *count* tuples in tuple(page,hits) format
source code
Variables [hide private]
  __package__ = None
Function Details [hide private]

__calcWeekDates__()

source code 

A funtion made for the internal use. It created the list of dates having diffrence of a week

Returns:
list

deadLinks(hostname)

source code 

Gives list of dead links at hostname in tuple(linked_by,linked_to) format

Parameters:
  • hostname - hostname of the machine which created the the log file in http://hostname/ format
Returns:
list

getHitsByPage(page)

source code 

Gives the list of number of hits to the particular page in the log file in last ten weeks

Parameters:
  • page - absolute address of the required page
Returns:
list

lastRecordDate()

source code 

Get the date of most recent entry in the logfile

Returns:
string

topHits(count=10)

source code 

Returns list of top *count* tuples in tuple(page,hits) format

Parameters:
  • count - size of list to be returned
Returns:
list