nerdexam
Microsoft

70-513 · Question #265

You are developing a Windows Communication Foundation (WCF) REST service to provide access to a library book catalog. The following code segment defines the service contract. (Line numbers are…

The correct answer is B. [WebGet(UriTemplate = "BookByTitle/{title}")]. See the full explanation below for the reasoning.

Question

You are developing a Windows Communication Foundation (WCF) REST service to provide access to a library book catalog. The following code segment defines the service contract. (Line numbers are included for reference only.) Library patrons want the ability to search the catalog by title. You need to ensure that the GetBookByTitle method is exposed as a service method. Which code segment should you insert at line 04?

Exhibit

70-513 question #265 exhibit

Options

  • A[WebGet(UriTemplate = "Book/{title}")]
  • B[WebGet(UriTemplate = "BookByTitle/{title}")]
  • C[WebGet(UriTemplate = "Book/{titleToSearch}")]
  • D[WebGet(UriTemplate = "{titleToSearch}")]

How the community answered

(20 responses)
  • A
    5% (1)
  • B
    75% (15)
  • C
    15% (3)
  • D
    5% (1)

Community Discussion

No community discussion yet for this question.

Full 70-513 Practice