nightly: remove unused BINARCHIVE
[unleashed.git] / share / man / man3picl / picl_get_propval.3picl
blob1b8d63d1bfa41bdcd5254c523b53a876f7c35187
1 '\" te
2 .\" Copyright (c) 2000, Sun Microsystems, Inc. All Rights Reserved.
3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License").  You may not use this file except in compliance with the License.
4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing.  See the License for the specific language governing permissions and limitations under the License.
5 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE.  If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
6 .TH PICL_GET_PROPVAL 3PICL "Mar 28, 2000"
7 .SH NAME
8 picl_get_propval, picl_get_propval_by_name \- get the value of a property
9 .SH SYNOPSIS
10 .LP
11 .nf
12 \fBcc\fR [ \fIflag\fR... ] \fIfile\fR... \fB-lpicl\fR [ \fIlibrary\fR... ]
13 #include <picl.h>
15 \fBint\fR \fBpicl_get_propval\fR(\fBpicl_prophdl_t\fR \fIproph\fR, \fBvoid *\fR\fIvalbuf\fR,
16      \fBsize_t\fR \fInbytes\fR);
17 .fi
19 .LP
20 .nf
21 \fBint\fR \fBpicl_get_propval_by_name\fR(\fBpicl_nodehdl_t\fR \fInodeh\fR,
22      \fBchar *\fR\fIpropname\fR, \fBvoid *\fR\fIvalbuf\fR, \fBsize_t\fR \fInbytes\fR);
23 .fi
25 .SH DESCRIPTION
26 .sp
27 .LP
28 The \fBpicl_get_propval()\fR function copies the value of the property
29 specified by the handle \fIproph\fR into the buffer location given by
30 \fIvalbuf\fR. The size of the buffer \fIvalbuf\fR in bytes is specified in
31 \fInbytes\fR.
32 .sp
33 .LP
34 The \fBpicl_get_propval_by_name()\fR function gets the value of property named
35 \fIpropname\fR of the node specified by handle \fInodeh\fR. The value is copied
36 into the buffer location given by \fIvalbuf\fR. The size of the buffer
37 \fIvalbuf\fR in bytes is specified in \fInbytes\fR.
38 .sp
39 .LP
40 The \fBpicl_get_propval_by_name()\fR function is used to get a reserved
41 property's value. An example of a reserved property is "\fB_parent\fR".  Please
42 refer to \fBlibpicl\fR(3PICL) for a complete list of reserved property names.
43 .SH RETURN VALUES
44 .sp
45 .LP
46 Upon successful completion, \fB0\fR is returned. On failure, a non-negative
47 integer is returned to indicate an error.
48 .sp
49 .LP
50 \fBPICL_PROPNOTFOUND\fR is returned if the property of the specified name does
51 not exist.
52 .sp
53 .LP
54 \fBPICL_PERMDENIED\fR is returned if the client does not have sufficient
55 permission to access the property.
56 .sp
57 .LP
58 \fBPICL_STALEHANDLE\fR is returned if the handle is no longer valid. This
59 occurs if the PICL tree was refreshed or reinitialized.
60 .sp
61 .LP
62 \fBPICL_INVALIDHANDLE\fR is returned if the specified handle never existed.
63 This error may be returned for a previously valid handle if the daemon was
64 brought down and restarted. When this occurs a client must revalidate any saved
65 handles.
66 .SH ERRORS
67 .sp
68 .ne 2
69 .na
70 \fB\fBPICL_NOTINITIALIZED\fR\fR
71 .ad
72 .RS 23n
73 Session not initialized
74 .RE
76 .sp
77 .ne 2
78 .na
79 \fB\fBPICL_NORESPONSE\fR\fR
80 .ad
81 .RS 23n
82 Daemon not responding
83 .RE
85 .sp
86 .ne 2
87 .na
88 \fB\fBPICL_PERMDENIED\fR\fR
89 .ad
90 .RS 23n
91 Insufficient permission
92 .RE
94 .sp
95 .ne 2
96 .na
97 \fB\fBPICL_VALUETOOBIG\fR\fR
98 .ad
99 .RS 23n
100 Value too big for buffer
104 .ne 2
106 \fB\fBPICL_NOTPROP\fR\fR
108 .RS 23n
109 Not a property
113 .ne 2
115 \fB\fBPICL_PROPNOTFOUND\fR\fR
117 .RS 23n
118 Property node found
122 .ne 2
124 \fB\fBPICL_NOTNODE\fR\fR
126 .RS 23n
127 Not a node
131 .ne 2
133 \fB\fBPICL_INVALIDHANDLE\fR\fR
135 .RS 23n
136 Invalid handle specified
140 .ne 2
142 \fB\fBPICL_STALEHANDLE\fR\fR
144 .RS 23n
145 Stale handle specified
149 .ne 2
151 \fB\fBPICL_FAILURE\fR\fR
153 .RS 23n
154 General system failure
157 .SH ATTRIBUTES
160 See \fBattributes\fR(5) for descriptions of the following attributes:
165 box;
166 c | c
167 l | l .
168 ATTRIBUTE TYPE  ATTRIBUTE VALUE
170 MT-Level        MT-Safe
173 .SH SEE ALSO
176 \fBlibpicl\fR(3PICL), \fBpicl_get_propinfo\fR(3PICL), \fBattributes\fR(5)