Exam 70-483 Topic 8 Question 140 Discussion
Actual exam question for Microsoft's 70-483 exam
Question #: 140
Topic #: 8
Question #: 140
Topic #: 8
You are developing an application by using C#.
The application includes an object that performs a long running process.
You need to ensure that the garbage collector does not release the object's resources until the process completes.
Which garbage collector method should you use?
The application includes an object that performs a long running process.
You need to ensure that the garbage collector does not release the object's resources until the process completes.
Which garbage collector method should you use?
Suggested Answer: D Vote an answer
The purpose of the KeepAlive method is to ensure the existence of a reference to an object that is at risk of being prematurely reclaimed by the garbage collector.
Reference:
https://msdn.microsoft.com/en-us/library/system.gc.keepalive(v=vs.110).aspx
Reference:
https://msdn.microsoft.com/en-us/library/system.gc.keepalive(v=vs.110).aspx
by Monroe at Feb 25, 2024, 01:13 AM
0
0
0
10
Comments
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
Report Comment
Commenting
You can sign-up / login (it's free).