'Initialize a KeyRangeItem object.
Args:
request_manager: A RequestManager instance.
progress_queue: A queue used for tracking progress information.
kind: The kind of entities for this range.
key_range: A KeyRange instance for this work item.
progress_key: The key for this range within the progress database.
state: The initial state of this range.
first: boolean, default False, whether this is the first WorkItem
of its kind.'

def __init__(self, request_manager, progress_queue, kind, key_range, progress_key=None, state=STATE_READ, first=False):

    _WorkItem.__init__(self, progress_queue, key_range.key_start, key_range.key_end, ExportStateName, state=state, progress_key=progress_key)
    assert KeyLEQ(key_range.key_start, key_range.key_end), ('%s    not    less    than    %s' % (repr(key_range.key_start), repr(key_range.key_end)))
    self.request_manager = request_manager
    self.kind = kind
    self.key_range = key_range
    self.download_result = None
    self.count = 0
    self.key_start = key_range.key_start
    self.key_end = key_range.key_end
    self.first = first
