File size: 531 Bytes
71fa0c7
 
 
60532a1
71fa0c7
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
from abc import ABC, abstractmethod
from typing import Generator
from pathlib import Path
from knowlang.configs.config import AppConfig

class CodeProvider(ABC):
    """Abstract base class for code source providers"""
    
    @abstractmethod
    def __init__(self, source_path: Path, config: AppConfig):
        self.source_path = source_path
        self.config = config
    
    @abstractmethod
    def get_files(self) -> Generator[Path, None, None]:
        """Yield paths to code files that should be processed"""
        pass