Searched refs:entity (Results 1 - 21 of 21) sorted by relevance

/frameworks/base/core/java/android/net/http/
H A DAndroidHttpClientConnection.java33 import org.apache.http.entity.BasicHttpEntity;
34 import org.apache.http.entity.ContentLengthStrategy;
37 import org.apache.http.impl.entity.EntitySerializer;
38 import org.apache.http.impl.entity.StrictContentLengthStrategy;
265 * Sends the request entity over the connection.
266 * @param request the request whose entity to send.
381 * Return the next response entity.
382 * @param headers contains values for parsing entity
387 BasicHttpEntity entity = new BasicHttpEntity();
391 entity
[all...]
H A DAndroidHttpClient.java28 import org.apache.http.entity.AbstractHttpEntity;
29 import org.apache.http.entity.ByteArrayEntity;
212 * Gets the input stream from a response entity. If the entity is gzipped
215 * @param entity the entity whose content should be read
219 public static InputStream getUngzippedContent(HttpEntity entity) argument
221 InputStream responseStream = entity.getContent();
223 Header header = entity.getContentEncoding();
303 AbstractHttpEntity entity;
[all...]
H A DRequest.java27 import org.apache.http.entity.InputStreamEntity;
127 // it is ok to have null entity for BasicHttpEntityEnclosingRequest.
265 HttpEntity entity = null;
269 entity = httpClientConnection.receiveResponseEntity(header);
276 if (entity != null) {
277 InputStream is = entity.getContent();
280 Header contentEncoding = entity.getContentEncoding();
352 mConnection.setCanPersist(entity, statusLine.getProtocolVersion(),
463 * Decide whether a response comes with an entity.
466 * indicate responses with an entity
[all...]
H A DConnection.java463 private boolean keepAlive(HttpEntity entity, argument
472 if (entity != null) {
473 if (entity.getContentLength() < 0) {
474 if (!entity.isChunked() || ver.lessEquals(HttpVersion.HTTP_1_0)) {
491 void setCanPersist(HttpEntity entity, ProtocolVersion ver, int connType) { argument
492 mCanPersist = keepAlive(entity, ver, connType, mHttpContext);
H A DHeaders.java24 import org.apache.http.entity.ContentLengthStrategy;
/frameworks/base/services/java/com/android/server/location/
H A DGpsXtraDownloader.java137 HttpEntity entity = response.getEntity();
139 if (entity != null) {
141 if (entity.getContentLength() > 0) {
142 body = new byte[(int) entity.getContentLength()];
143 DataInputStream dis = new DataInputStream(entity.getContent());
155 if (entity != null) {
156 entity.consumeContent();
/frameworks/support/volley/src/com/android/volley/toolbox/
H A DHurlStack.java27 import org.apache.http.entity.BasicHttpEntity;
118 BasicHttpEntity entity = new BasicHttpEntity();
125 entity.setContent(inputStream);
126 entity.setContentLength(connection.getContentLength());
127 entity.setContentEncoding(connection.getContentEncoding());
128 entity.setContentType(connection.getContentType());
129 return entity;
H A DHttpClientStack.java29 import org.apache.http.entity.ByteArrayEntity;
72 HttpEntity entity;
73 entity = new ByteArrayEntity(postBody);
74 postRequest.setEntity(entity);
H A DBasicNetwork.java201 private byte[] entityToBytes(HttpEntity entity) throws IOException, ServerError { argument
203 new PoolingByteArrayOutputStream(mPool, (int) entity.getContentLength());
206 InputStream in = entity.getContent();
219 entity.consumeContent();
221 // This can happen if there was an exception above that left the entity in
/frameworks/base/libs/androidfw/
H A DBackupData.cpp128 if (DEBUG) ALOGI("writing entity header, %d bytes", sizeof(entity_header_v1));
136 if (DEBUG) ALOGI("writing entity header key, %d bytes", keyLen+1);
262 m_header.entity.keyLen = fromlel(m_header.entity.keyLen);
263 if (m_header.entity.keyLen <= 0) {
265 (int)m_header.entity.keyLen);
268 m_header.entity.dataSize = fromlel(m_header.entity.dataSize);
272 size_t size = m_header.entity.keyLen;
283 m_dataEndPos = m_pos + m_header.entity
[all...]
/frameworks/base/core/jni/
H A Dandroid_backup_BackupDataInput.cpp50 readNextHeader_native(JNIEnv* env, jobject clazz, int r, jobject entity) argument
76 // TODO: Set the fields in the entity object
78 env->SetObjectField(entity, s_keyField, keyStr);
79 env->SetIntField(entity, s_dataSizeField, dataSize);
/frameworks/opt/vcard/tests/src/com/android/vcard/tests/testutils/
H A DExportTestProvider.java47 Entity entity = new Entity(new ContentValues());
49 entity.addSubValue(Data.CONTENT_URI, contentValues);
51 mEntityList.add(entity);
/frameworks/base/tests/DumpRenderTree2/src/com/android/dumprendertree2/
H A DFsUtils.java166 HttpEntity entity = response.getEntity();
167 return (entity == null ? null : EntityUtils.toByteArray(entity));
232 HttpEntity entity = response.getEntity();
233 if (entity == null) {
238 new BufferedReader(new InputStreamReader(entity.getContent()));
/frameworks/support/volley/tests/src/com/android/volley/mock/
H A DMockHttpClient.java40 public void setResponseData(HttpEntity entity) { argument
42 mResponseEntity = entity;
/frameworks/base/core/java/android/app/backup/
H A DBackupDataInput.java29 * onBackup()} implementation. An entity is composed of a descriptive header plus a
32 * The agent must consume every entity in the data stream, otherwise the
49 * data.readEntityData(buffer, 0, dataSize); // reads the entire entity at once
91 * Extract the next entity header from the restore stream. After this method
93 * be used to inspect the entity that is now available for processing.
95 * @return <code>true</code> when there is an entity ready for consumption from the
117 * Report the key associated with the current entity in the restore stream
118 * @return the current entity's key string
130 * Report the size in bytes of the data associated with the current entity in the
148 * must be read in a single call. Once all of the raw data for the current entity
191 readNextHeader_native(int mBackupReader, EntityHeader entity) argument
[all...]
/frameworks/base/include/androidfw/
H A DBackupHelpers.h77 * entity-structured. If the implementation here is changed, either this
129 entity_header_v1 entity; member in union:android::BackupDataReader::__anon1010
/frameworks/support/volley/tests/src/com/android/volley/toolbox/
H A DBasicNetworkTest.java25 import org.apache.http.entity.StringEntity;
/frameworks/base/core/java/com/android/internal/backup/
H A DLocalTransport.java121 FileOutputStream entity = new FileOutputStream(entityFile);
131 entity.write(buf, 0, dataSize);
136 entity.close();
/frameworks/base/core/java/com/android/internal/http/multipart/
H A DMultipartEntity.java41 import org.apache.http.entity.AbstractHttpEntity;
50 * Implements a request entity suitable for an HTTP multipart POST method.
65 * <p>This entity is designed to be used in conjunction with the
127 * Creates a new multipart entity containing the given parts.
129 * @param params The params of the HttpMethod using this entity.
158 * @return The boundary string of this entity in ASCII encoding.
/frameworks/base/core/java/android/provider/
H A DCalendarContract.java498 * Creates an entity iterator for the given cursor. It assumes the
567 Entity entity = new Entity(cv);
573 return entity;
1280 * @return an EntityIterator containing one entity per event in the
1292 * @return an EntityIterator containing one entity per event in the
1419 Entity entity = new Entity(cv);
1437 entity.addSubValue(Reminders.CONTENT_URI, reminderValues);
1471 entity.addSubValue(Attendees.CONTENT_URI, attendeeValues);
1497 entity.addSubValue(ExtendedProperties.CONTENT_URI, extendedValues);
1504 return entity;
[all...]
/frameworks/opt/vcard/java/com/android/vcard/
H A DVCardComposer.java497 // The resolver may return the entity iterator with no data. It is possible.
536 Entity entity = entityIterator.next();
537 for (NamedContentValues namedContentValues : entity.getSubValues()) {
649 * @return true when there's no entity to be built. The return value is undefined

Completed in 234 milliseconds