You are here

public function UcAddressesAddressBook::setPerformanceHint in Ubercart Addresses 7

Same name and namespace in other branches
  1. 6.2 class/UcAddressesAddressBook.class.php \UcAddressesAddressBook::setPerformanceHint()

Sets the performance hint setting.

Parameters

int $hint: The hint to set.

Return value

void

Throws

UcAddressesInvalidParameterException

File

class/UcAddressesAddressBook.class.php, line 227
Contains the UcAddressesAddressBook class.

Class

UcAddressesAddressBook
The address book class

Code

public function setPerformanceHint($hint) {
  switch ($hint) {
    case self::PERF_HINT_LOAD_ONE:
    case self::PERF_HINT_LOAD_ALL:
      $this->performanceHint = $hint;
      break;
    default:
      throw new UcAddressesInvalidParameterException(t('Tried to set an invalid performance hint for the address book'));
  }
}