// author: Andrew Thompson
// get at: http://www.physci.org/codes/
// version: 2004-05-09

/** Provide the name of this URL parameter. */
function getName() {
	return this.sName;
}

/** Provide the value of this URL parameter. */
function getValue() {
	return this.sValue;
}

/** Check if this is the 'paramName' URL parameter. */
function isParam( paramName ) {
	return ( this.sName==paramName );
}

/** Construct an URL parameter object, and attach the functions. */
function QueryParameter( paramName, paramValue ) {
	this.sName = paramName;
	var value;
	if (paramValue=='on') {
		value=true;
	} else {
		value = paramValue;
	}
	this.sValue = value;
	
	this.getName = getName;
	this.getValue = getValue;
	this.isParam = isParam;
}
