"""
This type stub file was generated by pyright.
"""

from abc import ABCMeta, abstractmethod
from ._ast import *
from ._cd import *
from ._ir import *

"""
This type stub file was generated by pyright.
"""
__all__ = ["ValueVisitor", "ValueTransformer", "StatementVisitor", "StatementTransformer", "FragmentTransformer", "TransformedElaboratable", "DomainCollector", "DomainRenamer", "DomainLowerer", "ResetInserter", "EnableInserter"]
class ValueVisitor(metaclass=ABCMeta):
    @abstractmethod
    def on_Const(self, value):
        ...
    
    @abstractmethod
    def on_Signal(self, value):
        ...
    
    @abstractmethod
    def on_ClockSignal(self, value):
        ...
    
    @abstractmethod
    def on_ResetSignal(self, value):
        ...
    
    @abstractmethod
    def on_AnyValue(self, value):
        ...
    
    @abstractmethod
    def on_Operator(self, value):
        ...
    
    @abstractmethod
    def on_Slice(self, value):
        ...
    
    @abstractmethod
    def on_Part(self, value):
        ...
    
    @abstractmethod
    def on_Concat(self, value):
        ...
    
    @abstractmethod
    def on_SwitchValue(self, value):
        ...
    
    @abstractmethod
    def on_Initial(self, value):
        ...
    
    def on_unknown_value(self, value):
        ...
    
    def replace_value_src_loc(self, value, new_value):
        ...
    
    def on_value(self, value):
        ...
    
    def __call__(self, value):
        ...
    


class ValueTransformer(ValueVisitor):
    def on_Const(self, value):
        ...
    
    def on_Signal(self, value):
        ...
    
    def on_ClockSignal(self, value):
        ...
    
    def on_ResetSignal(self, value):
        ...
    
    def on_AnyValue(self, value):
        ...
    
    def on_Operator(self, value):
        ...
    
    def on_Slice(self, value):
        ...
    
    def on_Part(self, value):
        ...
    
    def on_Concat(self, value):
        ...
    
    def on_SwitchValue(self, value):
        ...
    
    def on_Initial(self, value):
        ...
    


class StatementVisitor(metaclass=ABCMeta):
    @abstractmethod
    def on_Assign(self, stmt):
        ...
    
    @abstractmethod
    def on_Print(self, stmt):
        ...
    
    @abstractmethod
    def on_Property(self, stmt):
        ...
    
    @abstractmethod
    def on_Switch(self, stmt):
        ...
    
    @abstractmethod
    def on_statements(self, stmts):
        ...
    
    def on_unknown_statement(self, stmt):
        ...
    
    def replace_statement_src_loc(self, stmt, new_stmt):
        ...
    
    def on_statement(self, stmt):
        ...
    
    def __call__(self, stmt):
        ...
    


class StatementTransformer(StatementVisitor):
    def on_value(self, value):
        ...
    
    def on_Format(self, format):
        ...
    
    def on_Assign(self, stmt):
        ...
    
    def on_Print(self, stmt):
        ...
    
    def on_Property(self, stmt):
        ...
    
    def on_Switch(self, stmt):
        ...
    
    def on_statements(self, stmts):
        ...
    


class FragmentTransformer:
    def map_subfragments(self, fragment, new_fragment):
        ...
    
    def map_ports(self, fragment, new_fragment):
        ...
    
    def map_domains(self, fragment, new_fragment):
        ...
    
    def map_statements(self, fragment, new_fragment):
        ...
    
    def map_memory_ports(self, fragment, new_fragment):
        ...
    
    def on_fragment(self, fragment):
        ...
    
    def __call__(self, value, *, src_loc_at=...):
        ...
    


class TransformedElaboratable(Elaboratable):
    def __init__(self, elaboratable, *, src_loc_at=...) -> None:
        ...
    
    def __getattr__(self, attr):
        ...
    
    def elaborate(self, platform):
        ...
    


class DomainCollector(ValueVisitor, StatementVisitor):
    def __init__(self) -> None:
        ...
    
    def on_ignore(self, value):
        ...
    
    on_Const = ...
    on_Signal = ...
    on_AnyValue = ...
    def on_ClockSignal(self, value):
        ...
    
    def on_ResetSignal(self, value):
        ...
    
    def on_Operator(self, value):
        ...
    
    def on_Slice(self, value):
        ...
    
    def on_Part(self, value):
        ...
    
    def on_Concat(self, value):
        ...
    
    def on_SwitchValue(self, value):
        ...
    
    def on_Initial(self, value):
        ...
    
    def on_Format(self, format):
        ...
    
    def on_Assign(self, stmt):
        ...
    
    def on_Print(self, stmt):
        ...
    
    def on_Property(self, stmt):
        ...
    
    def on_Switch(self, stmt):
        ...
    
    def on_statements(self, stmts):
        ...
    
    def on_fragment(self, fragment):
        ...
    
    def __call__(self, fragment):
        ...
    


class DomainRenamer(FragmentTransformer, ValueTransformer, StatementTransformer):
    def __init__(self, domain_map) -> None:
        ...
    
    def on_ClockSignal(self, value):
        ...
    
    def on_ResetSignal(self, value):
        ...
    
    def map_domains(self, fragment, new_fragment):
        ...
    
    def map_statements(self, fragment, new_fragment):
        ...
    
    def map_memory_ports(self, fragment, new_fragment):
        ...
    


class DomainLowerer(FragmentTransformer, ValueTransformer, StatementTransformer):
    def __init__(self, domains=...) -> None:
        ...
    
    def replace_value_src_loc(self, value, new_value):
        ...
    
    def on_ClockSignal(self, value):
        ...
    
    def on_ResetSignal(self, value):
        ...
    
    def on_fragment(self, fragment):
        ...
    


class _ControlInserter(FragmentTransformer):
    def __init__(self, controls) -> None:
        ...
    
    def on_fragment(self, fragment):
        ...
    
    def __call__(self, value, *, src_loc_at=...):
        ...
    


class ResetInserter(_ControlInserter):
    ...


class EnableInserter(_ControlInserter):
    def on_fragment(self, fragment):
        ...
    


