class MainController: def __init__(self): self.repository = NoteRepository() def get_all_notes(self): return self.repository.get_all_notes() def add_note(self, note: str): self.repository.add_note(note) def clear_all(self): self.repository.clear_all_notes()
class MainController: def __init__(self): # Create note repository here # Your code here self.repository = NoteRepository() def get_all_notes(self): # Return all notes # Your code here return self.repository.get_all_notes() def add_note(self, note: str): # Add note # Your code here self.repository.add_note(note) def clear_all(self): # Clear all note # Your code here self.repository.clear_all_notes()
def __init__(self): # Create note repository here # Your code here self.repository = NoteRepository()
def __init__(self): self.repository = NoteRepository()
def clear_all(self): # Clear all note # Your code here NoteRepository.clear_all_notes(self) pass
def add_note(self, note: str): # Add note # Your code here NoteRepository.add_note(self, note) pass
def get_all_notes(self): # Return all notes # Your code here return NoteRepository.get_all_notes(self) pass
def get_all_notes(self): return NoteRepository.get_all_notes(self) pass
def clear_all(self): NoteRepository.clear_all_notes(self) pass
def add_note(self, note: str): NoteRepository.add_note(self, note) pass