1 : // Copyright 2015 Google Inc. All Rights Reserved.
2 : //
3 : // Licensed under the Apache License, Version 2.0 (the "License");
4 : // you may not use this file except in compliance with the License.
5 : // You may obtain a copy of the License at
6 : //
7 : // http://www.apache.org/licenses/LICENSE-2.0
8 : //
9 : // Unless required by applicable law or agreed to in writing, software
10 : // distributed under the License is distributed on an "AS IS" BASIS,
11 : // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 : // See the License for the specific language governing permissions and
13 : // limitations under the License.
14 :
15 : #ifndef SYZYGY_POIROT_POIROT_APP_H_
16 : #define SYZYGY_POIROT_POIROT_APP_H_
17 :
18 : #include "base/command_line.h"
19 : #include "base/files/file_path.h"
20 : #include "base/strings/string_piece.h"
21 : #include "syzygy/application/application.h"
22 : #include "syzygy/poirot/minidump_processor.h"
23 :
24 : namespace poirot {
25 :
26 : // This class implements the minidump processor command-line utility.
27 : //
28 : // See the description given in PoirotApp:::PrintUsage() for
29 : // information about running this utility.
30 : class PoirotApp : public application::AppImplBase {
31 : public:
32 : // @name Implementation of the AppImplBase interface.
33 : // @{
34 E : PoirotApp() : application::AppImplBase("PoirotApp") {}
35 :
36 : bool ParseCommandLine(const base::CommandLine* command_line);
37 :
38 : int Run();
39 : // @}
40 :
41 : protected:
42 : // @name Utility function
43 : // @{
44 : void PrintUsage(const base::FilePath& program,
45 : const base::StringPiece& message);
46 : // @}
47 :
48 : // @name Command-line options.
49 : // @{
50 : base::FilePath input_minidump_;
51 : base::FilePath output_file_;
52 : // @}
53 :
54 : private:
55 : DISALLOW_COPY_AND_ASSIGN(PoirotApp);
56 : };
57 :
58 : } // namespace poirot
59 :
60 : #endif // SYZYGY_POIROT_POIROT_APP_H_
|