1 // 7zCompressionMode.h 2 3 #ifndef __7Z_COMPRESSION_MODE_H 4 #define __7Z_COMPRESSION_MODE_H 5 6 #include "../../Common/MethodId.h" 7 #include "../../Common/MethodProps.h" 8 9 namespace NArchive { 10 namespace N7z { 11 12 struct CMethodFull: public CProps 13 { 14 CMethodId Id; 15 UInt32 NumInStreams; 16 UInt32 NumOutStreams; 17 18 bool IsSimpleCoder() const { return (NumInStreams == 1) && (NumOutStreams == 1); } 19 }; 20 21 struct CBind 22 { 23 UInt32 InCoder; 24 UInt32 InStream; 25 UInt32 OutCoder; 26 UInt32 OutStream; 27 }; 28 29 struct CCompressionMethodMode 30 { 31 CObjectVector<CMethodFull> Methods; 32 CRecordVector<CBind> Binds; 33 #ifndef _7ZIP_ST 34 UInt32 NumThreads; 35 #endif 36 bool PasswordIsDefined; 37 UString Password; 38 39 bool IsEmpty() const { return (Methods.IsEmpty() && !PasswordIsDefined); } 40 CCompressionMethodMode(): PasswordIsDefined(false) 41 #ifndef _7ZIP_ST 42 , NumThreads(1) 43 #endif 44 {} 45 }; 46 47 }} 48 49 #endif 50