Browse Source

Create a apir of interfaces for the repositories

pull/26/head
Starbeamrainbowlabs 4 years ago
parent
commit
bbd08b439e
Signed by: sbrl
GPG Key ID: 1BE5172E637709C2
  1. 2
      build
  2. 7
      logic/Repositories/IMeasurementDataRepository.php
  3. 8
      logic/Repositories/IMeasurementTypeRepository.php

2
build

@ -100,7 +100,7 @@ function task_database { @@ -100,7 +100,7 @@ function task_database {
sleep 1;
mysql --host 127.0.0.1 --port 3306 --database "${database_name}" --user "${USER}" --password;
kill $!; wait; sleep 0.5;
kill "${ssh_pid}"; wait; sleep 0.5;
task_end $?;
}

7
logic/Repositories/IMeasurementDataRepository.php

@ -0,0 +1,7 @@ @@ -0,0 +1,7 @@
<?php
namespace AirQuality\Repositories;
interface IMeasurementDataRepository {
public function get_readings_by_date(DateTime $datetime, string $reading_type);
}

8
logic/Repositories/IMeasurementTypeRepository.php

@ -0,0 +1,8 @@ @@ -0,0 +1,8 @@
<?php
namespace AirQuality\Repositories;
interface IMeasurementTypeRepository {
public function is_valid_type();
public function get_all_types();
}
Loading…
Cancel
Save