1 /* 2 * Copyright (C) 2011 Raphael Coeffic 3 * 2012 Frafos GmbH 4 * 5 * This file is part of SEMS, a free SIP media server. 6 * 7 * SEMS is free software; you can redistribute it and/or modify 8 * it under the terms of the GNU General Public License as published by 9 * the Free Software Foundation; either version 2 of the License, or 10 * (at your option) any later version. This program is released under 11 * the GPL with the additional exemption that compiling, linking, 12 * and/or using OpenSSL is allowed. 13 * 14 * For a license to use the SEMS software under conditions 15 * other than those described here, or to purchase support for this 16 * software, please contact iptel.org by e-mail at the following addresses: 17 * info@iptel.org 18 * 19 * SEMS is distributed in the hope that it will be useful, 20 * but WITHOUT ANY WARRANTY; without even the implied warranty of 21 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 22 * GNU General Public License for more details. 23 * 24 * You should have received a copy of the GNU General Public License 25 * along with this program; if not, write to the Free Software 26 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 27 */ 28 #ifndef _parse_nameaddr_h_ 29 #define _parse_nameaddr_h_ 30 31 #include "parse_uri.h" 32 33 struct sip_nameaddr 34 { 35 36 cstring name; 37 cstring addr; 38 39 sip_uri uri; 40 41 list<sip_avp*> params; 42 sip_nameaddrsip_nameaddr43 sip_nameaddr() {} 44 ~sip_nameaddr(); 45 }; 46 47 int parse_nameaddr(sip_nameaddr* na, const char** c, int len); 48 int parse_nameaddr_uri(sip_nameaddr* na, const char** c, int len); 49 int parse_first_nameaddr(sip_nameaddr* na, const char* c, int len); 50 int parse_nameaddr_list(list<cstring>& nas, const char* c, int len); 51 52 #endif 53