|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ConnectorResponse | Line # 30 | 0 | - | 0 | 0 | - |
-1.0
|
||||||||||||||||||||||||||||||||||||||||||||||||||||
| No Tests | |||
| 1 | /* | |
| 2 | * | |
| 3 | * (C)opyright 2010, Nikolaos Georgosopoulos | |
| 4 | * | |
| 5 | * This file is part of ARESTC. | |
| 6 | * | |
| 7 | * ARESTC is free software: you can redistribute it and/or modify it under the | |
| 8 | * terms of the Lesser General Public License as published by the Free Software | |
| 9 | * Foundation, either version 3 of the License, or (at your option) any later | |
| 10 | * version. | |
| 11 | * | |
| 12 | * ARESTC is distributed in the hope that it will be useful, but WITHOUT ANY | |
| 13 | * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR | |
| 14 | * A PARTICULAR PURPOSE. See the GNU General Public License for more details. | |
| 15 | * | |
| 16 | * You should have received a copy of the Lesser General Public License along | |
| 17 | * with ARESTC. If not, see <http://www.gnu.org/licenses/>. | |
| 18 | */ | |
| 19 | package net.sf.arestc.core; | |
| 20 | ||
| 21 | import java.io.InputStream; | |
| 22 | import java.util.Collection; | |
| 23 | ||
| 24 | import org.apache.commons.httpclient.Header; | |
| 25 | ||
| 26 | // TODO: Auto-generated Javadoc | |
| 27 | /** | |
| 28 | * The Interface ConnectorResponse. | |
| 29 | */ | |
| 30 | public interface ConnectorResponse { | |
| 31 | ||
| 32 | /** | |
| 33 | * Checks for errors. | |
| 34 | * | |
| 35 | * @return true, if successful | |
| 36 | */ | |
| 37 | boolean hasErrors(); | |
| 38 | ||
| 39 | /** | |
| 40 | * Gets the errors. | |
| 41 | * | |
| 42 | * @return the errors | |
| 43 | */ | |
| 44 | Collection<ARESTCError> getErrors(); | |
| 45 | ||
| 46 | /** | |
| 47 | * Gets the response body. | |
| 48 | * | |
| 49 | * @return the response body | |
| 50 | */ | |
| 51 | Object getResponseBody(); | |
| 52 | ||
| 53 | /** | |
| 54 | * Gets the response headers. | |
| 55 | * | |
| 56 | * @return the response headers | |
| 57 | */ | |
| 58 | Header[] getResponseHeaders(); | |
| 59 | ||
| 60 | /** | |
| 61 | * Gets the streamed body. | |
| 62 | * | |
| 63 | * @return the streamed body | |
| 64 | */ | |
| 65 | InputStream getStreamedBody(); | |
| 66 | ||
| 67 | void releaseConnection(); | |
| 68 | } | |
|
||||||||||||