70-503 interactive bootcamp(136 to 150) for candidates: Mar 2016 Edition

70-503 Royal Pack Testengine pdf

100% Actual & Verified — 100% PASS

Unlimited access to the world's largest Dumps library! Try it Free Today!

Get it now →

Product Description:
Exam Number/Code: 70-503
Exam name: TS: Microsoft .NET Framework 3.5 - Windows Communication Foundation
n questions with full explanations
Certification: Microsoft Certification
Last updated on Global synchronizing

Free Certification Real IT 70-503 Exam pdf Collection

Question No. 136

You are creating a Windows Communication Foundation service by using Microsoft .NET Framework 3.5. 

The service will be hosted in a Windows Service environment. You need to create a Windows Service class that instantiates a service host. 

Which code segment should you use? 


A. Option A 

B. Option B 

C. Option C 

D. Option D 

Answer:


Question No. 137

You are creating a distributed application by using Microsoft .NET Framework 3.5. 

The application uses Windows Communication Foundation (WCF). The distributed application provides point-to-point security. 

You need to ensure that the distributed application provides end-to-end security instead of point-to-point security. 

Which binding mode should you use? 

A. netTcpBinding with Transport security 

B. wsHttpBinding with Transport security 

C. wsHttpBinding with Message security 

D. netNamedPipeBinding with Transport security 

Answer:


Question No. 138

You are creating an endpoint for a Windows Communication Foundation service by using Microsoft .NET Framework 3.5. You create the endpoint by using a custom binding. 

You write the following code segment. 


You need to prevent the custom binding from making a persistent connection to the service endpoint. 

Which code segment should you use? 


A. Option A 

B. Option B 

C. Option C 

D. Option D 

Answer:


Question No. 139

You are creating a distributed application by using Microsoft .NET Framework 3.5. The application uses Windows Communication Foundation. 

The client applications require the users to provide a user name and a password. 

You need to ensure that the server authenticates the client applications by verifying user names and passwords. 

Which two actions should you perform? (Each correct answer presents part of the solution. Choose two.) 


A. Option A 

B. Option B 

C. Option C 

D. Option D 

Answer: BD 


Question No. 140

You are creating a Windows Communication Foundation service by using Microsoft .NET Framework 3.5. You write the following code segment. (Line numbers are included for reference only.) 


When you browse to the base address of the service, you receive the following message: "Metadata publishing for this service is currently disabled." 

You debug the code and discover that the ServiceMetadataBehavior behavior was previously nonexistent. You need to enable metadata publishing. 

What should you do? 

A. Delete lines 15 and 16. 

B. Modify the code segment at line 03 in the following manner. Uri mexAddress=neUri("/service"); 

C. Insert the following code segment at line 11. smb.HttpGetEnabled=true; 

D. Insert the following code segment at line 19. smb.HttpGetEnabled=true; 

Answer:


Question No. 141

You are creating a Windows Communication Foundation service by using Microsoft .NET Framework 3.5. 

The service contains the following code segment. 

[ServiceContract] 

public interface IMathSrvc 

[OperationContract] 

void AddNumbers(int num); 

[OperationContract] 

int Clear(); 

You need to ensure that the service meets the following requirements: 

Which code segment should you use to replace the existing code segment? 

A. [ServiceContract] 

public interface IMathSrvc 

[OperationContract(IsOneWay=true)] 

void AddNumbers(int num); 

[OperationContract(IsTerminating=true)] 

int Clear(); 

B. [ServiceContract] 

public interface IMathSrvc 

[OperationContract(IsTerminating=false)] 

void AddNumbers(int num); 

[OperationContract(IsTerminating=true)] 

int Clear(); 

C. [ServiceContract] 

public interface IMathSrvc 

[OperationContract(IsInitiating=true, IsOneWay=true)] 

void AddNumbers(int num); 

[OperationContract(IsTerminating=true)] 

int Clear(); 

D. [ServiceContract] 

public interface IMathSrvc 

[OperationContract] 

void AddNumbers(int num); 

[OperationContract(IsInitiating=false, IsTerminating=true)] 

int Clear(); 

Answer:


Question No. 142

You create an application by using Microsoft Visual Studio .NET 2008 and the .NET Framework 3.5. The application exposes a Windows Communication Foundation (WCF) service that will be consumed by an ASP. NET application. The WCF application and the ASP.NET application will be deployed on the same server. You need to ensure that the WCF service meets the following requirements: 

The communication between the applications incurs minimum latency. The binding satisfies the ordered delivery constraint that is specified in the service implementation by using the DeliveryRequirements attribute. 

Which binding object should you use? 

A. NetTcpBinding 

B. WSHttpBinding 

C. NetPeerTcpBinding 

D. NetNamedPipeBinding 

Answer:


Question No. 143

You are creating a Windows Communication Foundation service by using Microsoft .NET Framework 3.5. You write the following XML code fragment. 


You need to add an endpoint definition to the service configuration for the URL http://localhost:8000/ServiceModelExam/service to expose the Contoso. Exams. lExam service contract. 

Which definition should you add? 


