1*bb4632f1SStefano Ceccherini /* 2*bb4632f1SStefano Ceccherini * Copyright 2005, Ingo Weinhold, bonefish@users.sf.net. 3*bb4632f1SStefano Ceccherini * Distributed under the terms of the MIT License. 4*bb4632f1SStefano Ceccherini */ 5*bb4632f1SStefano Ceccherini 6*bb4632f1SStefano Ceccherini #ifndef ARGUMENTS_H 7*bb4632f1SStefano Ceccherini #define ARGUMENTS_H 8*bb4632f1SStefano Ceccherini 9*bb4632f1SStefano Ceccherini #include <Rect.h> 10*bb4632f1SStefano Ceccherini 11*bb4632f1SStefano Ceccherini class Arguments { 12*bb4632f1SStefano Ceccherini public: 13*bb4632f1SStefano Ceccherini Arguments(); 14*bb4632f1SStefano Ceccherini ~Arguments(); 15*bb4632f1SStefano Ceccherini 16*bb4632f1SStefano Ceccherini void Parse(int argc, const char *const *argv); 17*bb4632f1SStefano Ceccherini 18*bb4632f1SStefano Ceccherini BRect Bounds() const { return fBounds; } 19*bb4632f1SStefano Ceccherini const char *Title() const { return fTitle; } 20*bb4632f1SStefano Ceccherini bool StandardShell() const { return fStandardShell; } 21*bb4632f1SStefano Ceccherini bool FullScreen() const { return fFullScreen; } 22*bb4632f1SStefano Ceccherini bool UsageRequested() const { return fUsageRequested; } 23*bb4632f1SStefano Ceccherini void GetShellArguments(int &argc, const char *const *&argv) const; 24*bb4632f1SStefano Ceccherini 25*bb4632f1SStefano Ceccherini private: 26*bb4632f1SStefano Ceccherini void _SetShellArguments(int argc, const char *const *argv); 27*bb4632f1SStefano Ceccherini 28*bb4632f1SStefano Ceccherini bool fUsageRequested; 29*bb4632f1SStefano Ceccherini BRect fBounds; 30*bb4632f1SStefano Ceccherini bool fStandardShell; 31*bb4632f1SStefano Ceccherini bool fFullScreen; 32*bb4632f1SStefano Ceccherini int fShellArgumentCount; 33*bb4632f1SStefano Ceccherini const char **fShellArguments; 34*bb4632f1SStefano Ceccherini const char *fTitle; 35*bb4632f1SStefano Ceccherini }; 36*bb4632f1SStefano Ceccherini 37*bb4632f1SStefano Ceccherini 38*bb4632f1SStefano Ceccherini #endif // ARGUMENTS_H 39