Ensurepass.com : Ensure you pass the IT Exams
2018 Aug Microsoft Official New Released 70-486
100% Free Download! 100% Pass Guaranteed!
Developing ASP.NET MVC 4 Web Applications
Question No: 51 – (Topic 3)
You need to maximize performance of video delivery.
Which code segment should you use as the body of the GetVideoStream function in the Video-Controller class?
-
Option A
-
Option B
-
Option C
-
Option D
Answer: D
Question No: 52 – (Topic 3)
You need to ensure that developers can connect to a Windows Azure role by using RDP. What should you do?
-
Export a certificate without a private key. Upload the .cer file to the Management Certificates section on the Azure Management Portal.
-
Export a certificate with a private key. Upload the .pfx file to the Management Certificates section on the Azure Management Portal.
-
Export a certificate without a private key. Upload the .cer file to the Certificates section under the TranscodeWorkerRole hosted service on the Azure Management Portal.
-
Export a certificate with a private key. Upload the .pfx file to the Certificates section under the TranscodeWorkerRole hosted service on the Azure Management Portal.
Answer: D
Question No: 53 – (Topic 3)
You need to ensure that all the MVC controllers are secure.
Which code segment should you use as the body for the CreateController method in AdminVerifierFactory.cs?
-
Option A
-
Option B
-
Option C
-
Option D
Answer: C
Question No: 54 – (Topic 3)
The transcode.exe utility activates its license online when it is installed.
You need to ensure that the registration of the transcode utility is handled as specified in its license.
Which method should you add to the TranscodeWorkerRole class?
-
Option A
-
Option B
-
Option C
-
Option D
Answer: D
Topic 4, Mixed Questions
Question No: 55 HOTSPOT – (Topic 4)
You develop an ASP.NET MVC application that displays Information about products that a company sells. The application contains two classes named ProductController and RouteConfig
You have the following requirements:
-
If a value is provided for the Id property, you must display information about an individual product.
-
If no value is provided for the Id property, you must display information about all products.
You need to configure routing.
How should you complete the relevant classes? to answer, select the appropriate code segment from each list in the answer area.
Answer:
Question No: 56 DRAG DROP – (Topic 4)
You are building an ASP.NET application for a purchasing system.
The application has a method named CalculateBalance in the Purchasing class. You need to create a unit test for the CalculateBalance method.
Which five actions should you perform in sequence? To answer, move the appropriate actions from the list of actions to the answer area and arrange them in the correct order.
Answer:
Explanation:
Step 1: Select the Purchasing Project and add a new Unit Test Project. First we create a Unit Test Project within the current project.
Step 2:
You can turn an existing unit test into an ASP.NET unit test by configuring it, that is, by assigning values to certain of the test#39;s custom attributes. You set these values in the code file that contains the unit test.
All unit tests require the [TestMethod] attribute. Step 3: Build the solution
Step 4: Run all tests
Step 5: Debug the solution
After you run a unit test, if you chose to edit the test run configuration when you ran the test, you can open the Code Coverage window to see what percentage of the methods in the code that you are testing were covered by your unit tests.
Incorrect: Not:
You do not set up testing by creating copies of methods.
References: https://msdn.microsoft.com/en-us/library/ms182526(v=vs.90).aspx
Question No: 57 – (Topic 4)
You are developing an ASP.NET MVC web application in Visual Studio 2012. The application requires several thousand content files. All content is hosted on the same IIS instance as the application.
You detect performance issues when the application starts. You need to resolve the performance issues.
What should you do?
-
Implement HTTP caching in the ASP.NET MVC controllers.
-
Combine the content files by using ASP.NET MVC bundling.
-
Install a second IIS instance.
-
Move the content to a Windows Azure CDN.
Answer: B
Explanation:
Bundling is a new feature in ASP.NET 4.5 that makes it easy to combine or bundle multiple files into a single file. You can create CSS, JavaScript and other bundles. Fewer files means fewer HTTP requests and that can improve first page load performance.
References: https://www.asp.net/mvc/overview/performance/bundling-and-minification
Question No: 58 DRAG DROP – (Topic 4)
DRAG DROP
You are developing an ASP.NET MVC application in Visual Studio.
The application contains an area that is defined as shown in the following graphic.
The ActionLink method must invoke the GetOrders() action in ExternalOrderController. You need to configure the parameters of the ActionLink method.
You have the following markup.
Which markup segments should you include in Target 1, Target 2 and Target 3 to complete the markup? To answer, drag the appropriate markup segment to the correct targets. Each markup 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:
Explanation:
Target 1: 鈥淕etOrders鈥?
Target 2: 鈥淓xternalOrderController鈥?
Target 3: External,
Target 1: the action is getOrders
Target 2: the controller is ExternalOrderController Target 3: The area is External
LinkExtensions.ActionLink Method (HtmlHelper, String, String, String, RouteValueDictionary, IDictionarylt;String, Objectgt;)
Use:
Html.ActionLink(quot;Textquot;, quot;ActionNamequot;, quot;ControllerNamequot;, new { Area = quot;AreaNamequot; }, null) References:
Question No: 59 DRAG DROP – (Topic 4)
DRAG DROP
You are developing an ASP.NET MVC application that authenticates a user by using claims-based authentication.
The application must:
You need to implement authentication.
How should you build the class constructor? (To answer, drag the appropriate code segment to the correct location or locations in the answer area. 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:
Explanation:
Box 1: IClaimsIdent
Box 2: ClaimType
Box 3: ClaimTypes
Box 4: ClaimType
Similar example:
For Box 1, see line 15.
For Box 2, see line 22.
For Box 3, see line 22.
For Box 4, see line 26.
-
using System;
-
using System.Collections.Generic;
-
using System.Linq;
-
using System.Web;
-
using Microsoft.IdentityModel.Claims;
06
07 namespace MVC3MixedAuthenticationSample.Models
08 {
09 public class IdentityClaim 10 {
11 private string _identityProvider; 12 private string _identityValue;
13 public const string ACSProviderClaim
=quot;http://schemas.microsoft.com/accesscontrolservice/2010/07/claims/identityproviderquot;; 14
15 public IdentityClaim(IClaimsIdentity identity) 16 {
17
18 if (identity != null) 19 {
20 foreach (var claim in identity.Claims) 21 {
22 if (claim.ClaimType == ClaimTypes.NameIdentifier) 23 {
24 _identityValue = claim.Value; 25 }
26 if (claim.ClaimType == ACSProviderClaim) 27 {
28 _identityProvider = claim.Value; 29 }
30
31 }
32 }
33
34 }
References:
Question No: 60 – (Topic 4)
You develop an ASP.NET MVC application. The application has several Razor views. The application must support desktop and mobile devices by using server side code. You need to choose an approach to support mobile devices.
Which two approaches can you use?
-
use different controllers and views for both desktop and mobile browsers but render the views with the same Razor layout depending on the device type.
-
Use the same controllers for both desktop and mobile browsers, but render different views depending on the device type.
-
Use different controllers and views for both desktop and mobile browsers, but render the views using the Bootstart framework.
-
Create separate areas for desktop and mobile browsers implementing independent controllers and views for each.
Answer: B,D
100% Ensurepass Free Download!
–70-486 PDF
100% Ensurepass Free Guaranteed!
–70-486 Dumps
EnsurePass | ExamCollection | Testking | |
---|---|---|---|
Lowest Price Guarantee | Yes | No | No |
Up-to-Dated | Yes | No | No |
Real Questions | Yes | No | No |
Explanation | Yes | No | No |
PDF VCE | Yes | No | No |
Free VCE Simulator | Yes | No | No |
Instant Download | Yes | No | No |