'Returns the duration of the next maintenance window.
:return:  Duration of next maintenance window (or None if no
maintenance windows are scheduled)
:rtype:   :class:`datetime.timedelta` or ``None``'

def _get_next_mw_duration(self):

    next_window = self._get_next_maint()
    if (not next_window):
        return None
    next_begin = timestamp_to_datetime(next_window['beginTime'])
    next_end = timestamp_to_datetime(next_window['endTime'])
    return (next_end - next_begin)
