4 * @brief Interface job_t.
9 * Copyright (C) 2005 Jan Hutter, Martin Willi
10 * Hochschule fuer Technik Rapperswil
12 * This program is free software; you can redistribute it and/or modify it
13 * under the terms of the GNU General Public License as published by the
14 * Free Software Foundation; either version 2 of the License, or (at your
15 * option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>.
17 * This program is distributed in the hope that it will be useful, but
18 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
19 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
27 #include <definitions.h>
30 typedef enum job_type_t job_type_t
;
33 * @brief Definition of the various job types.
35 * @todo add more jobs, such as rekeying.
41 * Process an incoming IKEv2-Message.
43 * Job is implemented in class type incoming_packet_job_t
48 * Retransmit an IKEv2-Message.
53 * Establish an ike sa as initiator.
55 * Job is implemented in class type initiate_ike_sa_job_t
60 * Delete an ike sa which is still not established.
62 * Job is implemented in class type delete_half_open_ike_sa_job_t
64 DELETE_HALF_OPEN_IKE_SA
,
67 * Delete an ike sa which is established.
69 * Job is implemented in class type delete_established_ike_sa_job_t
71 DELETE_ESTABLISHED_IKE_SA
75 * string mappings for job_type_t
79 extern mapping_t job_type_m
[];
82 typedef struct job_t job_t
;
85 * @brief Job-Interface as it is stored in the job queue.
87 * A job consists of a job-type and one or more assigned values.
90 * - None, use specific implementation of the interface.
97 * @brief get type of job.
99 * @param this calling object
100 * @return type of this job
102 job_type_t (*get_type
) (job_t
*this);
105 * @brief Destroys a job_t object and all assigned data!
107 * @param job_t calling object
109 void (*destroy_all
) (job_t
*job
);
112 * @brief Destroys a job_t object
114 * @param job_t calling object
116 void (*destroy
) (job_t
*job
);