119370Spst/* Copyright (c) 2008 The NetBSD Foundation, Inc.
219370Spst * All rights reserved.
319370Spst *
4130803Smarcel * Redistribution and use in source and binary forms, with or without
5130803Smarcel * modification, are permitted provided that the following conditions
6130803Smarcel * are met:
798944Sobrien * 1. Redistributions of source code must retain the above copyright
819370Spst *    notice, this list of conditions and the following disclaimer.
998944Sobrien * 2. Redistributions in binary form must reproduce the above copyright
1098944Sobrien *    notice, this list of conditions and the following disclaimer in the
1198944Sobrien *    documentation and/or other materials provided with the distribution.
1298944Sobrien *
1319370Spst * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND
1498944Sobrien * CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
1598944Sobrien * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
1698944Sobrien * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
1798944Sobrien * IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS BE LIABLE FOR ANY
1819370Spst * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
1998944Sobrien * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
2098944Sobrien * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
2198944Sobrien * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
2298944Sobrien * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
2319370Spst * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
2419370Spst * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.  */
2519370Spst
2619370Spst#if !defined(ATF_C_DETAIL_TEXT_H)
27130803Smarcel#define ATF_C_DETAIL_TEXT_H
28130803Smarcel
29130803Smarcel#include <stdarg.h>
30130803Smarcel#include <stdbool.h>
31130803Smarcel
32130803Smarcel#include <atf-c/detail/list.h>
33130803Smarcel#include <atf-c/error_fwd.h>
3419370Spst
3519370Spstatf_error_t atf_text_for_each_word(const char *, const char *,
3619370Spst                                   atf_error_t (*)(const char *, void *),
3719370Spst                                   void *);
3819370Spstatf_error_t atf_text_format(char **, const char *, ...);
3919370Spstatf_error_t atf_text_format_ap(char **, const char *, va_list);
40130803Smarcelatf_error_t atf_text_split(const char *, const char *, atf_list_t *);
41130803Smarcelatf_error_t atf_text_to_bool(const char *, bool *);
42130803Smarcelatf_error_t atf_text_to_long(const char *, long *);
4398944Sobrien
4419370Spst#endif /* !defined(ATF_C_DETAIL_TEXT_H) */
4519370Spst