langinfo.h revision 232498
187744Sphantom/*- 287659Sphantom * Copyright (c) 2001 Alexey Zelkin <phantom@FreeBSD.org> 372169Sphantom * All rights reserved. 472169Sphantom * 572169Sphantom * Redistribution and use in source and binary forms, with or without 672169Sphantom * modification, are permitted provided that the following conditions 772169Sphantom * are met: 872169Sphantom * 1. Redistributions of source code must retain the above copyright 972169Sphantom * notice, this list of conditions and the following disclaimer. 1072169Sphantom * 2. Redistributions in binary form must reproduce the above copyright 1172169Sphantom * notice, this list of conditions and the following disclaimer in the 1272169Sphantom * documentation and/or other materials provided with the distribution. 1372169Sphantom * 1472169Sphantom * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 1572169Sphantom * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 1672169Sphantom * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 1772169Sphantom * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 1872169Sphantom * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 1972169Sphantom * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 2072169Sphantom * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 2172169Sphantom * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 2272169Sphantom * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 2372169Sphantom * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 2472169Sphantom * SUCH DAMAGE. 2572169Sphantom * 2672169Sphantom * $FreeBSD: head/include/langinfo.h 232498 2012-03-04 15:31:13Z theraven $ 2772169Sphantom */ 2872169Sphantom 2987744Sphantom#ifndef _LANGINFO_H_ 3087744Sphantom#define _LANGINFO_H_ 3172169Sphantom 3272169Sphantom#include <sys/cdefs.h> 33103522Smike#include <sys/_types.h> 3472169Sphantom 35103522Smike#ifndef _NL_ITEM_DECLARED 36103522Smiketypedef __nl_item nl_item; 37103522Smike#define _NL_ITEM_DECLARED 38103522Smike#endif 39103522Smike 4072169Sphantom#define CODESET 0 /* codeset name */ 4172169Sphantom#define D_T_FMT 1 /* string for formatting date and time */ 4272169Sphantom#define D_FMT 2 /* date format string */ 4372169Sphantom#define T_FMT 3 /* time format string */ 4472169Sphantom#define T_FMT_AMPM 4 /* a.m. or p.m. time formatting string */ 4572169Sphantom#define AM_STR 5 /* Ante Meridian affix */ 4672169Sphantom#define PM_STR 6 /* Post Meridian affix */ 4772169Sphantom 4872169Sphantom/* week day names */ 4972169Sphantom#define DAY_1 7 5072169Sphantom#define DAY_2 8 5172169Sphantom#define DAY_3 9 5272169Sphantom#define DAY_4 10 5372169Sphantom#define DAY_5 11 5472169Sphantom#define DAY_6 12 5572169Sphantom#define DAY_7 13 5672169Sphantom 5772169Sphantom/* abbreviated week day names */ 5872169Sphantom#define ABDAY_1 14 5972169Sphantom#define ABDAY_2 15 6072169Sphantom#define ABDAY_3 16 6172169Sphantom#define ABDAY_4 17 6272169Sphantom#define ABDAY_5 18 6372169Sphantom#define ABDAY_6 19 6472169Sphantom#define ABDAY_7 20 6572169Sphantom 6672169Sphantom/* month names */ 6772169Sphantom#define MON_1 21 6872169Sphantom#define MON_2 22 6972169Sphantom#define MON_3 23 7072169Sphantom#define MON_4 24 7172169Sphantom#define MON_5 25 7272169Sphantom#define MON_6 26 7372169Sphantom#define MON_7 27 7472169Sphantom#define MON_8 28 7572169Sphantom#define MON_9 29 7672169Sphantom#define MON_10 30 7772169Sphantom#define MON_11 31 7872169Sphantom#define MON_12 32 7972169Sphantom 8072169Sphantom/* abbreviated month names */ 8172169Sphantom#define ABMON_1 33 8272169Sphantom#define ABMON_2 34 8372169Sphantom#define ABMON_3 35 8472169Sphantom#define ABMON_4 36 8572169Sphantom#define ABMON_5 37 8672169Sphantom#define ABMON_6 38 8772169Sphantom#define ABMON_7 39 8872169Sphantom#define ABMON_8 40 8972169Sphantom#define ABMON_9 41 9072169Sphantom#define ABMON_10 42 9172169Sphantom#define ABMON_11 43 9272169Sphantom#define ABMON_12 44 9372169Sphantom 9472169Sphantom#define ERA 45 /* era description segments */ 9572169Sphantom#define ERA_D_FMT 46 /* era date format string */ 9672169Sphantom#define ERA_D_T_FMT 47 /* era date and time format string */ 9772169Sphantom#define ERA_T_FMT 48 /* era time format string */ 9872169Sphantom#define ALT_DIGITS 49 /* alternative symbols for digits */ 9972169Sphantom 10072169Sphantom#define RADIXCHAR 50 /* radix char */ 10172169Sphantom#define THOUSEP 51 /* separator for thousands */ 10272169Sphantom 10372169Sphantom#define YESEXPR 52 /* affirmative response expression */ 10472169Sphantom#define NOEXPR 53 /* negative response expression */ 105103522Smike 106103522Smike#if __BSD_VISIBLE || __XSI_VISIBLE <= 500 10772169Sphantom#define YESSTR 54 /* affirmative response for yes/no queries */ 10872169Sphantom#define NOSTR 55 /* negative response for yes/no queries */ 109103522Smike#endif 11072169Sphantom 11172169Sphantom#define CRNCYSTR 56 /* currency symbol */ 11272169Sphantom 113103522Smike#if __BSD_VISIBLE 11474458Sache#define D_MD_ORDER 57 /* month/day order (local extension) */ 115103522Smike#endif 11674458Sache 117197764Sedwin/* standalone months forms for %OB */ 118197764Sedwin#define ALTMON_1 58 119197764Sedwin#define ALTMON_2 59 120197764Sedwin#define ALTMON_3 60 121197764Sedwin#define ALTMON_4 61 122197764Sedwin#define ALTMON_5 62 123197764Sedwin#define ALTMON_6 63 124197764Sedwin#define ALTMON_7 64 125197764Sedwin#define ALTMON_8 65 126197764Sedwin#define ALTMON_9 66 127197764Sedwin#define ALTMON_10 67 128197764Sedwin#define ALTMON_11 68 129197764Sedwin#define ALTMON_12 69 130197764Sedwin 13172169Sphantom__BEGIN_DECLS 13293032Simpchar *nl_langinfo(nl_item); 133232498Stheraven 134232498Stheraven#if __POSIX_VISIBLE >= 200809 135232498Stheraven#include <xlocale/_langinfo.h> 136232498Stheraven#endif 13772169Sphantom__END_DECLS 13872169Sphantom 13987744Sphantom#endif /* !_LANGINFO_H_ */ 140