使用soui开发的mbc,只支持windows版本
w1146869587
2022-01-24 479b1995ef435713c2cf4f0da8de3a6af6c30922
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
#if !defined(AFX_FILESESSION_H__98E4B82D_78D8_4C49_A142_76756D59F6FD__INCLUDED_)
#define AFX_FILESESSION_H__98E4B82D_78D8_4C49_A142_76756D59F6FD__INCLUDED_
 
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// FileSession.h : header file
//
 
#include "OISession.h"
 
#define    OPTION_TRANOPTION_SHOWDLG        ( 0X0001 )    // ÏÔʾ½ø¶È¶Ô»°¿ò
#define    OPTION_TRANOPTION_REPORT        ( 0X0002 )    // ±¨¸æ½ø¶ÈÐÅÏ¢
//#define    OPTION_HAVESOURCE                ( 0X0004 )    // ÊÇת·¢µÄ¸½¼þ
#define    OPTION_NOT_GEN_DATEPATH            ( 0X0008 )    // ²»×Ô¶¯Éú³ÉÈÕÆÚ·¾¶
#define    OPTION_NOT_USE_GUIDFILE            ( 0X0010 )    // ²»Ê¹ÓàGUID ×÷ΪÎļþÃû
#define    OPTION_GEN_FILE_EXT                ( 0X0020 )    // Éú³ÉÎļþʱ£¬¼ÓÉÏÀ©Õ¹Ãû
 
#define        WM_TRANS_UPLOADED        ( WM_USER + 29101 )        // ÒѾ­ÉÏ´«Êý¾Ý
#define        WM_TRANS_DOWNLOADED        ( WM_USER + 29102 )        // ÒѾ­ÏÂÔØÊý¾Ý
 
/////////////////////////////////////////////////////////////////////////////
// CFileSession window
 
class CFileSession : public COISession
{
// Construction
public:
    CFileSession();
    virtual ~CFileSession();
 
// Attributes
public:
    CString        m_strResumeInfoPath;        // Ðø´«ÐÅÏ¢µÄ±£´æÂ·¾¶
    bool        m_bBase64;                    // ²ÉÓàBase64 ´«Êä
 
// Operations
public:
    void        SetBase64( bool bBase64 = true );
 
    // ÉÏ´«Îļþ
    UINT        UploadFile( CString strFileName, DWORD dwOption, CString strSavePathName = _T( "" ), CString strFileMD5 = _T( "" ) );
    // ÏÂÔØÎļþ
    UINT        DownloadFile( CString strFileID, DWORD dwOption, CString strSavePathName = _T( "" ), CString strFileName = _T( "" ) );
    // ¸´ÖÆÎļþ
    UINT        CopyFile( CString strFileID, DWORD dwOption, CString strSavePathName = _T( "" ) );
    // É¾³ýÎļþ
    UINT        DeleteFile( CString strFileID );
    // µÃµ½ÎļþÐÅÏ¢
    UINT        GetFileInfo( CString strFileID );
 
    // ±¨¸æÎļþ´«Êä½ø¶È
    void        ReportUploadProgress( CString strMethod, CString strFileID, UINT nTrID, CString strFileName, __int64 nReaded, __int64 nFileSize );
    void        ReportDownloadProgress( UINT nTrID, CString strFileID, CString strFileName, __int64 nWrited, __int64 nFileSize );
 
    bool        GetResumeInfoPath();
 
protected:
 
// Overrides
public:
    // ClassWizard generated virtual function overrides
    //{{AFX_VIRTUAL(CFileSession)
    virtual CCommander *    NewCmderByCMDName( CString strMethod );
    virtual void            OnCmderResponse( CResponse *pResponse, CCommander *pCmder, BOOL &bRemoveCmder );
    //}}AFX_VIRTUAL
 
};
 
/////////////////////////////////////////////////////////////////////////////
 
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
 
#endif // !defined(AFX_FILESESSION_H__98E4B82D_78D8_4C49_A142_76756D59F6FD__INCLUDED_)