File: catopen.3

package info (click to toggle)
manpages-es 1.24a-6
  • links: PTS
  • area: main
  • in suites: potato
  • size: 4,256 kB
  • ctags: 7
  • sloc: makefile: 66; sh: 62
file content (144 lines) | stat: -rw-r--r-- 4,144 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
.\" Copyright 1993 Mitchum DSouza <m.dsouza@mrc-applied-psychology.cambridge.ac.uk>
.\"
.\" Permission is granted to make and distribute verbatim copies of this
.\" manual provided the copyright notice and this permission notice are
.\" preserved on all copies.
.\"
.\" Permission is granted to copy and distribute modified versions of this
.\" manual under the conditions for verbatim copying, provided that the
.\" entire resulting derived work is distributed under the terms of a
.\" permission notice identical to this one
.\" 
.\" Since the Linux kernel and libraries are constantly changing, this
.\" manual page may be incorrect or out-of-date.  The author(s) assume no
.\" responsibility for errors or omissions, or for damages resulting from
.\" the use of the information contained herein.  The author(s) may not
.\" have taken the same level of care in the production of this manual,
.\" which is licensed free of charge, as they might when working
.\" professionally.
.\" 
.\" Formatted or processed versions of this manual, if unaccompanied by
.\" the source, must acknowledge the copyright and authors of this work.
.\"
.\"
.\" Traducido al castellano (con permiso) por:
.\" Sebastian Desimone (chipy@argenet.com.ar) (desimone@fasta.edu.ar)
.\" Translation fixed on Wed Apr 22 12:52:20 CEST 1998 by Gerardo
.\" Aburruzaga Garca <gerardo.aburruzaga@uca.es> 
.\"
.TH CATOPEN 3 "30 Noviembre 1993" "Linux" "Manual del Programador de Linux"
.SH NOMBRE
catopen, catclose \- abre/cierra un catlogo de mensajes
.SH SINOPSIS
.nf
.B #include <features.h>
.br
.B #include <nl_types.h>
.sp
.\" .LP
.\" .nf
.\" .ft B
.BI "nl_catd catopen(char *" name ", int " flag )
.\" char *name;
.\" int flag;
.\" .ft R
.\" .fi
.\" .LP
.\" .nf
.\" .ft B
.sp
.BI "void catclose(nl_catd " catalog )
.\" nl_catd catalog;
.\" .ft R
.fi
.SH DESCRIPCIN
.IX "catopen" "" "\fLcatopen\fR \(em abre un catlogo de mensajes" ""
.IX "catclose" "" "\fLcatclose\fR \(em cierra un catlogo de mensajes" ""
.LP
.B catopen(\|)
abre un catlogo de mensajes y devuelve un descriptor de catlogo.
.I name
espeficica el nombre del catlogo de mensajes a ser abierto.
Si
.I name
especifica un camino absoluto, (i.e. contiene una
.RB ` / ' )
entonces
.I name
especifica un nombre de camino para el catlogo de mensajes.
Si no, se usa la variable de ambiente
.SB NLSPATH
donde
.B %N
se sustituir por
.I name
(vea
.BR locale (5)).
Si
.SB NLSPATH
no existe en el ambiente, o si un catlogo de mensajes no se puede abrir
en ninguno de los caminos especificados por 
.BR \s-1NLSPATH\s0 ,
los siguiente caminos se buscan en orden

.RS
.B /etc/locale/LC_MESSAGES
.br
.B /usr/lib/locale/LC_MESSAGES
.br
.B /usr/lib/locale/name/LC_MESSAGES
.RE

En todos los casos
.I LC_MESSAGES
se refiere a la actual asignacin de la categora de localicacin
.B \s-1LC_MESSAGES\s+1
de una llamada previa a 
.BR setlocale ()
y toma como valor predeterminado "C". En el ltimo camino de bsqueda
.I name
se refiere al nombre del catlogo.
.LP
El argumento
.I flag
de \fBcatopen\fP se emplea para indicar el tipo de carga deseada. sta
debe ser bien 
.B MCLoadBySet
o bien
.BR MCLoadAll .
El primer valor indica que solamente el conjunto requerido desde el catlogo
se carga en la memoria al ser necesitado, mientras que el segundo hace que
en la llamada inicial a 
.BR catopen ()
se cargue el catlogo entero en la memoria.
.LP
.B catclose(\|)
cierra el catlogo de mensajes identificado por
.IR catalog .
Esto invalida cualquier referencia posterior al catlogo de mensajes 
definido por 
.IR catalog .
.LP
.SH VALOR DEVUELTO
.LP
.B catopen(\|)
devuelve un descritor de catlogo de mensajes de tipo
.I nl_catd
en caso de xito.
Si falla, devuelve
\-1
y pone un valor apropiado en
.B errno
para indicar el error.
.LP
.B catclose(\|)
devuelve 0 si es exitosa,  -1 si falla.
.SH NOTAS
Estas funciones estn slo disponibles en libc.so.4.4.4c o superior. 
En el caso de Linux, el descriptor de catlogo
.I nl_catd
es actualmente un rea mmap()'eada de memoria y no un descriptor de 
fichero; as se permite que los catlogos se puedan compartir.
.SH "VASE TAMBIN"
.BR catgets (3),
.BR setlocale (3)