Package io.github.hapjava.services
Interface Service
-
- All Known Implementing Classes:
AccessoryInformationService
,AirPurifierService
,AirQualityService
,BasicFanService
,BatteryService
,CarbonDioxideSensorService
,CarbonMonoxideSensorService
,ContactSensorService
,DoorbellService
,DoorService
,FanService
,FaucetService
,FilterMaintenanceService
,GarageDoorOpenerService
,HAPProtocolInformationService
,HeaterCoolerService
,HumidifierDehumidifierService
,HumiditySensorService
,InputSourceService
,IrrigationSystemService
,LeakSensorService
,LightbulbService
,LightSensorService
,LockMechanismService
,MicrophoneService
,MotionSensorService
,OccupancySensorService
,OutletService
,SecuritySystemService
,ServiceLabelService
,SlatService
,SmartSpeakerService
,SmokeSensorService
,SpeakerService
,StatelessProgrammableSwitchService
,SwitchService
,TelevisionService
,TelevisionSpeakerService
,TemperatureSensorService
,ThermostatService
,ValveService
,WindowCoveringService
,WindowService
public interface Service
Interface for a Service offered by an accessory.- Author:
- Andy Lintner
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
addLinkedService(Service service)
Add linked servicesjava.util.List<Characteristic>
getCharacteristics()
Characteristics are the variables offered for reading, updating, and eventing by the Service over the HomeKit protocol.java.util.List<Service>
getLinkedServices()
List of all the services to which the service linksjava.lang.String
getType()
The type is a UUID that uniquely identifies the type of Service offered.
-
-
-
Method Detail
-
getCharacteristics
java.util.List<Characteristic> getCharacteristics()
Characteristics are the variables offered for reading, updating, and eventing by the Service over the HomeKit protocol.It is important to maintain the order of this list and not change its contents between invocations, or a pairing error will result.
- Returns:
- the list of Characteristics.
-
getType
java.lang.String getType()
The type is a UUID that uniquely identifies the type of Service offered. Apple defines several types for standard Services, however UUIDs outside this range are allowed for custom Services.- Returns:
- A string representation of the UUID, with hexadecimal digits in the format ########-####-####-####-############.
-
getLinkedServices
java.util.List<Service> getLinkedServices()
List of all the services to which the service links- Returns:
- the list of linked services.
-
addLinkedService
void addLinkedService(Service service)
Add linked services- Parameters:
service
- linked service
-
-