本文整理汇总了C++中CBoolVector::Size方法的典型用法代码示例。如果您正苦于以下问题:C++ CBoolVector::Size方法的具体用法?C++ CBoolVector::Size怎么用?C++ CBoolVector::Size使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CBoolVector
的用法示例。
在下文中一共展示了CBoolVector::Size方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: while
HRESULT CFolderOutStream2::ProcessEmptyFiles()
{
while (_currentIndex < _extractStatuses->Size() && _db->Files[_startIndex + _currentIndex].Size == 0)
{
OpenFile();
RINOK(CloseFileAndSetResult());
}
return S_OK;
}
示例2: ReadHeader
HRESULT CInArchive::ReadHeader(
DECL_EXTERNAL_CODECS_LOC_VARS
CArchiveDatabaseEx &db
#ifndef _NO_CRYPTO
, ICryptoGetTextPassword *getTextPassword, bool &passwordIsDefined
#endif
)
{
UInt64 type = ReadID();
if (type == NID::kArchiveProperties)
{
ReadArchiveProperties(db.ArchiveInfo);
type = ReadID();
}
CObjectVector<CByteBuffer> dataVector;
if (type == NID::kAdditionalStreamsInfo)
{
HRESULT result = ReadAndDecodePackedStreams(
EXTERNAL_CODECS_LOC_VARS
db.ArchiveInfo.StartPositionAfterHeader,
db.ArchiveInfo.DataStartPosition2,
dataVector
#ifndef _NO_CRYPTO
, getTextPassword, passwordIsDefined
#endif
);
RINOK(result);
db.ArchiveInfo.DataStartPosition2 += db.ArchiveInfo.StartPositionAfterHeader;
type = ReadID();
}
CRecordVector<UInt64> unpackSizes;
CBoolVector digestsDefined;
CRecordVector<UInt32> digests;
if (type == NID::kMainStreamsInfo)
{
ReadStreamsInfo(&dataVector,
db.ArchiveInfo.DataStartPosition,
db.PackSizes,
db.PackCRCsDefined,
db.PackCRCs,
db.Folders,
db.NumUnpackStreamsVector,
unpackSizes,
digestsDefined,
digests);
db.ArchiveInfo.DataStartPosition += db.ArchiveInfo.StartPositionAfterHeader;
type = ReadID();
}
else
{
for (int i = 0; i < db.Folders.Size(); i++)
{
db.NumUnpackStreamsVector.Add(1);
CFolder &folder = db.Folders[i];
unpackSizes.Add(folder.GetUnpackSize());
digestsDefined.Add(folder.UnpackCRCDefined);
digests.Add(folder.UnpackCRC);
}
}
db.Files.Clear();
if (type == NID::kEnd)
return S_OK;
if (type != NID::kFilesInfo)
ThrowIncorrect();
CNum numFiles = ReadNum();
db.Files.Reserve(numFiles);
CNum i;
for (i = 0; i < numFiles; i++)
db.Files.Add(CFileItem());
db.ArchiveInfo.FileInfoPopIDs.Add(NID::kSize);
if (!db.PackSizes.IsEmpty())
db.ArchiveInfo.FileInfoPopIDs.Add(NID::kPackInfo);
if (numFiles > 0 && !digests.IsEmpty())
db.ArchiveInfo.FileInfoPopIDs.Add(NID::kCRC);
CBoolVector emptyStreamVector;
BoolVector_Fill_False(emptyStreamVector, (int)numFiles);
CBoolVector emptyFileVector;
CBoolVector antiFileVector;
CNum numEmptyStreams = 0;
for (;;)
{
UInt64 type = ReadID();
if (type == NID::kEnd)
break;
UInt64 size = ReadNumber();
size_t ppp = _inByteBack->_pos;
bool addPropIdToList = true;
bool isKnownType = true;
if (type > ((UInt32)1 << 30))
//.........这里部分代码省略.........
示例3: CheckFinishedState
HRESULT CheckFinishedState() const { return (_currentIndex == _extractStatuses->Size()) ? S_OK: E_FAIL; }