How to pass Microsoft 70-513(CSHARP) Real Exam in 24 Hours [real exam 17-32]

70-513(CSHARP) 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-513(CSHARP)
Exam name: Windows Communication Foundation Development with Microsoft C#.NET Framework 4
n questions with full explanations
Certification: Microsoft Certification
Last updated on Global synchronizing

Free Certification Real IT 70-513(CSHARP) Exam pdf Collection

Exam Code: 70-513(CSHARP) (Practice Exam Latest Test Questions VCE PDF)
Exam Name: Windows Communication Foundation Development with Microsoft C#.NET Framework 4
Certification Provider: Microsoft
Free Today! Guaranteed Training- Pass 70-513(CSHARP) Exam.

2016 Mar 70-513(CSHARP) Study Guide Questions:

Q17. You are developing a client that sends several types of SOAP messages to a Windows Communication Foundation (WCF) service method named PostData. 

PostData is currently defined as follows. 

[OperationContract] 

void PostData(Order data); 

You need to modify PostData so that it can receive any SOAP message. 

Which code segment should you use? 

A. [OperationContract(IsOneWay = true, Action = "*", ReplyAction = "*")] void PostData(Order data); 

B. [OperationContract(IsOneWay = true, Action = "*", ReplyAction = "*")] void PostData(BodyWriter data); 

C. [OperationContract] void PostData(BodyWriter data); 

D. [OperationContract] void PostData(Message data); 

Answer: D


Q18. You are creating a Windows Communication Foundation (WCF) service. 

You need to ensure that the service is compatible with ASP.NET to make use of the session state. 

Which binding should you use? 

A. NetTcp ContextBinding 

B. BasicHttpContextBinding 

C. NetTcp Binding 

D. NetMsmqBinding 

Answer: B


Q19. You are creating a Windows Communication Foundation (WCF) service that accepts claims-based tokens. 

You need to ensure that the service can use claims from trading partners even though there are variations on naming for the same elements. 

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

A. Register a custom Service Authorization Manager that implements Check Access In this method, use System. Convert. Change Type to transform the incoming claim set to a Windows Claim Set type. 

B. Apply a Principal Permission attribute on the operation with the required claims listed in the Roles property. 

C. Within the operation, verify the presence of the required claims in the current Authorization Context 

D. Register an Authorization Policy that maps external claims to an internal Claim Set. 

Answer: C,D


Q20. You are developing a Windows Communication Foundation (WCF) service to provide an in-memory cache for many Web applications. The service contract is defined as follows. (Line numbers are included for reference only.) 

01 [ServiceContract] 02 public interface IDataCache 03 { 04 05 } 06 07 08 public class DataCache : IDataCache 09 { 10 11 } 

You need to ensure that all users share the cache. 

Which code segment should you insert at line 07? 

A. [ServiceBehavior(TransactionlsolationLevel = IsolationLevel.RepeatableRead)] 

B. [ServiceBehavior(InstanceContextMode = InstanceContextMode.Single)] 

C. [ServiceBehavior(InstanceContextMode = InstanceContextMode.PerSession)] 

D. [ServiceBehavior(TransactionlsolationLevel= IsolationLevel.ReadCoromitted)] 

Answer: B


Q21. The endpoint of a Windows Communication Foundation (WCF) service uses basicHttpBinding for its binding Your Company’s policies have changed to require that messages not be sent in clear text. 

You must ensure that all messages are encrypted when traveling across the network 

What should you do? 

A. Set the ProtectionLevelAttribute on the service contract and update the binding attribute in the endpoint element of the configuration file to wsHttpBinding 

B. Set the ProtectionLevelAttribute on the service contract and update the bindingConfiguration attribute in the endpoint element of the configuration file to webHttpBinding 

C. Set the PrincipalPermissionAttribute on the service contract and update the binding attribute in the endpoint element of the configuration file to wsHttpBinding 

D. Set the PrincipalPermissionAttribute on the service contract and update the bindingConfiguration attribute in the endpoint element of the configuration file to wsHttpBinding. 

Answer: A


70-513(CSHARP) brain dumps

Update 70-513(CSHARP) test question:

Q22. You are creating an application that consumes a Windows Communication Foundation (WCF) service. The service implements the IService contract. The client application contains the CallbackHandler class, which implements IServiceCallback. 

You need to ensure that a client proxy is created that can communicate with the service over a duplex channel. 

Which code segment should you use? 

A. var handler = new CallbackHandler(); 

