from typing import Optional, List

from .standard_result import StandardResult
from actionstreamer.Model import AudioClip


class AudioClipResult(StandardResult):
    def __init__(self, code: int = 0, description: str = '', audio_clip: Optional[AudioClip] = None):
        super().__init__(code, description)
        self.audio_clip = audio_clip or AudioClip()


class AudioClipListResult(StandardResult):
    def __init__(self, code: int = 0, description: str = '', audio_clip_list: Optional[List[AudioClip]] = None):
        super().__init__(code, description)
        self.audio_clip_list = audio_clip_list or []