Home » Microsoft » 70-518 » What will you do?
You are creating a Windows Web service application using .NET Framework 4.0.
The application has the following requirements:
. The user settings have to be retained between application executions.
. The application will be executed without any administrative privileges.
You must ensure that the application meets the requirements by using the least amount of development effort.
What will you do?
A. Create a Windows service to store session state.
B. Use a WPF Standalone application to store session state.
C. Use the CookieContainer class to store session state.
D. Use temporary cookie to store session state.
Correct Answer: C
Explanation
Explanation/Reference:
Explanation others:
You will use the CookieContainer class to store session state. The CookieContainer class is used to represent a container for a collection of CookieCollection objects. It is a data structure that provides storage space for the Cookie class instances. It has a capacity limit that is set as soon as the container is created or altered by a property. The CookieContainer class has three properties that direct the volume of the content of the container, which are as follows: Capacity MaxCookieSize PerDomainCapacity
. A is incorrect:
A Windows service is a process that executes in the background and in its own process space, with a specific user identity. Usually, it does not involve any user interaction. A Windows service is required to conform to the interface provided by the Windows Service Control Manager (SCM).