Code example for HttpResponseException

Methods: egetMessagegetStatusCode

0
                query.put("tel", params[1]);
                query.put("devid", params[2]);
                query.put("simserial", params[3]);
                RestfulClient.get(params[0], query, pullParser);
            } catch (HttpResponseException e){
                if(404 == e.getStatusCode()){
                    Log.d(TAG, "this android user is not found. try to regist.");
                    return RESULT_STATE_NOT_REGIST;
                } else { 
                    Log.e(TAG, e.getMessage(), e);
                    return RESULT_STATE_SERVER_ERROR;
                } 
            } catch (Exception e) {
                Log.e(TAG, e.getMessage(), e);
                return RESULT_STATE_CLIENT_ERROR;
            } 
            if(pullParser.resultIsSuccess()){
                return RESULT_STATE_OK;
            } else { 
                return RESULT_STATE_NOT_REGIST;
Experience pair programming with AI  Get Codota for Java