Sets the flag that controls if this cookie will be hidden from scripts on the client side. @param httpOnly The new value of the flag @since Servlet 3.0
(boolean httpOnly)
| 360 | * @since Servlet 3.0 |
| 361 | */ |
| 362 | public void setHttpOnly(boolean httpOnly) { |
| 363 | if (httpOnly) { |
| 364 | setAttributeInternal(HTTP_ONLY, EMPTY_STRING); |
| 365 | } else { |
| 366 | setAttributeInternal(HTTP_ONLY, null); |
| 367 | } |
| 368 | } |
| 369 | |
| 370 | |
| 371 | /** |