https://github.com/egoing/java-iot 에서 라이브러리를 다운 받고 넣어주면
이렇게 뜬당
import org.opentutorials.iot.Elevator;
import org.opentutorials.iot.Lighting;
import org.opentutorials.iot.Security;
public class okayJava {
public static void main(String[] args) {
Stirng id = "JAVA APT 507";
// elevator call
Elevator myElevator = new Elevator(id);
myElevator.callForUp(1);
// Security off
Security mySecurity = new Security(id);
mySecurity.off();
// light on
Lighting hallLamp = new Lighting("JAVA APT 507 / HALL LAMP");
hallLamp.on();
Lighting floorLamp = new Lighting("JAVA APT 507 / HALL LAMP");
floorLamp.on();
}
}
이런식으로 라이브러리를 활용할 수 있다.
그러면 짜라란~