This commit introduces database integration using FireflyDB for storing and retrieving audio file metadata. - Integrated FireflyDB for persistent storage of metadata. - Added methods to check for existing metadata in the database and retrieve it. - Modified the Organizer class to use FireflyDB for processing metadata. - Added auto-scanning and metadata extraction upon directory opening in Fbrowser. - Created archiver.py and metaextract.py to house the ArchiveExtractor and MetadataExtractor classes respectively. - Added .gitignore entries for Firefly related files. - Added Mock MIT License, Contributor License Agreement, and Pro Edition License Agreement files.
41 lines
1.6 KiB
Python
41 lines
1.6 KiB
Python
from typing import Dict, List, Optional
|
|
|
|
class IFireflyClient:
|
|
def __init__(
|
|
self,
|
|
host: str = "localhost",
|
|
port: int = 6379,
|
|
password: Optional[str] = None,
|
|
) -> None: ...
|
|
def ping(self) -> bool: ...
|
|
def close(self) -> None: ...
|
|
|
|
# String operations
|
|
def string_ops(self, key: str) -> Dict[str, str]: ...
|
|
def string_set(self, key: str, value: str) -> bool: ...
|
|
def string_get(self, key: str) -> Optional[str]: ...
|
|
def string_delete(self, key: str) -> bool: ...
|
|
|
|
# List operations
|
|
def list_right_push(self, key: str, value: str) -> int: ...
|
|
def list_left_push(self, key: str, value: str) -> int: ...
|
|
def list_right_pop(self, key: str) -> Optional[str]: ...
|
|
def list_left_pop(self, key: str) -> Optional[str]: ...
|
|
def list_range(self, key: str, start: int, end: int) -> List[str]: ...
|
|
def list_length(self, key: str) -> int: ...
|
|
def list_ops(self, key: str) -> List[str]: ...
|
|
|
|
# Hash operations
|
|
def hash_ops(self, key: str) -> Dict[str, str]: ...
|
|
def hash_set(self, key: str, field: str, value: str) -> bool: ...
|
|
def hash_get(self, key: str, field: str) -> Optional[str]: ...
|
|
def hash_delete(self, key: str, field: str) -> bool: ...
|
|
def hash_get_all(self, key: str) -> Dict[str, str]: ...
|
|
def hash_exists(self, key: str, field: str) -> bool: ...
|
|
|
|
# Connection management
|
|
def execute_command(self, command: str, *args) -> Optional[str]: ...
|
|
def on_progress_update(self, progress: int) -> None: ...
|
|
def on_metadata_complete(self) -> None: ...
|
|
def on_scan_complete(self) -> None: ...
|