1 //===-- MICmdArgContext.h ---------------------------------------*- C++ -*-===//
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
12 #include "MIUtilString.h"
15 //============================================================================
16 // Details: MI common code class. Command arguments and options string. Holds
17 // the context string.
18 // Based on the Interpreter pattern.
20 class CMICmdArgContext {
23 /* ctor */ CMICmdArgContext();
24 /* ctor */ CMICmdArgContext(const CMIUtilString &vrCmdLineArgsRaw);
26 const CMIUtilString &GetArgsLeftToParse() const;
27 size_t GetNumberArgsPresent() const;
28 CMIUtilString::VecString_t GetArgs() const;
30 bool RemoveArg(const CMIUtilString &vArg);
31 bool RemoveArgAtPos(const CMIUtilString &vArg, size_t nArgIndex);
33 CMICmdArgContext &operator=(const CMICmdArgContext &vOther);
38 /* dtor */ virtual ~CMICmdArgContext();
42 CMIUtilString m_strCmdArgsAndOptions;