var clientFactory = newDuplexChannelFactory<IService>{ 

new WSHttpContextBinding() ; 

var clienc = clientFactory.CreateChannelt 

new InstanceContext (handler) , new EndpointAddress ("...")); 

B. var handler = new CallbackHandler(); 

var clientFactory = 

newDuplexChonnelFaccory<IService>{ 

typeof(CallbackHandler), new WSDualHttpBinding ()); var client = clientFactory.CreateChannel( 

new InstanceContext (handler) , new EndpointAddress ("...")) ; 

C. var handler = new CallbackHandler(); 

var clientFactory = newDuplexChannelFactory<IService>{ 

new WSHttpBinding()); 

var client = clientFactory.CreateChannel( 

new InstanceContext (handler) , new EndpointAddress ("...")) ; 

C D. var handler = new CallbackHandler(); 

var clientFactory = newDuplexChannelFactory<IService>{ 

typeof(CallbackHandler), new WSDualHttpBinding()); 

var client=clientFactory.CreateChannel( 

new EndpointAddress ("...")) ; 

Answer: B


Q23. You develop a Windows Communication Foundation (WCF) service that employees use to access bonus information. You define the following service contract. (Line numbers are included for reference only.) 

01 [ServiceContract(SessionMode = SessionMode.Required)] 

02 public interface IFinancialService 03 { 04 [OperationContract] 05 string Login(int employeeID, string passwordHash); 06 07 [OperationContract] 08 double GetBonus(int month); 09 10 [OperationContract(IsTerminating = true)] 11 void Logout(); 12 } 

Client applications can invoke methods without logging in. 

You need to ensure that the client applications invoke Login before invoking any other method. You also need to ensure that client applications cannot consume the service after invoking Logout. 

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

A. Replace line 04 with the following code. [OperationContract(IsInitiating = false)] 

B. Replace line 04 with the following code. [OperationContract(IsInitiating = true, IsTerminating = true)] 

C. Replace line 07 with the following code. [OperationContract(IsInitiating = false)] 

D. Replace line 10 with the following code. [OperationContract(IsInitiating = false, IsTerminating = true)] 

Answer: C,D


Q24. You need to modify a client application that consumes a Windows Communication Foundation (WCF) service. 

The service metadata is no longer available. 

You need to modify the previously generated proxy to include asynchronous calls to the service. 

What should you do? 

A. Update the service reference with the Generate asynchronous operations option. 

B. Create a partial class for the previously generated proxy and include the new asynchronous methods. 

C. Create a class with the same name as the previously generated proxy and add the new asynchronous methods. Add the new class to a namespace that is different from the original proxy. 

D. Create a class with the same name as the previously generated proxy and add the new asynchronous methods as partial methods. Add the new class to a namespace that is different from the original proxy. 

Answer: B


Q25. You develop a Windows Communication Foundation (WCF) service. You enable all performance counters and run multiple calls to the service. 

The service must isolate session data for each user. 

You need to monitor the instancing behavior used in the service. 

Which performance counter should you monitor? 

A. ServiceModelService 4.0.0.0\Calls 

B. ServiceModelService 4.0.0.0\Instances 

C. ASP.NET State Service\State Server Sessions Active 

D. ASP.NET State Service\State Server Sessions Total 

Answer: B


Q26. You are integrating a Windows Communication Foundation (WCF) service within an enterprise-wide Service 

Oriented Architecture (SQA) 

Your service has the following service contract. 

[ServiceContract] 

