Create Os Message from Id and Object - Android Android OS

Android examples for Android OS:Message

Description

Create Os Message from Id and Object

Demo Code


//package com.java2s;
import android.os.Message;

public class Main {

    public static Message obtainMessage(int msgWhat, Object obj) {
        Message msg = new Message();
        msg.what = msgWhat;/*from w  ww  . j a  v a  2  s . c o m*/
        msg.obj = obj;
        return msg;
    }
}

Related Tutorials