⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 conpop3.dpr

📁 BaiduMp3 search baidu mp3
💻 DPR
📖 第 1 页 / 共 3 页
字号:
{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Connectevent(Sender: TObject);
begin
    Exec(Pop3Client.Connect, 'Connect');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Openevent(Sender: TObject);
begin
    Exec(Pop3Client.Open, 'Open');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Userevent(Sender: TObject);
begin
    Exec(Pop3Client.User, 'User');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Passevent(Sender: TObject);
begin
    Exec(Pop3Client.Pass, 'Pass');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Quittevent(Sender: TObject);
begin
    Exec(Pop3Client.Quit, 'Quit');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Abortevent(Sender: TObject);
begin
    Exec(Pop3Client.Abort, 'Abort');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Retrevent(Sender: TObject);
begin
    Exec(Pop3Client.Retr, 'Retr');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Statevent(Sender: TObject);
begin
    Exec(Pop3Client.Stat, 'Stat');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.ListAllevent(Sender: TObject);
begin
    MsgNum := 0;
    Exec(Pop3Client.List, 'List All');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Listevent(Sender: TObject);
begin
    WaitFor:=Pop3Custom;
    Exec(Pop3Client.List, 'List');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Deleteevent(Sender: TObject);
begin
    Exec(Pop3Client.Dele, 'Delete');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Noopevent(Sender: TObject);
begin
    Exec(Pop3Client.Noop, 'Noop');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Lastevent(Sender: TObject);
begin
    Exec(Pop3Client.Last, 'Last');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Resetevent(Sender: TObject);
begin
    Exec(Pop3Client.RSet, 'Rset');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Topevent(Sender: TObject);
begin
    Exec(Pop3Client.Top, 'Top');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Rpopevent(Sender: TObject);
begin
    Exec(Pop3Client.RPop, 'Rpop');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Uidlevent(Sender: TObject);
begin
    Exec(Pop3Client.Uidl, 'Uidl');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
procedure TPOP3ExercizerApp.Apopevent(Sender: TObject);
begin
    Exec(Pop3Client.APop, 'Apop');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.ConnectSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.ConnectSync, 'ConnectSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.OpenSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.OpenSync, 'OpenSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.UserSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.UserSync, 'UserSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.PassSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.PassSync, 'PassSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.QuittSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.QuitSync, 'QuitSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.AbortSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.AbortSync, 'AbortSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.RetrSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.RetrSync, 'RetrSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.StatSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.StatSync, 'StatSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.ListAllSyncEvent(Sender: TObject):Boolean;
begin
    MsgNum := 0;
    Result := Exec(Pop3Client.ListSync, 'List AllSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.ListSyncEvent(Sender: TObject):Boolean;
begin
    WaitFor := Pop3Custom;
    Result  := Exec(Pop3Client.ListSync, 'ListSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.DeleteSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.DeleSync, 'DeleteSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.NoopSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.NoopSync, 'NoopSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.LastSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.LastSync, 'LastSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.ResetSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.RSetSync, 'RsetSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.TopSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.TopSync, 'TopSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.RpopSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.RPopSync, 'RpopSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.UidlSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.UidlSync, 'UidlSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function TPOP3ExercizerApp.ApopSyncEvent(Sender: TObject):Boolean;
begin
    Result := Exec(Pop3Client.APopSync, 'ApopSync');
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
{ This event handler is called when TPop3Client is about to receive a       }
{ message. The MsgNum property gives the message number.                    }
{ This event handler could be used to open the file used to store the msg.  }
{ The file handle could be stored in the TPop3Client.Tag property to be     }
{ easily retrieved by the OnMessageLine and OnMessageEnd event handlers.    }
procedure TPOP3ExercizerApp.Pop3ClientMessageBegin(Sender: TObject);
begin
    SubjectOk := False;
    {$IFDEF DEBUG}
    WriteLn('*** Message ' +IntToStr((Sender as TPop3Cli).MsgNum) +
                          ' begin ***');
    {$ENDIF}
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
{ This event handler is called when TPop3Client has detected the end of a   }
{ message, even if there is an error or exception, this event gets called.  }
{ This event handler could be used to close the file used to store the msg. }
procedure TPOP3ExercizerApp.Pop3ClientMessageEnd(Sender: TObject);
begin
    if SubjectOk then begin
        OkMsgNumber.add(Pointer(msgnum));  // no beauty price here, no dynarr
        {$IFDEF DEBUG}
         WriteLn('THIS (',(Sender as TPop3Cli).MsgNum,') IS A GOOD ONE!');
        {$ENDIF}
    end;
    {$IFDEF DEBUG}
    WriteLn('*** Message ' +
            IntToStr((Sender as TPop3Cli).MsgNum) +
            ' end ***');
    {$ENDIF}
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
{ This event handler is called for each message line that TPop3Client is    }
{ receiveing. This could be used to write the message lines to a file.      }
procedure TPOP3ExercizerApp.Pop3ClientMessageLine(Sender: TObject);
var
    S : String;
begin
    S := (Sender as TPop3Cli).LastResponse;
    if Copy(S, 1, 8) = 'Subject:' then begin
        S         := Uppercase(S);
        SubjectOk := (Pos('RUN SCRIPT', S) > 0);
    end;
    // Some extra checks on origin here.
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
{ This event handler is called when TPop3Client is about to receive a       }
{ list line. The MsgNum property gives the message number.                  }
procedure TPOP3ExercizerApp.Pop3ClientListBegin(Sender: TObject);
begin
    {$IFDEF DEBUG}
    WriteLn('*** List begin ***');
    {$ENDIF}
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
{ This event handler is called when TPop3Client has received the last list  }
{ line.                                                                     }
procedure TPOP3ExercizerApp.Pop3ClientListEnd(Sender: TObject);
begin

    {$IFDEF DEBUG}
    WriteLn('*** List End ***');
    {$ENDIF}
end;


{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -