本文整理匯總了Java中com.odoo.core.rpc.listeners.OdooSyncResponse.get方法的典型用法代碼示例。如果您正苦於以下問題:Java OdooSyncResponse.get方法的具體用法?Java OdooSyncResponse.get怎麽用?Java OdooSyncResponse.get使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.odoo.core.rpc.listeners.OdooSyncResponse
的用法示例。
在下文中一共展示了OdooSyncResponse.get方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: authenticate
import com.odoo.core.rpc.listeners.OdooSyncResponse; //導入方法依賴的package包/類
public OUser authenticate(String username, String password, String database) {
OdooSyncResponse response = new OdooSyncResponse();
authenticate(username, password, database, null, response);
OdooResult userResult = response.get().result;
if (!(userResult.get("uid") instanceof Boolean)) {
userResult.put("username", username);
bindOdooSession(userResult);
generateUserObject(username, password, database, userResult, null, response);
if (response.getObject() != null)
return (OUser) response.getObject();
}
return null;
}
示例2: validateResult
import com.odoo.core.rpc.listeners.OdooSyncResponse; //導入方法依賴的package包/類
private OdooResult validateResult(OdooSyncResponse response) {
OdooLog.d("SYNC_RESPONSE:" + response);
if (response.get() == null) {
return null;
} else {
if (response.get().result != null) {
return response.get().result;
} else {
OdooResult error = new OdooResult();
error.put("error", response.get().error);
return error;
}
}
}
示例3: authenticate
import com.odoo.core.rpc.listeners.OdooSyncResponse; //導入方法依賴的package包/類
public OUser authenticate(String username, String password, String database) {
OdooSyncResponse response = new OdooSyncResponse();
authenticate(username, password, database, null, response);
OdooResult userResult = response.get().result;
if (!(userResult.get("uid") instanceof Boolean)) {
userResult.put("username", username);
bindOdooSession(userResult);
generateUserObject(username, password, database, null, response);
if (response.getObject() != null)
return (OUser) response.getObject();
}
return null;
}