I는 다음과 같습니다이 코드를 (/ 자바 안드로이드에 새로운)를 trigger.io 모듈에 대한 진동 기능을 만들려고하지만, 나는이
The method getSystemService(String) is undefined for the type API
가 계속
라이브러리 등을 가져 오지 않았습니까?
public class API {
public static void pulse(final ForgeTask task){
Vibrator v = (Vibrator) getSystemService(Context.VIBRATOR_SERVICE);
// Output yes if can vibrate, no otherwise
if (v.hasVibrator()) {
v.vibrate(400);
}
}
}
동일한 응답으로 trigger.io에서 답장을 얻었으나이 문제가 해결되었습니다! –