mirror of
https://github.com/LongSoft/UEFITool.git
synced 2024-11-30 03:48:22 +08:00
5b43099d78
- ported after engine refactoring, no new features
44 lines
1.2 KiB
C++
44 lines
1.2 KiB
C++
/* uefidump.h
|
|
|
|
Copyright (c) 2016, Nikolaj Schlej. All rights reserved.
|
|
This program and the accompanying materials
|
|
are licensed and made available under the terms and conditions of the BSD License
|
|
which accompanies this distribution. The full text of the license may be found at
|
|
http://opensource.org/licenses/bsd-license.php
|
|
|
|
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
|
|
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
|
|
|
|
*/
|
|
|
|
#ifndef UEFIDUMP_H
|
|
#define UEFIDUMP_H
|
|
|
|
#include "../common/basetypes.h"
|
|
#include "../common/ustring.h"
|
|
#include "../common/treemodel.h"
|
|
#include "../common/ffsparser.h"
|
|
#include "../common/ffsreport.h"
|
|
|
|
class UEFIDumper
|
|
{
|
|
public:
|
|
explicit UEFIDumper() : model(), ffsParser(&model), ffsReport(&model), currentBuffer(), initialized(false), dumped(false) {}
|
|
~UEFIDumper() {}
|
|
|
|
USTATUS dump(const UByteArray & buffer, const UString & path, const UString & guid = UString());
|
|
|
|
private:
|
|
USTATUS recursiveDump(const UModelIndex & root);
|
|
|
|
TreeModel model;
|
|
FfsParser ffsParser;
|
|
FfsReport ffsReport;
|
|
|
|
UByteArray currentBuffer;
|
|
bool initialized;
|
|
bool dumped;
|
|
};
|
|
|
|
#endif
|