Which code segment should you insert at the line 02?

You are creating a Windows Communication Foundation application by using Microsoft .NET Framework 3.5.
The application must consume an ATOM 1.0 feed published at http://localhost:8000/Blogservice/GetBlog.
You write the following code segment.
(Line numbers are included for reference only.)

01 Uri address = new Uri("http://localhost:8000/Blogservice/GetBlog");
02
03 Console.WriteLine(feed.Title.Text);

You need to ensure that the application prints the title of the feed. Which code segment should you insert at the line 02?

You are creating a Windows Communication Foundation application by using Microsoft .NET Framework 3.5.
The application must consume an ATOM 1.0 feed published at http://localhost:8000/Blogservice/GetBlog.
You write the following code segment.
(Line numbers are included for reference only.)

01 Uri address = new Uri("http://localhost:8000/Blogservice/GetBlog");
02
03 Console.WriteLine(feed.Title.Text);

You need to ensure that the application prints the title of the feed. Which code segment should you insert at the line 02?

A.
SyndicationFeed feed = SyndicationFeed.Load(address);

B.
SyndicationFeed feed = new SyndicationFeed();
feed.BaseUri = address;

C.
SyndicationItem item = SyndicationItem.Load(address);
SyndicationFeed feed = new SyndicationFeed();
feed.Items = new SyndicationItem[]{ item };

D.
SyndicationItem item = new SyndicationItem();
item.BaseUri = address;
SyndicationFeed feed = new SyndicationFeed();
feed.Items = new SyndicationItem[]{ item };



Leave a Reply 0

Your email address will not be published. Required fields are marked *