155682Smarkm/* $NetBSD$ */ 2233294Sstas 3233294Sstas/* 4233294Sstas * Copyright (C) 2003-2004 Sistina Software, Inc. All rights reserved. 555682Smarkm * Copyright (C) 2004-2005 Red Hat, Inc. All rights reserved. 6233294Sstas * 7233294Sstas * This file is part of LVM2. 8233294Sstas * 955682Smarkm * This copyrighted material is made available to anyone wishing to use, 10233294Sstas * modify, copy, or redistribute it subject to the terms and conditions 11233294Sstas * of the GNU Lesser General Public License v.2.1. 1255682Smarkm * 13233294Sstas * You should have received a copy of the GNU Lesser General Public License 14233294Sstas * along with this program; if not, write to the Free Software Foundation, 15233294Sstas * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 1655682Smarkm */ 17233294Sstas 18233294Sstas#ifndef _LVM_TEXT_EXPORT_H 19233294Sstas#define _LVM_TEXT_EXPORT_H 2055682Smarkm 21233294Sstas#define outf(args...) do {if (!out_text(args)) return_0;} while (0) 22233294Sstas#define outnl(f) do {if (!out_newline(f)) return_0;} while (0) 23233294Sstas 24233294Sstasstruct formatter; 25233294Sstasstruct lv_segment; 26233294Sstasstruct config_node; 27233294Sstas 28233294Sstasint out_size(struct formatter *f, uint64_t size, const char *fmt, ...) 29233294Sstas __attribute__ ((format(printf, 3, 4))); 30233294Sstas 31233294Sstasint out_hint(struct formatter *f, const char *fmt, ...) 3255682Smarkm __attribute__ ((format(printf, 2, 3))); 3355682Smarkm 3455682Smarkmint out_text(struct formatter *f, const char *fmt, ...) 35178825Sdfr __attribute__ ((format(printf, 2, 3))); 3655682Smarkm 3772445Sassarint out_config_node(struct formatter *f, const struct config_node *cn); 3872445Sassar 3972445Sassarint out_areas(struct formatter *f, const struct lv_segment *seg, 4072445Sassar const char *type); 4155682Smarkm 42178825Sdfrvoid out_inc_indent(struct formatter *f); 4355682Smarkmvoid out_dec_indent(struct formatter *f); 4455682Smarkmint out_newline(struct formatter *f); 4555682Smarkm 4655682Smarkm#endif 4755682Smarkm