您编写下面的代码段,调用函数从 Win32 应用程序编程接口 (API),使用平台调用。 string personName = "N?el"; string msg = "welcome " + personName + "to club"!; bool rc = User32API.MessageBox(0, msg, personName, 0); 您需要定义一个方法原型可以最佳封送字符串数据。 您应该使用哪个代码段?()
A. B. C. D.
单项选择题您正在使用 MD5 算法开发后期验证哈希数据方法。作为字节数组的指定消息情况下,数据传递给您的方法。您需要使用 MD5 计算传入的参数的哈希值。此外,您还需要将结果放到一个字节数组。您应该使用哪个代码段?()
多项选择题You are defining a class named MyClass that contains several child objects. MyClass contains a method named ProcessChildren that performs actions on the child objects.MyClass objects will be serializable.You need to ensure that the ProcessChildren method is executed after the MyClass object and all its child objects are reconstructed. Which two actions should you perform?()
A.Apply the OnDeserializing attribute to the ProcessChildren method. B.Specify that MyClass implements the IDeserializationCallback interface. C.Specify that MyClass inherits from the ObjectManager class. D.Apply the OnSerialized attribute to the ProcessChildren method. E.Create a GetObjectData method that calls ProcessChildren. F.Create an OnDeserialization method that calls ProcessChildren.
多项选择题You are developing an application that receives events asynchronously. You create a WqlEventQuery instance to specify the events and event conditions to which the application must respond. You also create a ManagementEventWatcher instance to subscribe to events matching the query.You need to identify the other actions you must perform before the application can receive events asynchronously. Which two actions should you perform?()
A.Start listening for events by calling the Start method of the ManagementEventWatcher. B.Set up a listener for events by using the EventArrived event of the ManagementEventWatcher. C.Use the WaitForNextEvent method of the ManagementEventWatcher to wait for the events. D.Create an event handler class that has a method that receives an ObjectReadyEventArgs parameter. E.Set up a listener for events by using the Stopped event of the ManagementEventWatcher.
单项选择题您正在使用Microsoft Visual Studio 2005 IDE检查一个返回string的方法的输出信息,您指定这个方法的输出给一个命名为fName的变量,您需要写一个代码片段打印下面这一行信息 Test FaileD. 如果fName的值不为”JohnJohn””,您应该确定这个应该程序的代码持续的执行,您应该使用哪一个代码片段()
A.A B.B C.C D.D
单项选择题您正在创建一个共享的程序集的过程中。您要执行许多的集成测试,以确保程序集使用多个应用程序工作正常。要避免不断更新每个应用程序引用的程序集,则更新时。在由 DEVPATH 环境变量设置为共享的程序集的默认生成位置。您需要确保公共语言运行库 (CLR) 使用由 DEVPATH 找到共享程序集。你应该做什么?()