1
/* $Id: lib_authn_response_envelope.c,v 1.2 2004/08/13 15:16:13 fpeters Exp $
3
* Lasso - A free implementation of the Liberty Alliance specifications.
5
* Copyright (C) 2004 Entr'ouvert
6
* http://lasso.entrouvert.org
8
* Authors: Nicolas Clapies <nclapies@entrouvert.com>
9
* Valery Febvre <vfebvre@easter-eggs.com>
11
* This program is free software; you can redistribute it and/or modify
12
* it under the terms of the GNU General Public License as published by
13
* the Free Software Foundation; either version 2 of the License, or
14
* (at your option) any later version.
16
* This program is distributed in the hope that it will be useful,
17
* but WITHOUT ANY WARRANTY; without even the implied warranty of
18
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19
* GNU General Public License for more details.
21
* You should have received a copy of the GNU General Public License
22
* along with this program; if not, write to the Free Software
23
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
26
#include <lasso/xml/lib_authn_response_envelope.h>
30
/*****************************************************************************/
32
/*****************************************************************************/
35
lasso_lib_authn_response_envelope_set_extension(LassoLibAuthnResponseEnvelope *node,
38
LassoNodeClass *class;
39
g_assert(LASSO_IS_LIB_AUTHN_RESPONSE_ENVELOPE(node));
40
g_assert(LASSO_NODE(extension));
42
class = LASSO_NODE_GET_CLASS(node);
43
class->add_child(LASSO_NODE(extension), extension, FALSE);
47
lasso_lib_authn_response_envelope_set_authnResponse(LassoLibAuthnResponseEnvelope *node,
48
LassoLibAuthnResponse *authnResponse_node)
50
LassoNodeClass *class;
51
g_assert(LASSO_IS_LIB_AUTHN_RESPONSE_ENVELOPE(node));
52
g_assert(LASSO_IS_LIB_AUTHN_RESPONSE(authnResponse_node));
54
class = LASSO_NODE_GET_CLASS(node);
55
class->add_child(LASSO_NODE(node), LASSO_NODE(authnResponse_node), FALSE);
59
lasso_lib_authn_response_envelope_set_assertionConsumerServiceURL(LassoLibAuthnResponseEnvelope *node,
62
LassoNodeClass *class;
63
g_assert(LASSO_IS_LIB_AUTHN_RESPONSE_ENVELOPE(node));
64
g_assert(url != NULL);
66
class = LASSO_NODE_GET_CLASS(node);
67
class->new_child(LASSO_NODE (node), "AssertionConsumerServiceURL",
71
/*****************************************************************************/
72
/* instance and class init functions */
73
/*****************************************************************************/
76
lasso_lib_authn_response_envelope_instance_init(LassoLibAuthnResponseEnvelope *node)
78
LassoNodeClass *class = LASSO_NODE_GET_CLASS(LASSO_NODE(node));
80
class->set_ns(LASSO_NODE(node), lassoLibHRef, lassoLibPrefix);
81
class->set_name(LASSO_NODE(node), "AuthnResponseEnvelope");
85
lasso_lib_authn_response_envelope_class_init(LassoLibAuthnResponseEnvelopeClass *class)
89
GType lasso_lib_authn_response_envelope_get_type() {
90
static GType this_type = 0;
93
static const GTypeInfo this_info = {
94
sizeof (LassoLibAuthnResponseEnvelopeClass),
97
(GClassInitFunc) lasso_lib_authn_response_envelope_class_init,
100
sizeof(LassoLibAuthnResponseEnvelope),
102
(GInstanceInitFunc) lasso_lib_authn_response_envelope_instance_init,
105
this_type = g_type_register_static(LASSO_TYPE_NODE,
106
"LassoLibAuthnResponseEnvelope",
112
LassoNode* lasso_lib_authn_response_envelope_new() {
113
return LASSO_NODE(g_object_new(LASSO_TYPE_LIB_AUTHN_RESPONSE_ENVELOPE,