A. Option A 

B. Option B 

C. Option C 

D. Option D 

Answer:


Question No. 144

You are creating a Windows Communication Foundation service by using Microsoft .NET Framework 3.5. The service will be hosted on a Web server. You add the following code fragment to the .svc file. <% @ServiceHost Factory="ExamServiceFactory" Service="ExamService" %> 

You need to create the 3 instances of the services by using the custom ExamServiceFactory class. 

Which code segment should you use? 

A. public class ExamServiceFactory : ServiceHostj protected override void 

ApplyConfigurationO { 

//Implementation code comes here. }} 

B. public class ExamServiceFactory : ServiceHostBasej protected override void 

ApplyConfigurationQ {//Implementation code comes here. }} 

C. public class ExamServiceFactory : ServiceHostFactoryj protected override ServiceHost 

CreateServiceHost(Type serviceType, Uri[] baseAddresses) {//Implementation code comes here.} 

D. public class ExamServiceFactory : ServiceHostj public ExamServiceFactory(Type 

serviceType, params Uri[] baseAddresses): base(serviceType, baseAddresses) { 

//Implementation code comes here. }} 

Answer:


Question No. 145

You are creating a Windows Communication Foundation service by using Microsoft .NET Framework 3.5. The service will contain an enumeration named OrderState. 

The OrderState enumeration will contain the following four values: 

The client application must be able to set the state of an Order entity to only the following two values: 

You need to create the data contract for OrderState. Which code segment should you use? 


A. Option A 

B. Option B 

C. Option C 

D. Option D 

Answer:


Question No. 146

You are creating a distributed application with Windows Communication Foundation by using Microsoft .NET Framework 3.5. 

The distributed application topology includes client applications, routers, and services. Communication between the client applications and the services require authentication, confidentiality, and integrity. 

You need to ensure that routers are not able to read the contents of the messages. You must achieve this goal without customizing the binding configuration. 

Which binding should you use? 

A. NetNamedPipeBinding 

B. NetPeerTcpBinding 

C. WSHttpBinding 

D. NetTcpBinding 

Answer:


Question No. 147

You are creating a client application by using Microsoft .NET Framework 3.5. The client application uses a Windows Communication Foundation service. 

To log the called service proxy methods and their parameters, you implement custom endpoint behavior in the following class. 

Class ParametersLoggerBehavior 

Implements lEndpointBehavior End Class 

You also create the following class for the custom behavior. 

Class LoggerElement 

Inherits BehaviorExtensionElement End Class 

You add the following configuration code fragment to the application configuration file. (Line numbers are included for reference only.) 


You need to ensure that the endpoint uses the custom behavior. Which configuration settings should you insert at line 03? 


A. Option A 

B. Option B 

C. Option C 

D. Option D 

Answer:


Question No. 148

You are creating a remote database management application by using Microsoft Windows Forms and Microsoft .NET Framework 3.5. You use the Windows Communication Foundation model to create the application. 

You write the following code segment. (Line numbers are included for reference only.) 

01 Public Class ()ueryAnalyzerService 02 Implements IQueryAnalyzerService, IDisposable 

04 Public Sub Open() 05 ... 

06 End Sub 07 Public Sub ExecuteSql(ByVal sql As String) 08... 

09 End Sub 

10 Public Sub Close() 

11 ... 

12 End Sub 

13 Public Sub Dispose() Implements IDisposable.Dispose 14... 

15 End Sub 16... 

17 End Class 

You need to ensure that each time a client application calls the Open0 method, a new service instance is created. Which code segment should you insert at line 03? 

A. <OperationBehavior(TransactionScopeRequired:=True)> _ 

B. <OperationBehavior(AutoDisposeParameters:=True)> _ 

C. <OperationBehavior( _ ReleaselnstanceMode:=ReleaselnstanceMode.None)> _ 

D. <OperationBehavior(_ ReleaselnstanceMode:=ReleaselnstanceMode.BeforeCall> 

Answer:


Question No. 149

You are creating a Windows Communication Foundation service by using Microsoft .NET Framework 3.5. The service contains the following code segment. 


You need to ensure that the service meets the following requirements: 

Which code segment should you use to replace the existing code segment? 


A. Option A 

B. Option B 

C. Option C 

D. Option D 

Answer:


Question No. 150

You create a Windows Communication Foundation client application by using Microsoft .NET Framework 3.5. The client application communicates with an existing Web service that requires custom HTTP headers. You need to ensure that all messages sent to the service include the headers. Which two tasks should you perform? (Each correct answer presents part of the solution. Choose two.) 

A. Create a message inspector. Insert the custom headers by using the ICIientMessagelnspector.AfterReceiveReply method. 

B. Create a message inspector. Insert the custom headers by using the ICIientMessagelnspector.BeforeSendRequest method. 

C. Create a custom endpoint behavior. Add the message inspector by using the IEndpointBehavior.ApplyClientBehavior method. 

D. Create a custom endpoint behavior. Add the message inspector by using the IEndpointBehavior.AddBindingParameters method. 

Answer: BC