Wish File Set
The WishFileSet class represents a Wish file set.
- class newsbinpro_client.wishfileset.WishFileSet(data: str)
Bases:
objectRepresents a file set with metadata such as ID, subject, file size, timestamp, poster, download path, status string, file count, and par count, parsed from a tab-delimited input string.
- Attributes:
item_id (int): Identifier of the file set. subject (str): The subject or title of the file set. file_size (int): The size of the file set in bytes. time_stamp (datetime): The timestamp associated with the file set, calculated from the epoch time in seconds. poster (str): The name or identifier of the file set’s poster. download_path (str): The path where the file is downloaded. status_string (str): The unparsed status string associated with the file set. file_count (int): The number of files in the file set, extracted from the status string. par_count (int): The number of parity files (PAR files) in the file set, extracted from the status string.
- Methods:
__init__: Initializes the WishFileSet instance by parsing and storing details from a tab-delimited string. __str__: Returns a string representation of the file set with its key attributes.
- property download_path: str
- Returns:
The current download path.
- property file_count: int
- Returns:
The current count of files.
- property file_size: float
- Returns:
The size of the file.
- property item_id: int
- Returns:
The identifier of the object.
- property par_count: int
- Returns:
The value of the private attribute _par_count
- property poster: str
- Returns:
The poster property, which retrieves the value of the private attribute ‘_poster’.
- property status_string: str
- Returns:
The status string representing the current state.
- Return type:
str
- property subject: str
- Returns:
The subject associated with the instance.
- property time_stamp: datetime
- Returns:
The current timestamp associated with the object. This represents the time when the object was created or last updated, depending on its implementation.