Stay organized with collections
Save and categorize content based on your preferences.
CoreConnectionPNames
interface CoreConnectionPNames
Defines parameter names for connections in HttpCore.
Summary
Constants |
static String |
Determines the timeout until a connection is etablished.
|
static String |
Determines the maximum HTTP header count allowed.
|
static String |
Determines the maximum line length limit.
|
static String |
Determines the size of the internal socket buffer used to buffer data while receiving / transmitting HTTP messages.
|
static String |
Sets SO_LINGER with the specified linger time in seconds.
|
static String |
Defines the default socket timeout (SO_TIMEOUT) in milliseconds which is the timeout for waiting for data.
|
static String |
Determines whether stale connection check is to be used.
|
static String |
Determines whether Nagle's algorithm is to be used.
|
Constants
CONNECTION_TIMEOUT
static val CONNECTION_TIMEOUT: String
Deprecated: Deprecated in Java.
Determines the timeout until a connection is etablished. A value of zero means the timeout is not used. The default value is zero.
This parameter expects a value of type Integer
.
Value: "http.connection.timeout"
static val MAX_HEADER_COUNT: String
Deprecated: Deprecated in Java.
Determines the maximum HTTP header count allowed. If set to a positive value, the number of HTTP headers received from the data stream exceeding this limit will cause an IOException. A negative or zero value will effectively disable the check.
This parameter expects a value of type Integer
.
Value: "http.connection.max-header-count"
MAX_LINE_LENGTH
static val MAX_LINE_LENGTH: String
Deprecated: Deprecated in Java.
Determines the maximum line length limit. If set to a positive value, any HTTP line exceeding this limit will cause an IOException. A negative or zero value will effectively disable the check.
This parameter expects a value of type Integer
.
Value: "http.connection.max-line-length"
SOCKET_BUFFER_SIZE
static val SOCKET_BUFFER_SIZE: String
Deprecated: Deprecated in Java.
Determines the size of the internal socket buffer used to buffer data while receiving / transmitting HTTP messages.
This parameter expects a value of type Integer
.
Value: "http.socket.buffer-size"
SO_LINGER
static val SO_LINGER: String
Deprecated: Deprecated in Java.
Sets SO_LINGER with the specified linger time in seconds. The maximum timeout value is platform specific. Value 0 implies that the option is disabled. Value -1 implies that the JRE default is used. The setting only affects socket close.
This parameter expects a value of type Integer
.
Value: "http.socket.linger"
SO_TIMEOUT
static val SO_TIMEOUT: String
Deprecated: Deprecated in Java.
Defines the default socket timeout (SO_TIMEOUT) in milliseconds which is the timeout for waiting for data. A timeout value of zero is interpreted as an infinite timeout. This value is used when no socket timeout is set in the method parameters.
This parameter expects a value of type Integer
.
Value: "http.socket.timeout"
STALE_CONNECTION_CHECK
static val STALE_CONNECTION_CHECK: String
Deprecated: Deprecated in Java.
Determines whether stale connection check is to be used. Disabling stale connection check may result in slight performance improvement at the risk of getting an I/O error when executing a request over a connection that has been closed at the server side.
This parameter expects a value of type Boolean
.
Value: "http.connection.stalecheck"
TCP_NODELAY
static val TCP_NODELAY: String
Deprecated: Deprecated in Java.
Determines whether Nagle's algorithm is to be used. The Nagle's algorithm tries to conserve bandwidth by minimizing the number of segments that are sent. When applications wish to decrease network latency and increase performance, they can disable Nagle's algorithm (that is enable TCP_NODELAY). Data will be sent earlier, at the cost of an increase in bandwidth consumption.
This parameter expects a value of type Boolean
.
Value: "http.tcp.nodelay"
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-02-10 UTC."],[],[],null,["# CoreConnectionPNames\n\nAdded in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \nDeprecated in [API level 22](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels)\n\nCoreConnectionPNames\n====================\n\n```\ninterface CoreConnectionPNames\n```\n\n|--------------------------------------------------|\n| [org.apache.http.params.CoreConnectionPNames](#) |\n\n|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| Known Direct Subclasses [HttpConnectionParams](/reference/kotlin/org/apache/http/params/HttpConnectionParams) |---------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------| | [HttpConnectionParams](/reference/kotlin/org/apache/http/params/HttpConnectionParams) | An adaptor for accessing connection parameters in [HttpParams](/reference/kotlin/org/apache/http/params/HttpParams). | |\n\n*** ** * ** ***\n\n| **This interface was deprecated in API level 22.**\n|\n| Please use java.net.URL#openConnection instead. Please visit [this webpage](http://android-developers.blogspot.com/2011/09/androids-http-clients.html) for further details.\n\nDefines parameter names for connections in HttpCore.\n\nSummary\n-------\n\n| Constants ||\n|-----------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| static [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [CONNECTION_TIMEOUT](#CONNECTION_TIMEOUT:kotlin.String) Determines the timeout until a connection is etablished. |\n| static [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [MAX_HEADER_COUNT](#MAX_HEADER_COUNT:kotlin.String) Determines the maximum HTTP header count allowed. |\n| static [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [MAX_LINE_LENGTH](#MAX_LINE_LENGTH:kotlin.String) Determines the maximum line length limit. |\n| static [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [SOCKET_BUFFER_SIZE](#SOCKET_BUFFER_SIZE:kotlin.String) Determines the size of the internal socket buffer used to buffer data while receiving / transmitting HTTP messages. |\n| static [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [SO_LINGER](#SO_LINGER:kotlin.String) Sets SO_LINGER with the specified linger time in seconds. |\n| static [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [SO_TIMEOUT](#SO_TIMEOUT:kotlin.String) Defines the default socket timeout (SO_TIMEOUT) in milliseconds which is the timeout for waiting for data. |\n| static [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [STALE_CONNECTION_CHECK](#STALE_CONNECTION_CHECK:kotlin.String) Determines whether stale connection check is to be used. |\n| static [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) | [TCP_NODELAY](#TCP_NODELAY:kotlin.String) Determines whether Nagle's algorithm is to be used. |\n\nConstants\n---------\n\n### CONNECTION_TIMEOUT\n\nAdded in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nstatic val CONNECTION_TIMEOUT: String\n```\n\n**Deprecated:** *Deprecated in Java.*\n\nDetermines the timeout until a connection is etablished. A value of zero means the timeout is not used. The default value is zero.\n\nThis parameter expects a value of type [Integer](../../../../java/lang/Integer.html#). \n\n Value: \"http.connection.timeout\"\n\n### MAX_HEADER_COUNT\n\nAdded in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nstatic val MAX_HEADER_COUNT: String\n```\n\n**Deprecated:** *Deprecated in Java.*\n\nDetermines the maximum HTTP header count allowed. If set to a positive value, the number of HTTP headers received from the data stream exceeding this limit will cause an IOException. A negative or zero value will effectively disable the check.\n\nThis parameter expects a value of type [Integer](../../../../java/lang/Integer.html#). \n\n Value: \"http.connection.max-header-count\"\n\n### MAX_LINE_LENGTH\n\nAdded in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nstatic val MAX_LINE_LENGTH: String\n```\n\n**Deprecated:** *Deprecated in Java.*\n\nDetermines the maximum line length limit. If set to a positive value, any HTTP line exceeding this limit will cause an IOException. A negative or zero value will effectively disable the check.\n\nThis parameter expects a value of type [Integer](../../../../java/lang/Integer.html#). \n\n Value: \"http.connection.max-line-length\"\n\n### SOCKET_BUFFER_SIZE\n\nAdded in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nstatic val SOCKET_BUFFER_SIZE: String\n```\n\n**Deprecated:** *Deprecated in Java.*\n\nDetermines the size of the internal socket buffer used to buffer data while receiving / transmitting HTTP messages.\n\nThis parameter expects a value of type [Integer](../../../../java/lang/Integer.html#). \n\n Value: \"http.socket.buffer-size\"\n\n### SO_LINGER\n\nAdded in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nstatic val SO_LINGER: String\n```\n\n**Deprecated:** *Deprecated in Java.*\n\nSets SO_LINGER with the specified linger time in seconds. The maximum timeout value is platform specific. Value 0 implies that the option is disabled. Value -1 implies that the JRE default is used. The setting only affects socket close.\n\nThis parameter expects a value of type [Integer](../../../../java/lang/Integer.html#). \n\n Value: \"http.socket.linger\"\n\n**See Also**\n\n- [java.net.SocketOptions#SO_LINGER](../../../../java/net/SocketOptions.html#SO_LINGER:kotlin.Int) \n\n### SO_TIMEOUT\n\nAdded in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nstatic val SO_TIMEOUT: String\n```\n\n**Deprecated:** *Deprecated in Java.*\n\nDefines the default socket timeout (SO_TIMEOUT) in milliseconds which is the timeout for waiting for data. A timeout value of zero is interpreted as an infinite timeout. This value is used when no socket timeout is set in the method parameters.\n\nThis parameter expects a value of type [Integer](../../../../java/lang/Integer.html#). \n\n Value: \"http.socket.timeout\"\n\n**See Also**\n\n- [java.net.SocketOptions#SO_TIMEOUT](../../../../java/net/SocketOptions.html#SO_TIMEOUT:kotlin.Int) \n\n### STALE_CONNECTION_CHECK\n\nAdded in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nstatic val STALE_CONNECTION_CHECK: String\n```\n\n**Deprecated:** *Deprecated in Java.*\n\nDetermines whether stale connection check is to be used. Disabling stale connection check may result in slight performance improvement at the risk of getting an I/O error when executing a request over a connection that has been closed at the server side.\n\nThis parameter expects a value of type [Boolean](../../../../java/lang/Boolean.html#). \n\n Value: \"http.connection.stalecheck\"\n\n### TCP_NODELAY\n\nAdded in [API level 1](https://developer.android.com/guide/topics/manifest/uses-sdk-element.html#ApiLevels) \n\n```\nstatic val TCP_NODELAY: String\n```\n\n**Deprecated:** *Deprecated in Java.*\n\nDetermines whether Nagle's algorithm is to be used. The Nagle's algorithm tries to conserve bandwidth by minimizing the number of segments that are sent. When applications wish to decrease network latency and increase performance, they can disable Nagle's algorithm (that is enable TCP_NODELAY). Data will be sent earlier, at the cost of an increase in bandwidth consumption.\n\nThis parameter expects a value of type [Boolean](../../../../java/lang/Boolean.html#). \n\n Value: \"http.tcp.nodelay\"\n\n**See Also**\n\n- [java.net.SocketOptions#TCP_NODELAY](../../../../java/net/SocketOptions.html#TCP_NODELAY:kotlin.Int)"]]