public class CreditCardConfirmationService { [OperationContracti public Boolean ConfirmCreditCard(string cc Number double orderAmount, nmt orderNumber) { ) ) 

You need to allow the code in the ConfirmCreditCard method to participate automatically in existing transactions. If there is no existing transaction, a new transaction must be created automatically. 

What should you do? 

A. Inside the ConfirmCreditCard method, surround the code that must participate in the transaction with a using(new TransactionScopeO) block 

B. Inside the ConfirmCreditCard method, surround the code that must participate in the transaction with a using(new CommittableTransactionO) block. 

C. Add an [OperationBehavior(TransactionScopeRequired true)] attribute to the ConfirmCreditCard method. 

D. Add an [OperationBehavior(TransactionAutoComplete true)J attribute to the ConfirmCreditCard method. 

Answer: C


70-513(CSHARP) actual test

Simulation 70-513(CSHARP) sample question:

Q27. You are developing an application that performs file backups in the background. 

The background application will host a Windows Communication Foundation (WCF) service and must be active as soon as the machine is running. The background application will not have a user interface. A front-end application will consume the WCF service and will provide the user interface. 

You need to choose a host environment for the WCF service. Which hosting environment should you choose? 

A. Microsoft Internet Information Services (IIS) 6.0 

B. Windows Process Activation Services (WAS) 

C. a Windows Forms application 

D. a Windows Service 

Answer: D


Q28. You are using windows Communication Foundation (WCF) to create a service. 

You need to implement a custom message-level security binding element 

Which binding element should you use? 

A. TransportSecurityElement 

B. HttpsTransportBindingElement 

C. SslStreamSecuntyBindingElement 

D. WindowsStreamSecurityBindingElement 

Answer: A


Q29. You are developing a client application that uses the following code to consume a Windows Communication Foundation (WCF) service. (Line numbers are included for reference only.) 

01 BasicHttpBinding myBinding = new BasicHttpBinding(); 

02 EndpointAddress myEndpointAddress = 

new EndpointAddress( 

"http://contoso.com/TaxService.svc"); 

04 ITaxService client = channelFactory.CreateChannel(); 

05 string data = client.GetData(1); 

You need to consume the service. 

Which code segment should you insert at line 03? 

A. var channelFactory = new ChannelFactory<ITaxService>(); 

B. var channelFactory = new ChannelFactory<ITaxService>( myBinding); 

C. var channelFactory = new ChannelFactory<ITaxService>( myBinding, myEndpointAddress); 

D. var channelFactory = new ChannelFactory<ITaxService>( "http://contoso.com/TaxService.svc"); 

Answer: C


Q30. You are developing a Windows Communication Foundation (WCF) service. The service configuration file has a <System.Diagnostics> element defined. 

You need to ensure that all security audit information, trace logging, and message logging failures are recorded. 

Which configuration segment should you add to the <System.Diagnostics> element? 

A. <sources> 

<source name="System.ServiceModel" 

switchValue="Information, AccivityTracing" 

propagateActivity="true"> 

<listeners> 

<add name="xml" /> 

</listeners> 

</source> 

<source name-"Systero.ServiceModel.MessageLogging" 

propagaceActivicy-"ccue'/> 

<listeners> 

add name="cexc" /> 

</listeners> 

</source> 

</sources> 

B. <sources> 

<source name="System. ServiceModel" 

switchValue="Information, ActivityTracing" 

propagateActlvity."true'' /> 

<source name>System.ServiceModel.MessageLogging" 

propagateActivity-"true" /> 

</sources> 

C. <sources> 

<source name="Systero.ServiceModel" 

switchValue."Information, ActivityTracing" 

propagateActivity-"true"> 

<listeners> 

odd name="xml" /> 

</listeners> 

</source> 

<source name="System.ServiceModel.MessageLogging" 

propagateActivity="true"> 

<listeners> 

<add name-"xml" /> 

</listeners> 

</source> :/sources> 

<sharedListeners> 

<add name="xml" 

type="System.Diagnostics.XrolHriterTraceListener" 

initializeData="-" " /> 

<:/sharedListeners> 

D. <sources> 

<source name="System. ServiceModel" 

switchValue="Information, ActivityTracing" 

propagateActivity="true" /> 

<source name="System.ServiceModel.MessageLogging" 

propagateActivity="true" /> 

</sources> 

<sharedListeners> 

<add name="xml" 

type="System.Diagnostics.XmiUriterTraceListener" 

initializeData*""" " /> 

</sharedListeners> 

Answer: C


Q31. You are developing a client application that consumes a Windows Communication Foundation (WCF) service. The operation contract is as follows. 

[OperationContract] 

[FaultContract(typeof(SalesFault))] 

string GetSales(string saleld); 

The service configuration file contains the following line in the serviceBehaviors section. 

<behavior> 

<serviceDebug inc1udeExceptionDetoillnFauIts-"True"/> 

</behavior> 

A divide-by-zero exception is not being handled by the service. 

You need to ensure that the exception is caught in the client application. 

Which type of exception should the client catch? 

A. TimeoutException 

B. FaultException 

C. DivideByZeroException 

D. FaultException<SalesFault> 

Answer: B


Q32. A Windows Communication Foundation (WCF) service has a callback contract. You are developing a client application that will call this service. 

You must ensure that the client application can interact with the WCF service. 

What should you do? 

A. On the OperationContractAttribute, set the AsyncPattern property value to true. 

B. On the OperationContractAttribute, set the ReplyAction property value to the endpoint address of the client. 

C. On the client, create a proxy derived from DuplexClientBase<TChannel>. 

D. On the client, use GetCallbackChannel<T>. 

Answer: C



see more 70-513(CSHARP) - Windows Communication Foundation Development with Microsoft C#.NET Framework 4