mirror of
				https://github.com/owncloud/android-library.git
				synced 2025-10-31 10:27:45 +00:00 
			
		
		
		
	Handle 503 code error
This commit is contained in:
		
							parent
							
								
									45e70f5906
								
							
						
					
					
						commit
						0fdc5694f1
					
				| @ -3,7 +3,7 @@ buildscript { | |||||||
|         jcenter() |         jcenter() | ||||||
|     } |     } | ||||||
|     dependencies { |     dependencies { | ||||||
|         classpath 'com.android.tools.build:gradle:2.2.0' |         classpath 'com.android.tools.build:gradle:2.2.3' | ||||||
|     } |     } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | |||||||
| @ -34,6 +34,7 @@ import java.net.SocketException; | |||||||
| import java.net.SocketTimeoutException; | import java.net.SocketTimeoutException; | ||||||
| import java.net.UnknownHostException; | import java.net.UnknownHostException; | ||||||
| import java.util.ArrayList; | import java.util.ArrayList; | ||||||
|  | 
 | ||||||
| import android.accounts.Account; | import android.accounts.Account; | ||||||
| import android.accounts.AccountsException; | import android.accounts.AccountsException; | ||||||
| 
 | 
 | ||||||
| @ -61,7 +62,8 @@ import javax.net.ssl.SSLException; | |||||||
|  */ |  */ | ||||||
| public class RemoteOperationResult implements Serializable { | public class RemoteOperationResult implements Serializable { | ||||||
| 
 | 
 | ||||||
| 	/** Generated - should be refreshed every time the class changes!! */; |     /** Generated - should be refreshed every time the class changes!! */ | ||||||
|  |     ; | ||||||
|     private static final long serialVersionUID = 1129130415603799707L; |     private static final long serialVersionUID = 1129130415603799707L; | ||||||
| 
 | 
 | ||||||
|     private static final String TAG = RemoteOperationResult.class.getSimpleName(); |     private static final String TAG = RemoteOperationResult.class.getSimpleName(); | ||||||
| @ -112,7 +114,8 @@ public class RemoteOperationResult implements Serializable { | |||||||
|         WRONG_SERVER_RESPONSE, |         WRONG_SERVER_RESPONSE, | ||||||
|         INVALID_CHARACTER_DETECT_IN_SERVER, |         INVALID_CHARACTER_DETECT_IN_SERVER, | ||||||
|         DELAYED_FOR_WIFI, |         DELAYED_FOR_WIFI, | ||||||
|         LOCAL_FILE_NOT_FOUND |         LOCAL_FILE_NOT_FOUND, | ||||||
|  |         MAINTENANCE_MODE | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     private boolean mSuccess = false; |     private boolean mSuccess = false; | ||||||
| @ -160,6 +163,9 @@ public class RemoteOperationResult implements Serializable { | |||||||
|                 case HttpStatus.SC_FORBIDDEN: |                 case HttpStatus.SC_FORBIDDEN: | ||||||
|                     mCode = ResultCode.FORBIDDEN; |                     mCode = ResultCode.FORBIDDEN; | ||||||
|                     break; |                     break; | ||||||
|  |                 case HttpStatus.SC_SERVICE_UNAVAILABLE: | ||||||
|  |                     mCode = ResultCode.MAINTENANCE_MODE; | ||||||
|  |                     break; | ||||||
|                 default: |                 default: | ||||||
|                     mCode = ResultCode.UNHANDLED_HTTP_CODE; |                     mCode = ResultCode.UNHANDLED_HTTP_CODE; | ||||||
|                     Log_OC.d(TAG, "RemoteOperationResult has processed UNHANDLED_HTTP_CODE: " + |                     Log_OC.d(TAG, "RemoteOperationResult has processed UNHANDLED_HTTP_CODE: " + | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user