ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
ilGeoLocation Class Reference
+ Collaboration diagram for ilGeoLocation:

Public Member Functions

 __construct (int $a_id, string $a_title, float $a_latitude, float $a_longitude, \DateTimeImmutable $a_expiration_timestamp)
 
 getId ()
 
 getTitle ()
 
 getLatitude ()
 
 getLongitude ()
 
 getExpirationAsTimestamp ()
 
 getExpirationAsImmutableDateTime ()
 

Protected Attributes

 $id
 
 $title
 
 $latitude
 
 $longitude
 
 $expiration_timestamp
 

Detailed Description

Definition at line 3 of file ilGeoLocation.php.

Constructor & Destructor Documentation

◆ __construct()

ilGeoLocation::__construct ( int  $a_id,
string  $a_title,
float  $a_latitude,
float  $a_longitude,
\DateTimeImmutable  $a_expiration_timestamp 
)

Definition at line 20 of file ilGeoLocation.php.

26  {
27  $this->id = $a_id;
28  $this->title = $a_title;
29  // In a real world example we might want to conduct more checks on latitude
30  // and longitude here.
31  $this->latitude = $a_latitude;
32  $this->longitude = $a_longitude;
33  $this->expiration_timestamp = $a_expiration_timestamp;
34  }

Member Function Documentation

◆ getExpirationAsImmutableDateTime()

ilGeoLocation::getExpirationAsImmutableDateTime ( )

Definition at line 61 of file ilGeoLocation.php.

References $expiration_timestamp.

61  : \DateTimeImmutable
62  {
64  }

◆ getExpirationAsTimestamp()

ilGeoLocation::getExpirationAsTimestamp ( )

Definition at line 56 of file ilGeoLocation.php.

Referenced by ilGeoLocationFileMockRepository\updateGeoLocation(), and ilGeoLocationDBRepository\updateGeoLocation().

56  : float
57  {
58  return $this->expiration_timestamp->getTimestamp();
59  }
+ Here is the caller graph for this function:

◆ getId()

ilGeoLocation::getId ( )

Definition at line 36 of file ilGeoLocation.php.

References $id.

Referenced by ilGeoLocationFileMockRepository\updateGeoLocation(), and ilGeoLocationDBRepository\updateGeoLocation().

36  : int
37  {
38  return $this->id;
39  }
+ Here is the caller graph for this function:

◆ getLatitude()

ilGeoLocation::getLatitude ( )

Definition at line 46 of file ilGeoLocation.php.

References $latitude.

Referenced by ilGeoLocationFileMockRepository\updateGeoLocation(), and ilGeoLocationDBRepository\updateGeoLocation().

46  : float
47  {
48  return $this->latitude;
49  }
+ Here is the caller graph for this function:

◆ getLongitude()

ilGeoLocation::getLongitude ( )

Definition at line 51 of file ilGeoLocation.php.

References $longitude.

Referenced by ilGeoLocationFileMockRepository\updateGeoLocation(), and ilGeoLocationDBRepository\updateGeoLocation().

51  : float
52  {
53  return $this->longitude;
54  }
+ Here is the caller graph for this function:

◆ getTitle()

ilGeoLocation::getTitle ( )

Definition at line 41 of file ilGeoLocation.php.

References $title.

Referenced by ilGeoLocationFileMockRepository\updateGeoLocation(), and ilGeoLocationDBRepository\updateGeoLocation().

41  : string
42  {
43  return $this->title;
44  }
+ Here is the caller graph for this function:

Field Documentation

◆ $expiration_timestamp

ilGeoLocation::$expiration_timestamp
protected

Definition at line 18 of file ilGeoLocation.php.

Referenced by getExpirationAsImmutableDateTime().

◆ $id

ilGeoLocation::$id
protected

Definition at line 6 of file ilGeoLocation.php.

Referenced by getId().

◆ $latitude

ilGeoLocation::$latitude
protected

Definition at line 12 of file ilGeoLocation.php.

Referenced by getLatitude().

◆ $longitude

ilGeoLocation::$longitude
protected

Definition at line 15 of file ilGeoLocation.php.

Referenced by getLongitude().

◆ $title

ilGeoLocation::$title
protected

Definition at line 9 of file ilGeoLocation.php.

Referenced by getTitle().


The documentation for this class was generated from the following file: