Skip to content

Commit ce74e0a

Browse files
chore: create actuator repository
1 parent b652ec5 commit ce74e0a

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
/*
2+
* Copyright (c) 2023. Smart Operating Block
3+
*
4+
* Use of this source code is governed by an MIT-style
5+
* license that can be found in the LICENSE file or at
6+
* https://opensource.org/licenses/MIT.
7+
*/
8+
9+
package usecase.repository;
10+
11+
import entity.actuator.ActuatorID;
12+
import entity.actuator.ActuatorType;
13+
import entity.room.RoomID;
14+
15+
import java.util.Optional;
16+
17+
/**
18+
* Interface that models the repository to manage Actuators.
19+
*/
20+
public interface ActuatorRepository {
21+
/**
22+
* Method to find an actuator of a specific type inside a room specified with its id.
23+
* @param actuatorType the type of actuator to find
24+
* @param roomID the room id where the actuator should be placed.
25+
* @return an optional that contains the actuator id if found, empty otherwise.
26+
*/
27+
Optional<ActuatorID> findActuatorInRoom(ActuatorType actuatorType, RoomID roomID);
28+
}

0 commit comments

Comments
 (0)