public function validatesUniquenessOf($attrs)
	{
		$configuration = array_merge(self::$DEFAULT_VALIDATION_OPTIONS, array(
			'message' => Errors::$DEFAULT_ERROR_MESSAGES['unique']
		));
		// Retrieve connection from model for quote_name method
		$connection = $this->klass->getMethod('connection')->invoke(null);

		foreach ($attrs as $attr)
		{
			$options = array_merge($configuration, $attr);
			$pk = $this->model->get_primary_key();
			$pk_value = $this->model->$pk[0];

			if (is_array($options[0]))
			{
				$add_record = join("_and_", $options[0]);
				$fields = $options[0];
			}
			else
			{
				$add_record = $options[0];
				$fields = array($options[0]);
			}

			$sql = "";
			$conditions = array("");
			$pk_quoted = $connection->quote_name($pk[0]);
			if ($pk_value === null)
				$sql = "{$pk_quoted} IS NOT NULL";
			else
			{
				$sql = "{$pk_quoted} != ?";
				array_push($conditions,$pk_value);
			}

			foreach ($fields as $field)
			{
				$field = $this->model->get_real_attribute_name($field);
				$quoted_field = $connection->quote_name($field);
				$sql .= " AND {$quoted_field}=?";
				array_push($conditions,$this->model->$field);
			}

			$conditions[0] = $sql;

			if ($this->model->exists(array('conditions' => $conditions)))
				$this->record->add($add_record, $options['message']);
		}
	}