Code example for ClipboardManager

Methods: addPrimaryClipChangedListener

    public void onCreate() { 
    	Log.i(TAG, "Service started");
    	ClipboardManager clipBoard = (ClipboardManager)getSystemService(CLIPBOARD_SERVICE);
        clipBoard.addPrimaryClipChangedListener( this );
    	started = true;
    public int onStartCommand(Intent intent, int flags, int startId) {
        // The service is starting, due to a call to startService() 
        return mStartMode;
    public IBinder onBind(Intent intent) {
        // TODO: Return the communication channel to the service. 
        throw new UnsupportedOperationException("Not implemented");
        //return mBinder;