Exam Code: 70-486 (Practice Exam Latest Test Questions VCE PDF)
Exam Name: Developing ASP.NET MVC 4 Web Applications
Certification Provider: Microsoft
Free Today! Guaranteed Training- Pass 70-486 Exam.

2017 Jan 70-486 question

Q21. - (Topic 4) 

You are developing an ASP.NET MVC application. 

The application provides a RESTful API for third-party applications. This API updates the information for a contact by embedding the information in the URL of an HTTP POST. 

You need to save the Contact type when third-party applications use the EditContact method. 

Which code segment should you use? {Each correct answer presents a complete solution. Choose all that apply.) 

A. Option A 

B. Option B 

C. Option C 

D. Option D 

Answer: B,D 

Explanation: Basics of RESTful services: 

REST stands for Representational State Transfer, it is a simple stateless architecture that runs over HTTP where each unique URL is representation of some resource. There are four basic design principles which should be followed when creating RESTful service: 

* Use HTTP methods (verbs) explicitly and in consistent way to interact with resources 

(Uniform Interface), i.e. to retrieve a resource use GET, to create a resource use POST, to 

update a resource use PUT/PATCH, and to remove a resource use DELETE. 

Etc. 


Q22. - (Topic 4) 

You are designing a localized ASP.NET application to support multiple cultures. You need to ensure that the application can be displayed in several languages. How should you implement this feature? 

A. Use a resource (.resx) file. 

B. Include language-specific content in the assembly manifest. 

C. Use Systems.Collections.Generics.Dictionary to store alternative translations. 

D. Ensure that all strings are marked internal. 

Answer:


Q23. - (Topic 2) 

You need to modify the application to meet the productId requirement. 

What should you do? 

A. Modify the RegisterGlobalFilters method of the Global.asax.cs file as follows. Contract.Assume<ArgumentException>(productId != 0); 

B. Modify the GetDealPrice method of ProductController as follows. Contract.Requires<ArgumentException>(productId > 0); 

C. Modify the RegisterGlobalFilters method of the Global.asax.cs file as follows. Contract.Requires<ArgumentException>(productId > 0); 

D. Modify the GetDealPrice method of ProductController as follows. Contract.Assume<ArgumentException>(productId > 0); 

Answer:

Explanation: 

The Contract.Requires(Of TException) method specifies a precondition contract for the enclosing method or property, and throws an exception if the condition for the contract fails. Syntax: 'Declaration Public Shared Sub Requires(Of TException As Exception) ( _ condition As Boolean _) Type Parameters TException The exception to throw if the condition is false. Parameters condition Type: System.Boolean The conditional expression to test. 

Reference: Contract.Requires(Of TException) Method (Boolean) 


Q24. HOTSPOT - (Topic 2) 

You need to implement the mobile device support requirements. 

How should you build the ProcessRequest method? (To answer, select the appropriate options in the answer area.) 

Answer: 


Q25. DRAG DROP - (Topic 1) 

You need to ensure that only valid parameters are passed to the EditLog action. 

How should you build the route? (To answer, drag the appropriate code segments to the 

correct location or locations. Each code segment may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content.) 

Answer: 


Avant-garde 70-486 test:

Q26. - (Topic 2) 

You need to configure session storage in the web.config file to meet the technical requirements for scalability. 

Which SessionState mode should you use? (Each correct answer presents a complete solution. Choose all that apply.) 

A. StateServer 

B. InProc 

C. AutoDetect 

D. SqlServer 

Answer: A,D 


Q27. - (Topic 2) 

You need to update the routes to ensure that a product is always displayed on the product page. 

Which code segment should you use? 

A. Option A 

B. Option B 

C. Option C 

D. Option D 

Answer:


Q28. - (Topic 4) 

You are designing a data-oriented application that features a variety of storage schemas. The application object model must be mapped to the various storage schemas. 

You need to enable developers to manipulate the data. 

Which ADO.NET data access strategy should you use? (Each correct answer presents a complete solution. Choose all that apply.) 

A. LINQ to SQL 

B. Entity Framework 

C. DataAdapter 

D. DataReader 

Answer: A,B,C 


Q29. - (Topic 4) 

You are developing an ASP.NET MVC application. 

You need to authenticate clients by using an ASP.NET membership database. 

Which authentication method should you implement? 

A. Kerberos 

B. Forms 

C. Basic 

D. Windows 

Answer:


Q30. HOTSPOT - (Topic 4) 

You are developing an ASP.NET MVC application. 

Before an action is executed, information about the action must be written to a log. After 

results are returned, information about the results also must be written to the log. 

You need to log the actions and results. 

You have the following code: 

Which code segments should you include in Target 1, Target 2 and Target 3 to implement the LogActionFilter class? (To answer, select the appropriate option from the drop-down list in the answer area.) 

Answer: