RQNavigationControllerStack.h 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. //
  2. // RQNavigationControllerStack.h
  3. // RQCommon
  4. //
  5. // Created by 张嵘 on 2018/11/14.
  6. // Copyright © 2018 张嵘. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. #import "RQRouter.h"
  10. @protocol RQViewModelServices;
  11. @interface RQNavigationControllerStack : NSObject
  12. /// Initialization method. This is the preferred way to create a new navigation controller stack.
  13. ///
  14. /// services - The service bus of the `Model` layer.
  15. ///
  16. /// Returns a new navigation controller stack.
  17. - (instancetype)initWithServices:(id<RQViewModelServices>)services;
  18. /// Pushes the navigation controller.
  19. ///
  20. /// navigationController - the navigation controller
  21. - (void)pushNavigationController:(UINavigationController *)navigationController;
  22. /// Pops the top navigation controller in the stack.
  23. ///
  24. /// Returns the popped navigation controller.
  25. - (UINavigationController *)popNavigationController;
  26. /// Retrieves the top navigation controller in the stack.
  27. ///
  28. /// Returns the top navigation controller in the stack.
  29. - (UINavigationController *)topNavigationController;
  30. @end