当前位置: 首页>>代码示例>>Java>>正文


Java RemoteException.printStackTrace方法代码示例

本文整理汇总了Java中android.os.RemoteException.printStackTrace方法的典型用法代码示例。如果您正苦于以下问题:Java RemoteException.printStackTrace方法的具体用法?Java RemoteException.printStackTrace怎么用?Java RemoteException.printStackTrace使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在android.os.RemoteException的用法示例。


在下文中一共展示了RemoteException.printStackTrace方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: updateProgress

import android.os.RemoteException; //导入方法依赖的package包/类
private void updateProgress() {
    int progress;
    int duration = (int) currentSong.getDuration();
    final float phoneWidth = Utils.getMetrics(activity).widthPixels;

    try {
        progress = mControl.getProgress();
        int width = (int) (phoneWidth * (progress / (float) duration));
        FrameLayout.LayoutParams params = (FrameLayout.LayoutParams) mProgress.getLayoutParams();
        params.width = width;
        mProgress.setLayoutParams(params);
        mProgress.invalidate();

    } catch (RemoteException e) {
        e.printStackTrace();
    }
}
 
开发者ID:DuanJiaNing,项目名称:Musicoco,代码行数:18,代码来源:BottomNavigationController.java

示例2: notifyAppInstalled

import android.os.RemoteException; //导入方法依赖的package包/类
private void notifyAppInstalled(PackageSetting setting, int userId) {
    final String pkg = setting.packageName;
    int N = mRemoteCallbackList.beginBroadcast();
    while (N-- > 0) {
        try {
            if (userId == -1) {
                sendInstalledBroadcast(pkg);
                mRemoteCallbackList.getBroadcastItem(N).onPackageInstalled(pkg);
                mRemoteCallbackList.getBroadcastItem(N).onPackageInstalledAsUser(0, pkg);

            } else {
                mRemoteCallbackList.getBroadcastItem(N).onPackageInstalledAsUser(userId, pkg);
            }
        } catch (RemoteException e) {
            e.printStackTrace();
        }
    }
    mRemoteCallbackList.finishBroadcast();
    VAccountManagerService.get().refreshAuthenticatorCache(null);
}
 
开发者ID:coding-dream,项目名称:TPlayer,代码行数:21,代码来源:VAppManagerService.java

示例3: getIconsID

import android.os.RemoteException; //导入方法依赖的package包/类
private int[] getIconsID() {
    int[] res = {
            R.drawable.ic_create_new_folder_black_24dp,
            R.drawable.ic_art_track_black_24dp,
            R.drawable.ic_delete_forever_black_24dp,
            R.drawable.ic_clear_black_24dp
    };

    try {
        int sheetID = control.getPlayListId();
        int[] ids;
        if (sheetID < 0) {
            ids = Arrays.copyOf(res, 3);
        } else {
            ids = res;
        }
        return ids;
    } catch (RemoteException e) {
        e.printStackTrace();
    }

    return res;
}
 
开发者ID:DuanJiaNing,项目名称:Musicoco,代码行数:24,代码来源:SongOption.java

示例4: sendCancelQueue

import android.os.RemoteException; //导入方法依赖的package包/类
/**
 * 取消排队
 */
public void sendCancelQueue() {
    try {
        mMessageManager.sendEventMessage(SocketParams.getCancelQueueParams(), new IPCCallBack.Stub() {
            @Override
            public void onResult(int code, String result) throws RemoteException {
                getMvpView().cancelQueue(code);
            }
        });
    } catch (RemoteException e) {
        e.printStackTrace();
    }
}
 
开发者ID:Zyj163,项目名称:yyox,代码行数:16,代码来源:IMPresenter.java

示例5: sendMsgToForeService

import android.os.RemoteException; //导入方法依赖的package包/类
private void sendMsgToForeService(Message msg){
    if(mServiceMessager == null){
        return;
    }
    try {
        mServiceMessager.send(msg);
    } catch (RemoteException e) {
        e.printStackTrace();
    }
}
 
开发者ID:stdnull,项目名称:RunMap,代码行数:11,代码来源:TrackPresenterImpl.java

示例6: onConnected

import android.os.RemoteException; //导入方法依赖的package包/类
@Override
public void onConnected() {
    super.onConnected();
    Log.d(TAG, "on connected");
    try {
        connectToSession(mMediaBrowser.getSessionToken());
    } catch (RemoteException e) {
        e.printStackTrace();
        Log.d(TAG, "can not connect to media controller");
    }
}
 
开发者ID:Jaysaw,项目名称:NovaMusicPlayer,代码行数:12,代码来源:MainActivity.java

示例7: confirmCredentials

import android.os.RemoteException; //导入方法依赖的package包/类
public void confirmCredentials(IAccountManagerResponse response, Account account, Bundle options, boolean expectActivityLaunch) {
	try {
		getRemote().confirmCredentials(VUserHandle.myUserId(), response, account, options, expectActivityLaunch);
	} catch (RemoteException e) {
		e.printStackTrace();
	}
}
 
