2026-02-23 09:18:35 +01:00
|
|
|
# -*- coding: utf-8 -*-
|
|
|
|
|
|
|
|
|
|
from __future__ import annotations
|
2026-03-04 13:18:28 +00:00
|
|
|
from typing import Iterable, TYPE_CHECKING
|
2026-02-23 09:18:35 +01:00
|
|
|
|
|
|
|
|
import abc
|
|
|
|
|
|
2026-03-04 13:18:28 +00:00
|
|
|
from ..lib.Package import Package
|
2026-02-23 09:18:35 +01:00
|
|
|
from .Backend import Backend as Base
|
|
|
|
|
|
|
|
|
|
if TYPE_CHECKING:
|
|
|
|
|
from ..CmdPkg import CmdPkg as Parent
|
|
|
|
|
|
|
|
|
|
class BePkg(Base):
|
|
|
|
|
|
|
|
|
|
def __init__(self, parent: Parent):
|
|
|
|
|
super().__init__(parent)
|
|
|
|
|
|
2026-03-04 13:18:28 +00:00
|
|
|
async def files(self, name: str) -> Iterable[str]:
|
|
|
|
|
return await self._files(name)
|
2026-02-23 09:18:35 +01:00
|
|
|
|
|
|
|
|
@abc.abstractmethod
|
2026-03-04 13:18:28 +00:00
|
|
|
async def _files(self, name: str) -> Iterable[str]:
|
|
|
|
|
pass
|
|
|
|
|
|
|
|
|
|
async def meta_data(self, names: Iterable[str]) -> Iterable[Package]:
|
|
|
|
|
return await self._meta_data(names)
|
|
|
|
|
|
|
|
|
|
@abc.abstractmethod
|
|
|
|
|
async def _meta_data(self, names: Iterable[str]) -> Iterable[Package]:
|
2026-02-23 09:18:35 +01:00
|
|
|
pass
|