Example #1
0
 public InnerBlogEditor(AppDataStore store)
 {
     InitializeComponent();
     store.Blog
     .GetModelHandler()
     .BindErrors(errors)
     .Bind(b => b.Url, url, urlErrors)
     .Bind(b => b.Rating, rating, ratingErrors);
 }
Example #2
0
        public AppDataStoreTests()
        {
            Mock <IAppNameProvider> appNameProviderMock = new Mock <IAppNameProvider>();

            appNameProviderMock.SetupGet(provider => provider.AppName)
            .Returns(AppName);

            _directoryManipulatorMock = new Mock <IDirectoryManipulator>();
            _directoryManipulatorMock.Setup(manipulator => manipulator.AppDataPath)
            .Returns(AppDataPath);

            _fileManipulatorMock = new Mock <IFileManipulator>();

            _appDataStore = new AppDataStore(appNameProviderMock.Object, _directoryManipulatorMock.Object, _fileManipulatorMock.Object);
        }
 protected override async void OnStart()
 {
     Db = await AppDataStore.Create();
 }
        public InnerBlogList(AppDataStore store)
        {
            InitializeComponent();

            contents.BindTo(store.Blogs, b => new BlogItem(b));
        }
Example #5
0
 public PostRepository(MainConsumer consumer, AppDataStore store) : base(consumer)
 {
     this.store = store;
 }