Branch data Line data Source code
1 : : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : : /*
3 : : * This file is part of the LibreOffice project.
4 : : *
5 : : * This Source Code Form is subject to the terms of the Mozilla Public
6 : : * License, v. 2.0. If a copy of the MPL was not distributed with this
7 : : * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 : : *
9 : : * This file incorporates work covered by the following license notice:
10 : : *
11 : : * Licensed to the Apache Software Foundation (ASF) under one or more
12 : : * contributor license agreements. See the NOTICE file distributed
13 : : * with this work for additional information regarding copyright
14 : : * ownership. The ASF licenses this file to you under the Apache
15 : : * License, Version 2.0 (the "License"); you may not use this file
16 : : * except in compliance with the License. You may obtain a copy of
17 : : * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 : : */
19 : :
20 : : #ifndef X2C_CMDLINE_HXX
21 : : #define X2C_CMDLINE_HXX
22 : :
23 : : #include "sistr.hxx"
24 : :
25 : : class CommandLine
26 : : {
27 : : public:
28 : : CommandLine(
29 : : int i_argc,
30 : : char * i_argv[] );
31 : : ~CommandLine();
32 : :
33 : 2 : bool IsOk() const { return bIsOk; }
34 : : const char * ErrorText() const;
35 : :
36 : 2 : const char * XmlSrcFile() const { return sXmlSourceFile.str(); }
37 : 2 : const char * FuncFile() const { return sFuncFile.str(); }
38 : 2 : const char * HtmlFile() const { return sHtmlFile.str(); }
39 : 4 : const char * TypeInfoFile() const { return sTypeInfoFile.str(); }
40 : 0 : const char * DepPath() const { return sDepPath.str(); }
41 : :
42 : 2 : bool IsDepCommand() const { return sDepPath.l() > 0; }
43 : : const char * XmlSrcDirectory() const { return sXmlSourceDirectory.str(); }
44 : : const char * OutputDirectory() const { return sOutputDirectory.str(); }
45 : :
46 : 0 : const char * IdlRootPath() const { return sIdlRootPath.str(); }
47 : :
48 : : private:
49 : : void ParseSingleFileCommand(
50 : : int argc,
51 : : char * argv[] );
52 : : Simstr sXmlSourceFile;
53 : : Simstr sFuncFile;
54 : : Simstr sHtmlFile;
55 : : Simstr sTypeInfoFile;
56 : :
57 : : Simstr sXmlSourceDirectory;
58 : : Simstr sOutputDirectory;
59 : :
60 : : Simstr sIdlRootPath;
61 : : Simstr sDepPath;
62 : :
63 : : bool bIsOk;
64 : : };
65 : :
66 : :
67 : :
68 : :
69 : : #endif
70 : :
71 : : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|