开发者ID:codehz,项目名称:container,代码行数:8,代码来源:VAccountManager.java

示例8: updateFavorite

import android.os.RemoteException; //导入方法依赖的package包/类
public void updateFavorite() {
    try {
        Song song = control.currentSong();
        if (song != null) {
            DBSongInfo info = dbMusicoco.getSongInfo(song);
            boolean isFavorite = info != null && info.favorite;
            songOption.updateCurrentFavorite(isFavorite, false);
        }
    } catch (RemoteException e) {
        e.printStackTrace();
    }
}
 
开发者ID:DuanJiaNing,项目名称:Musicoco,代码行数:13,代码来源:BottomNavigationController.java

示例9: isReadyRemote

import android.os.RemoteException; //导入方法依赖的package包/类
/**
 * 检查所有的服务是否已经就位(已经添加到{@link ServiceManagerThread})
 * @return
 */
private boolean isReadyRemote(){
	Parcel data = Parcel.obtain();
	Parcel reply = Parcel.obtain();
	try {
		mRemoteServiceManager.transact(ServiceContext.READY_REMOTE, data, reply, 0);
		int result = reply.readInt();
		
		if(result == ServiceContext.SUCCESS) {
			
			log("remote service manager ready");
			
			return true;
		}
		
		log("remote service manager not ready");
		
		return false;
	} catch (RemoteException e) {
		e.printStackTrace();
		log("getService exception");
		return false;
	} finally {
		data.recycle();
		reply.recycle();
	}
}
 
开发者ID:devyok,项目名称:DroidIPC,代码行数:31,代码来源:ServiceManagerImpl.java

示例10: invalidateAuthToken

import android.os.RemoteException; //导入方法依赖的package包/类
public void invalidateAuthToken(String accountType, String authToken) {
	try {
		getRemote().invalidateAuthToken(VUserHandle.myUserId(), accountType, authToken);
	} catch (RemoteException e) {
		e.printStackTrace();
	}
}
 
开发者ID:7763sea,项目名称:VirtualHook,代码行数:8,代码来源:VAccountManager.java

示例11: onDestroy

import android.os.RemoteException; //导入方法依赖的package包/类
@Override
protected void onDestroy() {
    //解绑Service
    if (mBound && mService != null) {
        try {
            mService.send(Message.obtain(null, MsgService.MSG_UNREGISTER));
        } catch (RemoteException e) {
            e.printStackTrace();
        }
        mService =null;
        unbindService(mConnection);
        mBound = false;
    }
    super.onDestroy();
}
 
开发者ID:TommyFen,项目名称:NaiveDemos,代码行数:16,代码来源:BleServiceTestActivity.java

示例12: processRestarted

import android.os.RemoteException; //导入方法依赖的package包/类
public void processRestarted(String packageName, String processName, int userId) {
    try {
        getService().processRestarted(packageName, processName, userId);
    } catch (RemoteException e) {
        e.printStackTrace();
    }
}
 
开发者ID:7763sea,项目名称:VirtualHook,代码行数:8,代码来源:VActivityManager.java

示例13: handleApplicationCrash

import android.os.RemoteException; //导入方法依赖的package包/类
public void handleApplicationCrash() {
    try {
        getService().handleApplicationCrash();
    } catch (RemoteException e) {
        e.printStackTrace();
    }
}
 
开发者ID:coding-dream,项目名称:TPlayer,代码行数:8,代码来源:VActivityManager.java

示例14: sendMessageWithDevice

import android.os.RemoteException; //导入方法依赖的package包/类
private void sendMessageWithDevice(int what) {
    if (mHealthService == null) {
        Log.d(TAG, "Health Service not connected.");
        return;
    }

    try {
        mHealthService.send(Message.obtain(null, what, mDevice));
    } catch (RemoteException e) {
        Log.w(TAG, "Unable to reach service.");
        e.printStackTrace();
    }
}
 
开发者ID:appledong,项目名称:AndroidthingsStudy,代码行数:14,代码来源:BluetoothHDPActivity.java

示例15: addAccount

import android.os.RemoteException; //导入方法依赖的package包/类
public void addAccount(IAccountManagerResponse response, String accountType, String authTokenType, String[] requiredFeatures, boolean expectActivityLaunch, Bundle optionsIn) {
	try {
		getRemote().addAccount(VUserHandle.myUserId(), response, accountType, authTokenType, requiredFeatures, expectActivityLaunch, optionsIn);
	} catch (RemoteException e) {
		e.printStackTrace();
	}
}
 
开发者ID:codehz,项目名称:container,代码行数:8,代码来源:VAccountManager.java


注:本文中的android.os.RemoteException.printStackTrace方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。