LumiSoft Mail Server User API
POP3_Client Class
Namespaces > LumiSoft.Net.POP3.Client > POP3_Client
POP3 Client.
Syntax

C# | Visual Basic | Managed C++

    public class POP3_Client : IDisposable

    Public Class POP3_Client _
    	Implements IDisposable

    public ref class POP3_Client : IDisposable

Members

All Members | Constructors | Methods | Properties | Fields | Events
Public Protected | Instance Static | Declared Inherited

Icon | Member | Description
--- | --- | ---
| POP3_Client New() | Default constructor.
| Authenticate(String, String, Boolean) | Authenticates user.
| Authenticated | Gets if pop3 client is authenticated.
| Connect(String, Int32) | Connects to specified host.
| Connect(String, Int32, Boolean) | Connects to specified host.
| Connected | Gets if pop3 client is connected.
| DeleteMessage(Int32) | Deletes specified message
| Disconnect() | Closes connection to POP3 server.
| Dispose() | Clean up any resources being used.
| Equals(Object) | Determines whether the specified Object is equal to the current Object. (Inherited from Object.)
| Finalize() | Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (Inherited from Object.)
| GetHashCode() | Serves as a hash function for a particular type. GetHashCode() is suitable for use in hashing algorithms and data structures like a hash table. (Inherited from Object.)
| GetMessage(POP3_MessageInfo) | Gets specified message.
| GetMessage(Int32) | Gets specified message.
| GetMessage(Int32, Stream) | Gets specified message and stores it to specified stream.
| GetMessagesInfo() | Gets messages info.
| GetTopOfMessage(Int32, Int32) | Gets top lines of message.
| GetType() | Gets the Type of the current instance. (Inherited from Object.)
| GetUidlList() | Gets uid listing.
| IsSecureConnection | Gets if the connection is an SSL connection.
| LogCommands | Gets or sets if to log commands.
| MemberwiseClone() | Creates a shallow copy of the current Object. (Inherited from Object.)
| Reset() | Resets session.
| SessionLog | Occurs when POP3 session has finished and session log is available.
| StartTLS() | Switches POP3 connection to SSL.
| ToString() | Returns a String that represents the current Object. (Inherited from Object.)

Examples

     1/*
     2 To make this code to work, you need to import following namespaces:
     3 using LumiSoft.Net.Mime;
     4 using LumiSoft.Net.POP3.Client;
     5 */
     6
     7using(POP3_Client c = new POP3_Client()){
     8    c.Connect("ivx",110);
     9    c.Authenticate("test","test",true);
    10
    11    POP3_MessagesInfo mInf = c.GetMessagesInfo();
    12
    13    // Get first message if there is any
    14    if(mInf.Count > 0){
    15        byte[] messageData = c.GetMessage(mInf[0]);
    16
    17        // Do your suff
    18
    19        // Parse message
    20        Mime m = Mime.Parse(messageData);
    21        string from = m.MainEntity.From;
    22        string subject = m.MainEntity.Subject;
    23        // ...
    24    }
    25}

Inheritance Hierarchy

Object
| POP3_Client

Assembly: LumiSoft.Net Version: 2.0.2636.18419 (Module: LumiSoft.Net)