librsync  2.3.4
command.h
Go to the documentation of this file.
1/*= -*- c-basic-offset: 4; indent-tabs-mode: nil; -*-
2 *
3 * librsync -- library for network deltas
4 *
5 * Copyright (C) 1999, 2000, 2001 by Martin Pool <mbp@sourcefrog.net>
6 * Copyright (C) 1999 by Andrew Tridgell <tridge@samba.org>
7 *
8 * This program is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Lesser General Public License
10 * as published by the Free Software Foundation; either version 2.1 of
11 * the License, or (at your option) any later version.
12 *
13 * This program is distributed in the hope that it will be useful, but
14 * WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Lesser General Public License for more details.
17 *
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with this program; if not, write to the Free Software
20 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
21 */
22
23/** \file command.h
24 * Types of commands present in the encoding stream.
25 *
26 * The vague idea is that eventually this file will be more abstract than
27 * protocol.h, but it's not clear that will ever be required. */
28#ifndef COMMAND_H
29# define COMMAND_H
30
31/** Classes of operation that can be present. Each may have several different
32 * possible representations. */
34 RS_KIND_END = 1000,
35 RS_KIND_LITERAL,
36 RS_KIND_SIGNATURE,
37 RS_KIND_COPY,
38 RS_KIND_CHECKSUM,
39 RS_KIND_RESERVED, /* for future expansion */
40
41 /* This one should never occur in file streams. It's an internal marker for
42 invalid commands. */
43 RS_KIND_INVALID
44};
45
46typedef struct rs_op_kind_name {
47 char const *name;
48 enum rs_op_kind const kind;
50
51char const *rs_op_kind_name(enum rs_op_kind);
52
53#endif /* !COMMAND_H */
rs_op_kind
Classes of operation that can be present.
Definition: command.h:33
char const * rs_op_kind_name(enum rs_op_kind)
Return a human-readable name for KIND.
Definition: command.c:38