PrepAway - Latest Free Exam Questions & Answers

Author: seenagape

Which code segment should you use?

DRAG DROP
Contract exhibit:
<ServiceContract>
Public Interface IHelloService
<OperationContract>
<WebGet(UriTemplate: =“hellonane={name}”>
Function PassGuideHello(Byval name As String) As string
End Interface
Class exhibit:
Public Class HelloService
Implements IHelloService
Public Function PassGuideHello(ByVal name As String) As String_
Implements lHelloService
PassGuideHello
Return “Hi there “& name
End Function
End Class

Hosting code exhibit:
Dim svcHost As WebServiceHost = CreateHost()
svcHost.Open()
Console.ReadLine()
svcHost.Close()
There is a WCF (Windows Communication Foundation) service PassGuideService.
The contract of PassGuideService, the implementation, and self-hosted service hosting code are
displayed in separate exhibits.
A single endpoint, at http://PassGuide:7500/HelloService, is used for the implementation of
CreateHost.
Which code should you use?
You need to implement CreateHost so that the service has a single endpoint hosted
http:/IPassGuide7500/HeloService.
Which code segment should you use?

Which code should be used for the channel factory?

DRAG DROP
Exhibit:
<client>
<endpoint address=”nettcp://server/PassGuideService”
Binding=”netTcpBinding”
Contracts ” PassGuide.IPassGuideService”
name=”netTcp” />
<endpoint address=”net.pipe://localhost/PassGuideService”
Binding=”netNamedPipeBinding”
Contracts ” PassGuide.IPassGuideService”
Name=”netPipe” />
</client>

There is a WCF (Windows Communication Foundation) service client PassGuideServiceClient.
The system ServiceModel element of PassGuideServiceClient includes the XML element that is
being displayed in the exhibit.
There is a need of channel factory.
The channel factory should send messages to endpoint listening at
net.pipe://localhost/PassGuideService.
Which code should be used for the channel factory?

How should the client channed be implemented?

DRAG DROP
Exhibit:
<ServiceContract(CallbackContract =GetType(INameService))>
Public Interface IGreetingService
<OperationContract>
Function PassGuideMessage() As String
End Interface
<ServiceContract>
Public Interface INameService
<OperationContract>
Function PassGuideName() As String
End Interface

There is a WCF (Windows Communication Foundation) solution PassGuideSol, which is using
some contracts being displayed in the exhibit.
Whenever the client uses PassGuideMessage on the service interface, the service uses the client
callback to call PassGuideName. Within the client the callback contract is implemented by the
NameService class.
The service callback must processed by an instance of NameService.
How should the client channed be implemented?

How should this be achieved?

Contract exhibit:
<ServiceContract(Namespaces”http://PassGuide.com”)>
Public Interface IShipping
<OperationContract>
Function PassGuideWork(ByVal id As Integer) As String
End Interface
There is a WCF (Windows Communication Foundation) application PassGuideApp.
There is a WCF (Windows Communication Foundation) service PassGuideService.
The contract of PassGuideService is being displayed in the exhibit.
PassGuideApp is also hosting other services.
PassGuideApp endpoints use SOAP 1.2 bindings with WS-Addressing 1.0.
There is one single lister configured in System.ServiceModel.MessageLogging trace source of the
system.diagnostics configuration section.
Only the messeages that the PassGuideWork operation returns should be logged.
How should this be achieved? Select four.

How can this be achieved?

DRAG DROP
Data contract Exhibit:
<DataContract>
Public Class Employee
<DataMember>
Public Name As String
<DataMember>
Public City As String
<DataMember>
Public Wage As Integer
<DataMember>
Public EMPLOYEEID As Integer
End Class

XML exhibit:
<Employee>
<Name xsi:nil”true”/>
<City xsi:nil “true”/>
< EMPLOYEEID >123456789 </ EMPLOYEEID >
</Employee>
There is WCF (Windows Communication Foundation) application PassGuideApp.
PassGuideApp uses the data contract being displayed data contract exhibit.
The XML code in the XML exhibit must be produces with the data contract is serialized.
How can this be achieved?

How should this be achieved?

DRAG DROP
Soap envelope exhibit:
<s:Envelope xmlns:se’http://schemas.xmlsoporg/soap/enveloper’>
<s: Header>
<h:PassGuideID xmlns = “http:/www.PassGuide.com”>
9283
</h: PassGuideID>

</s:Header>
<s:Body>
<PassGuideStock xmlns=http://www.PassGuide.com”>
<ParticularID>1234 </ ParticularID >
</PassGuideStock>
</s: Body>
</s: Envelope>
The SOAP envelope in the exhibit must be generated.
How should this be achieved?