Ejemplo n.º 1
0
        override public void Load(string url)
        {
            Debug.Log("OutrunRealmHTMLDataSource");

            url += string.Format("?{0}", DateTime.Now.ToLongDateString());
            RealmsContentProvider.DownloadTextFile(url, ParseMainHTML);
        }
Ejemplo n.º 2
0
        private void LoadBlogPostContent(XElement blogPostNode)
        {
            OnContentItemLoadingStart();

            string blogPostURL =
                blogPostNode
                .Descendants()
                .Where(node => node.Attribute("class") != null)
                .Where(node => node.Attribute("class").Value == "entry-featured-image-url")
                .ElementAt(0)
                .Attribute("href")
                .Value
            ;

            RealmsContentProvider.DownloadTextFile(blogPostURL, ParseBlogPostHTML);
        }
Ejemplo n.º 3
0
        void Awake()
        {
            if (_instance == null)
            {
                _instance = this;
            }

            string dataSourceUrl = string.Empty;

            switch (_sourceFormat)
            {
            case SourceFormat.JSON:

                _dataSource   = new RealmsJSONDataSource();
                dataSourceUrl = _jsonUrl;
                break;

            case SourceFormat.HTML:

                _dataSource   = new RealmsHTMLDataSource();
                dataSourceUrl = _htmlURL;
                break;

            case SourceFormat.RSS_XML:
                _dataSource   = new RealmsFeedXMLDataSource();
                dataSourceUrl = _feedURL;
                break;

            default:
                _dataSource = new RealmsHTMLDataSource();
                break;
            }

            _dataSource.OnLoadingComplete += OnDataLoaded;
            _dataSource.Load(dataSourceUrl);
        }
 private void LoadVideosHTML(string url)
 {
     OnContentItemLoadingStart();
     RealmsContentProvider.DownloadTextFile(url, ParseMainHTML);
 }
 private void LoadFeedXML(string url)
 {
     OnContentItemLoadingStart();
     RealmsContentProvider.DownloadTextFile(url, ParseFeedXML);
 }