vlivepy.Upcoming¶
-
class
vlivepy.
Upcoming
(refresh_rate: float = 5, show_vod: bool = True, show_upcoming_vod: bool = True, show_upcoming_live: bool = True, show_live: bool = True)[source]¶ Bases:
object
This is the object represents a upcoming list of VLIVE.
This object doesn’t use endpoint API but use parsing upcoming webpage. This use refresh rate to caching result. Set
refresh_rate
to 0 to disable cachingSee also
This object mainly returns list of
vlivepy.parser.UpcomingVideo
. Check docs!- Parameters
refresh_rate (
float
, optional) – Unique id of post to load. Also, the object can be initialized by video_seq. Defaults to 5show_vod (
bool
, optional) – Add VOD to upcoming list, defaults to True.show_upcoming_vod (
bool
, optional) – Add reserved VOD to upcoming list, defaults to True.show_upcoming_live (
bool
, optional) – Add reserved Live to upcoming list, defaults to True.show_live (
bool
, optional) – Add on air live to upcoming list, defaults to True.
-
refresh_rate
¶ Optional. Unique id of post to load. Also, the object can be initialized by video_seq. Defaults to 5
- Type
float
-
show_vod
¶ Optional. Add VOD to upcoming list, defaults to True.
- Type
bool
-
show_upcoming_vod
¶ Optional. Add reserved VOD to upcoming list, defaults to True.
- Type
bool
-
show_upcoming_live
¶ Optional. Add reserved Live to upcoming list, defaults to True.
- Type
bool
-
show_live
¶ Optional. Add on air live to upcoming list, defaults to True.
- Type
bool
-
load
(date: Optional[str], show_vod: Optional[bool] = None, show_upcoming_vod: Optional[bool] = None, show_upcoming_live: Optional[bool] = None, show_live: Optional[bool] = None, silent: Optional[bool] = False) → Optional[List[vlivepy.upcoming.UpcomingVideo]][source]¶ Get upcoming list data with specific date
Note
Use
upcoming()
instead of using this function to load current upcoming.- Parameters
date (
bool
) – Specify date to load upcoming.show_vod (
bool
, optional) – Add VOD to upcoming list, defaults toself.show_vod
show_upcoming_vod (
bool
, optional) – Add reserved VOD to upcoming list, defaults toself.show_upcoming_vod
show_upcoming_live (
bool
, optional) – Add reserved Live to upcoming list, defaults toself.show_upcoming_live
show_live (
bool
, optional) – Add on air live to upcoming list, defaults toself.show_live
silent (
bool
, optional) – Return None instead of raising exception, defaults to False.
- Returns
List of
vlivepy.parser.UpcomingVideo
-
refresh
(force: bool = False) → None[source]¶ Refresh self data
- Parameters
force (
bool
, optional) – Force refresh with ignoring refresh rate, defaults to False.
-
upcoming
(force=False, show_vod: Optional[bool] = None, show_upcoming_vod: Optional[bool] = None, show_upcoming_live: Optional[bool] = None, show_live: Optional[bool] = None) → List[vlivepy.upcoming.UpcomingVideo][source]¶ Upcoming list with cache life check
- Parameters
force (
bool
, optional) – Force refresh with ignoring refresh rate, defaults to False.show_vod (
bool
, optional) – Add VOD to upcoming list, defaults toself.show_vod
show_upcoming_vod (
bool
, optional) – Add reserved VOD to upcoming list, defaults toself.show_upcoming_vod
show_upcoming_live (
bool
, optional) – Add reserved Live to upcoming list, defaults toself.show_upcoming_live
show_live (
bool
, optional) – Add on air live to upcoming list, defaults toself.show_live
- Returns
List of
vlivepy.parser.UpcomingVideo