37        if ($a_value !== 
null) {
 
   38            $a_value = (float) $a_value;
 
   40        $this->longitude = $a_value;
 
   50        if ($a_value !== 
null) {
 
   51            $a_value = (float) $a_value;
 
   53        $this->latitude = $a_value;
 
   68        $this->zoom = max(1, abs((
int) $a_value));
 
   77            return ($this->
getLongitude() == $a_adt->getLongitude() &&
 
   78                $this->getLatitude() == $a_adt->getLatitude());
 
  105        $valid = parent::isValid();
 
  111        if ($long !== 
null && $lat !== 
null) {
 
  113            if ($long < -180 || $long > 180) {
 
  118            if ($lat < -90 || $lat > 90) {
 
  138                return $lng->txt(
"adt_error_longitude");
 
  141                return $lng->txt(
"adt_error_latitude");
 
  145                return parent::translateErrorCode($a_code);
 
An exception for terminatinating execution or to throw for unit testing.
ADT definition base class.
const ADT_VALIDATION_ERROR_LONGITUDE
setLatitude($a_value=null)
setLongitude($a_value=null)
isValidDefinition(ilADTDefinition $a_def)
Check if definition is valid for ADT.
getCheckSum()
Get unique checksum.
translateErrorCode($a_code)
Translate error-code to human-readable message.
isLarger(ilADT $a_adt)
Check if given ADT is larger than self.
isNull()
Is currently null.
reset()
Init property defaults.
isSmaller(ilADT $a_adt)
Check if given ADT is smaller than self.
const ADT_VALIDATION_ERROR_LATITUDE
isValid()
Is currently valid.
equals(ilADT $a_adt)
Check if given ADT equals self.
addValidationError($a_error_code)
Add validation error code.
getDefinition()
Get definition.