code: public boolean data_setCookie(Integer userId, CharSequence cookieName, CharSequence cookieValue, Long expiresTimestamp, CharSequence path)
      throws FacebookException, IOException {
  
      if (null == userId || 0 >= userId)
        throw new IllegalArgumentException("userId should be provided.");
      if (null == cookieName || null == cookieValue)
        throw new IllegalArgumentException("cookieName and cookieValue should be provided.");
  
      ArrayList<Pair<String, CharSequence>> params =
        new ArrayList<Pair<String, CharSequence>>(FacebookMethod.DATA_GET_COOKIES.numParams());
      params.add(new Pair<String, CharSequence>("uid", userId.toString()));
      params.add(new Pair<String, CharSequence>("name", cookieName));
      params.add(new Pair<String, CharSequence>("value", cookieValue));
      if (null != expiresTimestamp && expiresTimestamp >= 0L)
        params.add(new Pair<String, CharSequence>("expires", expiresTimestamp.toString()));
      if (null != path)
        params.add(new Pair<String, CharSequence>("path", path));
      
      return extractBoolean(this.callMethod(FacebookMethod.DATA_GET_COOKIES, params));
    }
docs: Sets a cookie for a given user and application.
  @param userId The user for whom this cookie needs to be set
  @param cookieName Name of the cookie.
  @param cookieValue Value of the cookie.
  @param expiresTimestamp Time stamp when the cookie should expire. If not specified, the cookie never expires.
  @return true if cookie was successfully set, false otherwise
  @see <a href="http://wiki.developers.facebook.com/index.php/Data.getCookies">
  Developers Wiki: Data.setCookie</a>
  @see <a href="http://wiki.developers.facebook.com/index.php/Cookies">
  Developers Wiki: Cookies</a>