Refactor LinphonecoreFactory
This commit is contained in:
parent
723ecc0c26
commit
83d0690898
6 changed files with 43 additions and 6 deletions
Binary file not shown.
|
@ -227,7 +227,7 @@ public class LinphoneService extends Service implements LinphoneCoreListener {
|
||||||
String lIdentity = "sip:"+lUserName+"@"+lDomain;
|
String lIdentity = "sip:"+lUserName+"@"+lDomain;
|
||||||
try {
|
try {
|
||||||
if (lDefaultProxyConfig == null) {
|
if (lDefaultProxyConfig == null) {
|
||||||
lDefaultProxyConfig = mLinphoneCore.createProxyConfig(lIdentity, lProxy, null,true);
|
lDefaultProxyConfig = LinphoneCoreFactory.instance().createProxyConfig(lIdentity, lProxy, null,true);
|
||||||
mLinphoneCore.addProxyConfig(lDefaultProxyConfig);
|
mLinphoneCore.addProxyConfig(lDefaultProxyConfig);
|
||||||
mLinphoneCore.setDefaultProxyConfig(lDefaultProxyConfig);
|
mLinphoneCore.setDefaultProxyConfig(lDefaultProxyConfig);
|
||||||
|
|
||||||
|
|
|
@ -28,4 +28,29 @@ class LinphoneAuthInfoImpl implements LinphoneAuthInfo {
|
||||||
protected void finalize() throws Throwable {
|
protected void finalize() throws Throwable {
|
||||||
delete(nativePtr);
|
delete(nativePtr);
|
||||||
}
|
}
|
||||||
|
public String getPassword() {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
throw new RuntimeException("not implemeneted yet");
|
||||||
|
}
|
||||||
|
public String getRealm() {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
throw new RuntimeException("not implemeneted yet");
|
||||||
|
}
|
||||||
|
public String getUsername() {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
throw new RuntimeException("not implemeneted yet");
|
||||||
|
}
|
||||||
|
public void setPassword(String password) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
throw new RuntimeException("not implemeneted yet");
|
||||||
|
|
||||||
|
}
|
||||||
|
public void setRealm(String realm) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
throw new RuntimeException("not implemeneted yet");
|
||||||
|
}
|
||||||
|
public void setUsername(String username) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
throw new RuntimeException("not implemeneted yet");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -72,10 +72,7 @@ class LinphoneCoreImpl implements LinphoneCore {
|
||||||
addAuthInfo(nativePtr,((LinphoneAuthInfoImpl)info).nativePtr);
|
addAuthInfo(nativePtr,((LinphoneAuthInfoImpl)info).nativePtr);
|
||||||
}
|
}
|
||||||
|
|
||||||
public synchronized LinphoneProxyConfig createProxyConfig(String identity, String proxy,String route,boolean enableRegister) throws LinphoneCoreException {
|
|
||||||
isValid();
|
|
||||||
return new LinphoneProxyConfigImpl(identity, proxy, route,enableRegister);
|
|
||||||
}
|
|
||||||
|
|
||||||
public synchronized LinphoneProxyConfig getDefaultProxyConfig() {
|
public synchronized LinphoneProxyConfig getDefaultProxyConfig() {
|
||||||
isValid();
|
isValid();
|
||||||
|
|
|
@ -97,4 +97,19 @@ class LinphoneProxyConfigImpl implements LinphoneProxyConfig {
|
||||||
public void setDialEscapePlus(boolean value) {
|
public void setDialEscapePlus(boolean value) {
|
||||||
setDialEscapePlus(nativePtr,value);
|
setDialEscapePlus(nativePtr,value);
|
||||||
}
|
}
|
||||||
|
public String getIdentity() {
|
||||||
|
throw new RuntimeException("not implemeneted yet");
|
||||||
|
}
|
||||||
|
public String getProxy() {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
throw new RuntimeException("not implemeneted yet");
|
||||||
|
}
|
||||||
|
public boolean isRegistered() {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
throw new RuntimeException("not implemeneted yet");
|
||||||
|
}
|
||||||
|
public boolean registerEnabled() {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
throw new RuntimeException("not implemeneted yet");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit da5f0737578936881ed77d88525cb9bf6cc4961b
|
Subproject commit 572b696529119810350e083cec72e59b2d3e75d5
|
Loading…
Reference in a new issue