getClusterName (NotesDbDirectory - JavaScript)

Returns the name of the cluster containing a database directory.

Defined in

NotesDbDirectory

Syntax

getClusterName() : string

getClusterName(servername:string) : string

Parameter Description
servername The full hierarchical name (can be abbreviated) of the server. Defaults to the current server.
Return value Description
string The name of the cluster.

Examples

This computed field displays the cluster name for a database directory set elsewhere on the page.
if (sessionScope.dbdir != null) {
	var dbdir:NotesDbDirectory = sessionScope.dbdir;
	var cluster:string = dbdir.getClusterName("Sales/Acme"); // specifies a server
//	var cluster:string = dbdir.getClusterName(); // uses the current server
	if (cluster.isEmpty()) {
		cluster = "No cluster";
	}
	return "Cluster name: " + cluster;
}