/**
* Gère l'affichage des tarifs de location d'un produit.
*
* @param Product product Produit pour lequel afficher les tarifs
* @access public
* @since 1.0
*/
function DisplayProductPrice(product) {
	/**
	 * Produit pour lequel afficher les tarifs.
	 *
	 * @var Product
	 * @access private
	 * @since 1.0
	 */
	this.product = product;
	
	/**
	* Affiche les tarifs de location du produit sélectionné.
	*
	* @param String Identifiant du calque où afficher les informations
	* @access public
	* @since 1.0
	*/
	this.display = function(divId) {
		price = this.product.getPrice();
		
		var html = '';
		html += '<table class="tarif">';
		html += '<tr>';
		for(var i = 0; i < price.length; i++) {
			html += '<th>' + price[i].duration + '</th>';
		}
		html += '</tr>';
		html += '<tr>';
		for(var i = 0; i < price.length; i++) {
			html += '<td>' + formatPrice(price[i].value) + ' &euro;</td>';
		}
		html += '</tr>';
		html += '</table>';
		
		document.getElementById(divId).innerHTML = html;
	}
	
	/**
	* Renvoit les informations sur l'objet.
	*
	* @return String Information sur l'objet
	* @access public
	* @since 1.0
	*/
	this.toString = function() {
		return 'product = ' + this.value;
	}
}
