当前位置: 首页>>代码示例>>C#>>正文


C# Folder.GetBookmarks方法代码示例

本文整理汇总了C#中Folder.GetBookmarks方法的典型用法代码示例。如果您正苦于以下问题:C# Folder.GetBookmarks方法的具体用法?C# Folder.GetBookmarks怎么用?C# Folder.GetBookmarks使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Folder的用法示例。


在下文中一共展示了Folder.GetBookmarks方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: GetBookmarksTest

        public void GetBookmarksTest()
        {
            Login l = new Login();
            WebBrowser wb = l.GetBrowserElement();
            wb.DocumentCompleted += delegate(Object sender, WebBrowserDocumentCompletedEventArgs args)
            {
                OAuthHelper h = new OAuthHelper(wb); // TODO: Passenden Wert initialisieren
                InstapaperConnector target = new InstapaperConnector(h); // TODO: Passenden Wert initialisieren
                Folder folder = new Folder(target);
                folder.Id = Folder.STARRED;
                folder.GetBookmarks(delegate(IAsyncResult result)
                {
                    // Should return an empty List in case of zero folders

                    if (folder.Bookmarks.Count > 0)
                        foreach (Bookmark b in folder.Bookmarks)
                            Assert.IsNotNull(b);
                });

            };
        }
开发者ID:janmonschke,项目名称:Instablitz,代码行数:21,代码来源:InstapaperConnectorTest.cs

示例2: GetBookmarkText

        public void GetBookmarkText()
        {
            Login l = new Login();
            WebBrowser wb = l.GetBrowserElement();
            wb.DocumentCompleted += delegate(Object sender, WebBrowserDocumentCompletedEventArgs args)
            {
                OAuthHelper h = new OAuthHelper(wb); // TODO: Passenden Wert initialisieren
                InstapaperConnector target = new InstapaperConnector(h); // TODO: Passenden Wert initialisieren
                Folder folder = new Folder(target);
                folder.Id = Folder.STARRED;
                folder.GetBookmarks(delegate(IAsyncResult result)
                {
                    folder.Bookmarks[0].GetText(delegate(IAsyncResult res)
                    {
                        Assert.IsTrue(folder.Bookmarks[0].HtmlText.Length > 0);
                    });

                });

            };
        }
开发者ID:janmonschke,项目名称:Instablitz,代码行数:21,代码来源:InstapaperConnectorTest.cs

示例3: loadFolder

        private void loadFolder(String folder_id)
        {
            Folder f = new Folder(getConnector());
            f.Id = folder_id;

            f.GetBookmarks(delegate(IAsyncResult res) {
                BookmarkList.Clear();

                for (int i = 0; i < f.Bookmarks.Count; i++)
                {
                    Bookmark bookmark = f.Bookmarks[i];
                    BookmarkList.Items.Add(bookmark.Title);
                    Console.WriteLine("Adding Bookmark: " + bookmark.Title);
                }

                currentBookmarks = f.Bookmarks;
            });
        }
开发者ID:janmonschke,项目名称:Instablitz,代码行数:18,代码来源:BookmarkBrowser.cs


注:本文中的Folder.GetBookmarks方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。