Lotus Software logo
IBM Lotus Domino Designer 8.5
Versions 8.5, 8.5.1, 8.5.2, and 8.5.3






hasOwnProperty (JavaScript)

Checks whether a string has a specified property.

Defined in

RegExp (JavaScript)

Syntax

hasOwnProperty(property:string) : boolean
Parameters Description
property The name of a property.
Return value Description
boolean True if the object has the property; otherwise false.

Examples

This example returns true or false for three properties.
var regexp = /(Moscow)/;
return "constructor = " + regexp.hasOwnProperty("constructor") +
	"\nlength = " + regexp.hasOwnProperty("length") +
	"\nprototype = " + regexp.hasOwnProperty("prototype")



Library | Support | Terms of use |

Last updated: Tuesday, September 20, 2011