Code example for SipProfile

Methods: getUriString

0
 
		try { 
			SipProfile.Builder builder = new SipProfile.Builder(username, domain);
			builder.setPassword(password);
			mSipProfile = builder.build();
			Log.e(TAG, "profile " + mSipProfile.getUriString());
 
			Intent i = new Intent();
			i.setAction("android.andSip.INCOMING_CALL");
			PendingIntent pi = PendingIntent.getBroadcast(this, 0, i, Intent.FILL_IN_DATA);
			mSipManager.open(mSipProfile, pi, null);
			// 
			mSipManager.setRegistrationListener(mSipProfile.getUriString(), registrationListener);
		} catch (Exception e) {
			e.printStackTrace();
		} 
	} 
 
	/** 
	 * 通过Sip服务器呼叫对方,建立通话 
Stop searching for code, let great code find you!  Add Codota to your java IDE