안드로이드 스레드

    안드로이드 스레드(Thread) 개념

    1) Thread 클래스를 상속 2) Runnable 인터페이스를 구현한 클래스를 구현하고 Thread 의 인스턴스를 연결 [Thread] Thread를 상속할때는 새로운 스레드가 실행할 코드를 run() 메소드에 오버라이드 시킨다 Runnable 객체를 매개변수로 받아 객체를 생성할수 있다. Thread() Thread(Runnable) Thread(Runnable, String threadName) Thread(ThreadGroup, Runnable, String threadName) start() :: 메소드는 run() 메소드를 호출한다. sleep(long milisecs) :: 지정된 초만큼 멈춘다. sleep(long milisecs, int nanosecs) :: long + int 시간동..