Cursor.prototype

NES2+, ECMAScript1.0+Syntax

							cursor.prototype.method = methodName
							cursor.prototype.property
						

Description

The prototype property of the Cursor object allows you to create new properties and methods of the object. If you are adding a method, you set the instance equal to the methodName of the method you have defined.

Example

Listing 8.35 creates a new property and method of the Cursor object. An instance is created and the new property is set. The new method is then called to verify the property, and, if it is incorrect, an error is written to the page.

Listing 8.35 Using the prototype Property to Create a New Property and Method
 <SERVER> // Define the method that we prototyped function verifySELECT(){ // Check to see if the ...

Get Pure JavaScript now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.