Skip to content
options.hh 1.09 KiB
Newer Older
Seblu's avatar
Seblu committed
/*
  This file is part of SLC.
Seblu's avatar
Seblu committed
  Copyright (C) 2008 Sebastien LUTTRINGER <contact@seblu.net>
Seblu's avatar
Seblu committed

  SLC is free software; you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
Seblu's avatar
Seblu committed
  the Free Software Foundation; version 2 of the License.
Seblu's avatar
Seblu committed

  SLC is distributed in the hope that it will be useful,
  but WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  GNU General Public License for more details.

  You should have received a copy of the GNU General Public License
  along with SLC; if not, write to the Free Software
Seblu's avatar
Seblu committed
  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
Seblu's avatar
Seblu committed
*/

Seblu's avatar
Seblu committed
#ifndef OPTIONS_HH
# define OPTIONS_HH

struct Options {
  Options();

  Options &load(int argc, char *argv[]);
  Options &loadenv();

Seblu's avatar
Seblu committed
  void usage(const char *name, ostream &out) const;

  friend ostream &operator<<(ostream &, const Options &);

  string server;
  int port; //-1 undef
  string login;
  string pass;
  string history_file;
  size_t history_size;
  size_t log_size;
Seblu's avatar
Seblu committed
};

#endif