/** * Adds valid Port attribute value, e.g. "8000,8001,8002" */ @Override protected void formatCookieAsVer(final CharArrayBuffer buffer, final Cookie cookie, int version) { super.formatCookieAsVer(buffer, cookie, version); // format port attribute if (cookie instanceof ClientCookie) { // Test if the port attribute as set by the origin server is not blank String s = ((ClientCookie) cookie).getAttribute(ClientCookie.PORT_ATTR); if (s != null) { buffer.append("; $Port"); buffer.append("=\""); if (s.trim().length() > 0) { int[] ports = cookie.getPorts(); if (ports != null) { for (int i = 0, len = ports.length; i < len; i++) { if (i > 0) { buffer.append(","); } buffer.append(Integer.toString(ports[i])); } } } buffer.append("\""); } } }
/** * Returns whether or not this cookie is HttpOnly (i.e. not available in JS). * @see <a href="http://en.wikipedia.org/wiki/HTTP_cookie#Secure_and_HttpOnly">Wikipedia</a> * @return whether or not this cookie is HttpOnly (i.e. not available in JS). */ public boolean isHttpOnly() { return httpClientCookie_.getAttribute("httponly") != null; }
/** * Returns whether or not this cookie is HttpOnly (i.e. not available in JS). * @see <a href="http://en.wikipedia.org/wiki/HTTP_cookie#Secure_and_HttpOnly">Wikipedia</a> * @return whether or not this cookie is HttpOnly (i.e. not available in JS). */ public boolean isHttpOnly() { return httpClientCookie_.getAttribute("httponly") != null; }
/** * Adds valid Port attribute value, e.g. "8000,8001,8002" */ @Override protected void formatCookieAsVer(final CharArrayBuffer buffer, final Cookie cookie, final int version) { super.formatCookieAsVer(buffer, cookie, version); // format port attribute if (cookie instanceof ClientCookie) { // Test if the port attribute as set by the origin server is not blank final String s = ((ClientCookie) cookie).getAttribute(ClientCookie.PORT_ATTR); if (s != null) { buffer.append("; $Port"); buffer.append("=\""); if (!s.trim().isEmpty()) { final int[] ports = cookie.getPorts(); if (ports != null) { final int len = ports.length; for (int i = 0; i < len; i++) { if (i > 0) { buffer.append(","); } buffer.append(Integer.toString(ports[i])); } } } buffer.append("\""); } } }
/** * Adds valid Port attribute value, e.g. "8000,8001,8002" */ @Override protected void formatCookieAsVer(final CharArrayBuffer buffer, final Cookie cookie, final int version) { super.formatCookieAsVer(buffer, cookie, version); // format port attribute if (cookie instanceof ClientCookie) { // Test if the port attribute as set by the origin server is not blank final String s = ((ClientCookie) cookie).getAttribute(ClientCookie.PORT_ATTR); if (s != null) { buffer.append("; $Port"); buffer.append("=\""); if (s.trim().length() > 0) { final int[] ports = cookie.getPorts(); if (ports != null) { final int len = ports.length; for (int i = 0; i < len; i++) { if (i > 0) { buffer.append(","); } buffer.append(Integer.toString(ports[i])); } } } buffer.append("\""); } } }
/** * Adds valid Port attribute value, e.g. "8000,8001,8002" */ @Override protected void formatCookieAsVer(final CharArrayBuffer buffer, final Cookie cookie, int version) { super.formatCookieAsVer(buffer, cookie, version); // format port attribute if (cookie instanceof ClientCookie) { // Test if the port attribute as set by the origin server is not blank String s = ((ClientCookie) cookie).getAttribute(ClientCookie.PORT_ATTR); if (s != null) { buffer.append("; $Port"); buffer.append("=\""); if (s.trim().length() > 0) { int[] ports = cookie.getPorts(); if (ports != null) { for (int i = 0, len = ports.length; i < len; i++) { if (i > 0) { buffer.append(","); } buffer.append(Integer.toString(ports[i])); } } } buffer.append("\""); } } }
/** * Adds valid Port attribute value, e.g. "8000,8001,8002" */ @Override protected void formatCookieAsVer(final CharArrayBuffer buffer, final Cookie cookie, final int version) { super.formatCookieAsVer(buffer, cookie, version); // format port attribute if (cookie instanceof ClientCookie) { // Test if the port attribute as set by the origin server is not blank final String s = ((ClientCookie) cookie).getAttribute(ClientCookie.PORT_ATTR); if (s != null) { buffer.append("; $Port"); buffer.append("=\""); if (!s.trim().isEmpty()) { final int[] ports = cookie.getPorts(); if (ports != null) { final int len = ports.length; for (int i = 0; i < len; i++) { if (i > 0) { buffer.append(","); } buffer.append(Integer.toString(ports[i])); } } } buffer.append("\""); } } }
/** * Adds valid Port attribute value, e.g. "8000,8001,8002" */ @Override protected void formatCookieAsVer(final CharArrayBuffer buffer, final Cookie cookie, int version) { super.formatCookieAsVer(buffer, cookie, version); // format port attribute if (cookie instanceof ClientCookie) { // Test if the port attribute as set by the origin server is not blank String s = ((ClientCookie) cookie).getAttribute(ClientCookie.PORT_ATTR); if (s != null) { buffer.append("; $Port"); buffer.append("=\""); if (s.trim().length() > 0) { int[] ports = cookie.getPorts(); if (ports != null) { for (int i = 0, len = ports.length; i < len; i++) { if (i > 0) { buffer.append(","); } buffer.append(Integer.toString(ports[i])); } } } buffer.append("\""); } } }
/** * Adds valid Port attribute value, e.g. "8000,8001,8002" */ @Override protected void formatCookieAsVer(final CharArrayBuffer buffer, final Cookie cookie, int version) { super.formatCookieAsVer(buffer, cookie, version); // format port attribute if (cookie instanceof ClientCookie) { // Test if the port attribute as set by the origin server is not blank String s = ((ClientCookie) cookie).getAttribute(ClientCookie.PORT_ATTR); if (s != null) { buffer.append("; $Port"); buffer.append("=\""); if (s.trim().length() > 0) { int[] ports = cookie.getPorts(); if (ports != null) { for (int i = 0, len = ports.length; i < len; i++) { if (i > 0) { buffer.append(","); } buffer.append(Integer.toString(ports[i])); } } } buffer.append("\""); } } }
/** * Adds valid Port attribute value, e.g. "8000,8001,8002" */ @Override protected void formatCookieAsVer(final CharArrayBuffer buffer, final Cookie cookie, final int version) { super.formatCookieAsVer(buffer, cookie, version); // format port attribute if (cookie instanceof ClientCookie) { // Test if the port attribute as set by the origin server is not blank final String s = ((ClientCookie) cookie).getAttribute(ClientCookie.PORT_ATTR); if (s != null) { buffer.append("; $Port"); buffer.append("=\""); if (!s.trim().isEmpty()) { final int[] ports = cookie.getPorts(); if (ports != null) { final int len = ports.length; for (int i = 0; i < len; i++) { if (i > 0) { buffer.append(","); } buffer.append(Integer.toString(ports[i])); } } } buffer.append("\""); } } }
/** * Adds valid Port attribute value, e.g. "8000,8001,8002" */ @Override protected void formatCookieAsVer(final CharArrayBuffer buffer, final Cookie cookie, final int version) { super.formatCookieAsVer(buffer, cookie, version); // format port attribute if (cookie instanceof ClientCookie) { // Test if the port attribute as set by the origin server is not blank final String s = ((ClientCookie) cookie).getAttribute(ClientCookie.PORT_ATTR); if (s != null) { buffer.append("; $Port"); buffer.append("=\""); if (!s.trim().isEmpty()) { final int[] ports = cookie.getPorts(); if (ports != null) { final int len = ports.length; for (int i = 0; i < len; i++) { if (i > 0) { buffer.append(","); } buffer.append(Integer.toString(ports[i])); } } } buffer.append("\""); } } }
/** * Adds valid Port attribute value, e.g. "8000,8001,8002" */ @Override protected void formatCookieAsVer(final CharArrayBuffer buffer, final Cookie cookie, final int version) { super.formatCookieAsVer(buffer, cookie, version); // format port attribute if (cookie instanceof ClientCookie) { // Test if the port attribute as set by the origin server is not blank final String s = ((ClientCookie) cookie).getAttribute(ClientCookie.PORT_ATTR); if (s != null) { buffer.append("; $Port"); buffer.append("=\""); if (s.trim().length() > 0) { final int[] ports = cookie.getPorts(); if (ports != null) { final int len = ports.length; for (int i = 0; i < len; i++) { if (i > 0) { buffer.append(","); } buffer.append(Integer.toString(ports[i])); } } } buffer.append("\""); } } }
/** * Adds valid Port attribute value, e.g. "8000,8001,8002" */ @Override protected void formatCookieAsVer(final CharArrayBuffer buffer, final Cookie cookie, final int version) { super.formatCookieAsVer(buffer, cookie, version); // format port attribute if (cookie instanceof ClientCookie) { // Test if the port attribute as set by the origin server is not blank final String s = ((ClientCookie) cookie).getAttribute(ClientCookie.PORT_ATTR); if (s != null) { buffer.append("; $Port"); buffer.append("=\""); if (!s.trim().isEmpty()) { final int[] ports = cookie.getPorts(); if (ports != null) { final int len = ports.length; for (int i = 0; i < len; i++) { if (i > 0) { buffer.append(","); } buffer.append(Integer.toString(ports[i])); } } } buffer.append("\""); } } }
/** * Adds valid Port attribute value, e.g. "8000,8001,8002" */ @Override protected void formatCookieAsVer(final CharArrayBuffer buffer, final Cookie cookie, int version) { super.formatCookieAsVer(buffer, cookie, version); // format port attribute if (cookie instanceof ClientCookie) { // Test if the port attribute as set by the origin server is not blank String s = ((ClientCookie) cookie).getAttribute(ClientCookie.PORT_ATTR); if (s != null) { buffer.append("; $Port"); buffer.append("=\""); if (s.trim().length() > 0) { int[] ports = cookie.getPorts(); if (ports != null) { for (int i = 0, len = ports.length; i < len; i++) { if (i > 0) { buffer.append(","); } buffer.append(Integer.toString(ports[i])); } } } buffer.append("\""); } } }