'Get a database.item object by fetching relevant HTTP information
from the document pointed to by the given url.'

@staticmethod
def _get_item(url):

    try:
        info = urllib2.urlopen(url).info()
    except IOError as err:
        print ('WARNING:    %s' % err)
        return None
    size = info.get('content-length')
    if size:
        size = int(size)
    else:
        size = (-1)
    timestamp = int(time.mktime(info.getdate('date')))
    if (not timestamp):
        timestamp = 0
    return database.item(url, size, timestamp)
