toktokkie.metadata.movie package

Submodules

toktokkie.metadata.movie.Movie module

class toktokkie.metadata.movie.Movie.Movie(directory_path: str, json_data: Optional[Dict[str, Any]] = None, no_validation: bool = False)

Bases: toktokkie.metadata.base.Metadata.Metadata, toktokkie.metadata.movie.MovieRenamer.MovieRenamer, toktokkie.metadata.movie.MoviePrompter.MoviePrompter, toktokkie.metadata.movie.MovieValidator.MovieValidator

Metadata class that handles movies

directory_path: str

The path to the directory this metadata describes

json: Dict[str, Any]
classmethod media_type()toktokkie.enums.MediaType
Returns

The Movie media type

classmethod required_id_types() → List[toktokkie.enums.IdType]
Returns

A list of required ID types

classmethod valid_id_types() → List[toktokkie.enums.IdType]
Returns

A list of valid ID types

toktokkie.metadata.movie.MovieExtras module

class toktokkie.metadata.movie.MovieExtras.MovieExtras

Bases: toktokkie.metadata.base.MetadataBase.MetadataBase, abc.ABC

Additional methods and attributes for movie metadata objects

directory_path: str

The path to the directory this metadata describes

json: Dict[str, Any]
property movie_path
Returns

The path to the movie file

toktokkie.metadata.movie.MoviePrompter module

class toktokkie.metadata.movie.MoviePrompter.MoviePrompter

Bases: toktokkie.metadata.base.Prompter.Prompter, toktokkie.metadata.movie.MovieExtras.MovieExtras, abc.ABC

Implements the Prompter functionality for movie metadata

directory_path: str

The path to the directory this metadata describes

json: Dict[str, Any]
classmethod pre_prompt_check(directory_path: str)

Makes sure that the movie directory has exactly one movie file :param directory_path: The path to the directory to check :return: None

toktokkie.metadata.movie.MovieRenamer module

class toktokkie.metadata.movie.MovieRenamer.MovieRenamer

Bases: toktokkie.metadata.base.Renamer.Renamer, toktokkie.metadata.movie.MovieExtras.MovieExtras, abc.ABC

Implements the Renamer functionality for movie metadata

create_rename_operations() → List[toktokkie.metadata.base.components.RenameOperation.RenameOperation]

Creates renaming operations for movie metadata :return: The renaming operations

directory_path: str

The path to the directory this metadata describes

json: Dict[str, Any]
resolve_title_name() → str

If possible, will fetch the appropriate name for the metadata based on IDs, falling back to the directory name if this is not possible or supported.

toktokkie.metadata.movie.MovieValidator module

class toktokkie.metadata.movie.MovieValidator.MovieValidator

Bases: toktokkie.metadata.base.Validator.Validator, toktokkie.metadata.movie.MovieExtras.MovieExtras, abc.ABC

Implements the Validator functionality for movie metadata

directory_path: str

The path to the directory this metadata describes

json: Dict[str, Any]
validate()

Ensures that the movie file exist :return: None

Module contents