File: cteb.h

package info (click to toggle)
ion 3.2.1%2Bdfsg-1.1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 23,768 kB
  • ctags: 11,049
  • sloc: ansic: 141,798; sh: 22,848; makefile: 7,818; python: 1,638; sql: 311; perl: 197; awk: 178; xml: 50; java: 19
file content (44 lines) | stat: -rw-r--r-- 1,502 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
/*
 *	cteb.h:		definitions supporting implementation of
 *			the Custody Transfer Enhancement Block (CTEB).
 *
 *  Copyright (c) 2010-2011, Regents of the University of Colorado.
 *  This work was supported by NASA contracts NNJ05HE10G, NNC06CB40C, and
 *  NNC07CB47C.
 *
 *	Author: Andrew Jenkins, University of Colorado
 */

#ifndef _CTEB_H_
#define _CTEB_H_

#include "bei.h"

#define	EXTENSION_TYPE_CTEB	10

typedef struct {
    unsigned int id;
} CtebScratchpad;

extern int	cteb_offer(ExtensionBlock *, Bundle *);
extern void	cteb_release(ExtensionBlock *);
extern int	cteb_record(ExtensionBlock *, AcqExtBlock *);
extern int	cteb_copy(ExtensionBlock *, ExtensionBlock *);
extern int	cteb_processOnFwd(ExtensionBlock *, Bundle *, void *);
extern int	cteb_processOnAccept(ExtensionBlock *, Bundle *, void *);
extern int	cteb_processOnEnqueue(ExtensionBlock *, Bundle *, void *);
extern int	cteb_processOnDequeue(ExtensionBlock *, Bundle *, void *);
extern int	cteb_acquire(AcqExtBlock *, AcqWorkArea *);
extern int	cteb_check(AcqExtBlock *, AcqWorkArea *);
extern void	cteb_clear(AcqExtBlock *);

/* Looks in the bundle's extensions for a valid custody transfer enhancement
 * block.  If one is found, load the custody id.
 *
 * If calling before extensions have been recorded to SDR, AcqWorkArea should
 * be valid; otherwise, it should be NULL.
 *
 * Returns -1 if no valid CTEB is found. */
extern int  loadCtebScratchpad(Sdr, Bundle *, AcqWorkArea *, CtebScratchpad *);

#endif /* _CTEB_H_ */