Question:You create a Microsoft ASP.NET application by using the Microsoft .NET Framework version 3.5. To create a JavaScript class named Employee, you write the following code segment. (Line numbers are included for reference only.)

01 Type.registerNamespace("HR");
02 HR.Employee = function(firstName, lastName) {
03 this._firstName = firstName;
04 this._lastName = lastName;
05 }
07 HR.Employee.prototype.get_FirstName = function() {
08 return this._firstName;
09 }
11 HR.Employee.prototype.set_FirstName = function(first) {
12 this._firstName = first;
13 }
15 HR.Employee.prototype.get_LastName = function() {
16 return this._lastName;
17 }
19 HR.Employee.prototype.set_LastName = function(last) {
20 this._lastName = last; 21 } 23 HR.Employee.prototype.dispose = function() {
24 }

You need to register the Employee class with the ASP.NET AJAX Framework to meet the following requirements:
The Employee class derives from a class named Person.
The Employee class implements the Sys.IDisposable JavaScript interface.
Which code segment should you add at line 25?

 

A HR.Employee.registerInterface("Sys.IDisposable");
HR.Employee.registerClass("HR.Employee", Person); 

B HR.Employee.registerClass("HR.Employee", Person, Sys.IDisposable); 

C HR.Employee.registerInterface("Sys.IDisposable");
HR.Employee.registerClass("Employee", Person); 

D HR.Employee.registerClass("Employee", Person, Sys.IDisposable); 

+ Answer
+ Report
Total Preview: 832

Copyright © 2024. Powered by Intellect Software Ltd