]>
Commit | Line | Data |
---|---|---|
7fa2d1a0 | 1 | /* |
6606c3ae | 2 | * Copyright (C) 2003-2004 Sistina Software, Inc. All rights reserved. |
be684599 | 3 | * Copyright (C) 2004-2007 Red Hat, Inc. All rights reserved. |
7fa2d1a0 | 4 | * |
6606c3ae AK |
5 | * This file is part of LVM2. |
6 | * | |
7 | * This copyrighted material is made available to anyone wishing to use, | |
8 | * modify, copy, or redistribute it subject to the terms and conditions | |
be684599 | 9 | * of the GNU Lesser General Public License v.2.1. |
6606c3ae | 10 | * |
be684599 | 11 | * You should have received a copy of the GNU Lesser General Public License |
6606c3ae | 12 | * along with this program; if not, write to the Free Software Foundation, |
fcbef05a | 13 | * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
7fa2d1a0 AK |
14 | */ |
15 | ||
16 | #ifndef _LVM_CMDLINE_H | |
17 | #define _LVM_CMDLINE_H | |
18 | ||
6711231a AK |
19 | struct cmd_context; |
20 | ||
f359c9b8 | 21 | struct cmdline_context { |
45d9b2c4 | 22 | const struct opt_name *opt_names; |
1e2420bc DT |
23 | struct command *commands; |
24 | int num_commands; | |
82617852 ZK |
25 | const struct command_name *command_names; |
26 | const struct command_name_args *command_names_args; | |
1e2420bc | 27 | int num_command_names; |
f359c9b8 AK |
28 | }; |
29 | ||
02961979 | 30 | int lvm2_main(int argc, char **argv); |
6711231a | 31 | |
bd272e3b | 32 | void *cmdlib_lvm2_init(unsigned static_compile, unsigned threaded); |
6711231a AK |
33 | void lvm_fin(struct cmd_context *cmd); |
34 | ||
bd272e3b | 35 | struct cmd_context *init_lvm(unsigned set_connections, unsigned set_filters, unsigned threaded); |
15eaf703 | 36 | int lvm_register_commands(struct cmd_context *cmdtool, const char *name); |
6711231a AK |
37 | int lvm_split(char *str, int *argc, char **argv, int max); |
38 | int lvm_run_command(struct cmd_context *cmd, int argc, char **argv); | |
94d4a90f | 39 | int lvm_return_code(int ret); |
f359c9b8 | 40 | int lvm_shell(struct cmd_context *cmd, struct cmdline_context *cmdline); |
7fa2d1a0 AK |
41 | |
42 | #endif |