.\"##
.\" $XConsortium: p004,v 5.3 94/04/17 20:54:14 hersh Exp $
.\"##
.\"## 
$XMCOPY
.\"## Copyright (c) 1990, 1991 by Sun Microsystems, Inc. 
.\"## 
.\"##                         All Rights Reserved
.\"## 
.\"## Permission to use, copy, modify, and distribute this software and its 
.\"## documentation for any purpose and without fee is hereby granted, 
.\"## provided that the above copyright notice appear in all copies and that
.\"## both that copyright notice and this permission notice appear in 
.\"## supporting documentation, and that the name of Sun Microsystems,
.\"## not be used in advertising or publicity 
.\"## pertaining to distribution of the software without specific, written 
.\"## prior permission.  
.\"## 
.\"## SUN MICROSYSTEMS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, 
.\"## INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
.\"## EVENT SHALL SUN MICROSYSTEMS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
.\"## CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
.\"## USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
.\"## OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
.\"## PERFORMANCE OF THIS SOFTWARE.
.TH "APPLICATION DATA" 3P "16 August 1991"
.SH NAME
APPLICATION DATA \- create a structure element containing application data
.IX "Elements" "APPLICATION DATA"
.SH SYNOPSIS
.SS C Syntax
.ft B
.ta 1.25i 3i
.nf
void
pappl_data ( data )
Pdata	*data;	\fIapplication data\fP
.fi
.ft R
.SS Required PHIGS Operating States
(PHOP, *, STOP, *)
.SH DESCRIPTION
.SS Purpose
The 
\s-2APPLICATION DATA\s+2 
subroutine puts a structure element containing
application data into the currently open structure.
.LP
If the current edit mode is \s-2INSERT\s+2, the 
\s-2APPLICATION DATA\s+2
element is inserted into the currently open structure after the element
currently pointed to by the element pointer. If the edit mode is
\s-2REPLACE\s+2, the 
\s-2APPLICATION DATA\s+2
element replaces the element pointed
to. In either case, the element pointer is updated to point to the new
\s-2APPLICATION DATA\s+2
element.
.SS C Input Parameter
.IP \fIdata \fP
A pointer to a Pdata structure containing the application data.
Pdata is defined in phigs.h as follows:
.sp .4
.ta .5i +\w'void     'u +\w'*data;     'u
.nf
typedef struct {
.sp .2
	size_t	size;	/* size of data */
	void	*data;	/* pointer to data */
.sp .2
} Pdata;
.fi
.sp
The size component specifies the number of bytes the data 
component is pointing to.
.SS Execution
The 
\s-2APPLICATION DATA\s+2
element is ignored during structure traversal.
.SH ERRORS
.IP 005
Ignoring function, function requires state (\s-2PHOP\s+2, *, \s-2STOP\s+2, *)
.SH SEE ALSO
.nf
.IP
.ta 0.5i
.SM "INQUIRE CURRENT ELEMENT TYPE AND SIZE (3P)"
.SM "INQUIRE CURRENT ELEMENT CONTENT (3P)"
.SM "INQUIRE ELEMENT TYPE AND SIZE (3P)"
.SM "INQUIRE ELEMENT CONTENT (3P)"
.fi
