public class CookieUtil extends Object
| Constructor and Description |
|---|
CookieUtil() |
| Modifier and Type | Method and Description |
|---|---|
static void |
clear(String path,
String name)
Clears out the specified cookie.
|
static String |
get(String name)
Looks up and returns the value for the specified cookie.
|
static void |
set(String path,
int expires,
String name,
String value)
Sets a cross-domain cookie to the supplied value, which can be accessed by other subdomains.
|
static void |
set(String path,
int expires,
String name,
String value,
String domain)
Sets the specified cookie to the supplied value.
|
public static void set(String path, int expires, String name, String value)
expires - The number of days in which the cookie should expire.public static void set(String path, int expires, String name, String value, String domain)
expires - The number of days in which the cookie should expire.domain - The domain to set this cookie on.Copyright © 2013. All Rights Reserved.