vibe.d beta banner
get vibe.d
0.10.0

Asynchronous I/O that doesn’t get in your way, written in D

Function parseHTTPCookie

Parses the cookie from a header field, returning the name of the cookie. Implements an algorithm equivalent to https://tools.ietf.org/html/rfc6265#section-5.2

string parseHTTPCookie (
  string header_string,
  scope Cookie dst
) @safe;

std.typecons.Tuple!(string,vibe.http.common.Cookie) parseHTTPCookie (
  string header_string
) @safe;

Returns

the cookie name as return value, populates the dst argument or allocates on the GC for the tuple overload.

Authors

Sönke Ludwig, Jan Krüger

Copyright

© 2012-2015 RejectedSoftware e.K.

License

Subject to the terms of the MIT license, as written in the included LICENSE.txt file.