public static PopCapability FromCapa(PopFollowingResponse response) { /* * http://tools.ietf.org/html/rfc2449 * RFC 2449 - POP3 Extension Mechanism * * 5. The CAPA Command * * An -ERR response indicates the capability command is not * implemented and the client will have to probe for * capabilities as before. * * An +OK response is followed by a list of capabilities, one * per line. Each capability name MAY be followed by a single * space and a space-separated list of parameters. Each * capability line is limited to 512 octets (including the * CRLF). The capability list is terminated by a line * containing a termination octet (".") and a CRLF pair. */ return PopTextConverter.ToCapability(SplitDataOrThrow(response, 1)); }
public static PopUniqueIdListing FromUidl(PopFollowingResponse response) { /* * 7. Optional POP3 Commands * UIDL * If no argument was given and the POP3 server issues a positive * response, then the response given is multi-line. After the * initial +OK, for each message in the maildrop, the POP3 server * responds with a line containing information for that message. * This line is called a "unique-id listing" for that message. */ return PopTextConverter.ToUniqueIdListing(SplitDataOrThrow(response, 2)); }
public static PopScanListing FromList(PopFollowingResponse response) { /* * 5. The TRANSACTION State * LIST * If no argument was given and the POP3 server issues a * positive response, then the response given is multi-line. * After the initial +OK, for each message in the maildrop, * the POP3 server responds with a line containing * information for that message. This line is also called a * "scan listing" for that message. If there are no * messages in the maildrop, then the POP3 server responds * with no scan listings--it issues a positive response * followed by a line containing a termination octet and a * CRLF pair. */ return PopTextConverter.ToScanListing(SplitDataOrThrow(response, 2)); }