<!-- $XConsortium: user.sgm /main/5 1996/08/30 13:46:07 rws $ -->
<!-- (c) Copyright 1995 Digital Equipment Corporation. -->
<!-- (c) Copyright 1995 Hewlett-Packard Company. -->
<!-- (c) Copyright 1995 International Business Machines Corp. -->
<!-- (c) Copyright 1995 Sun Microsystems, Inc. -->
<!-- (c) Copyright 1995 Novell, Inc. -->
<!-- (c) Copyright 1995 FUJITSU LIMITED. -->
<!-- (c) Copyright 1995 Hitachi. -->

<![ %CDE.C.CDE; [<RefEntry Id="CDEMX.XCDI.MAN157.rsml.1">]]>
<![ %CDE.C.XO; [<RefEntry Id="XCDI.MAN157.rsml.1">]]>
<RefMeta>
<RefEntryTitle>tt_message_user</RefEntryTitle>
<ManVolNum>library call</ManVolNum>
</RefMeta>
<RefNameDiv>
<RefName><Function>tt_message_user</Function></RefName>
<RefPurpose>retrieve the user information associated with a message object
</RefPurpose>
</RefNameDiv>
<!-- $XConsortium: user.sgm /main/5 1996/08/30 13:46:07 rws $-->
<!-- CDE Common Source Format, Version 1.0.0-->
<!-- (c) Copyright 1993, 1994, 1995 Hewlett-Packard Company-->
<!-- (c) Copyright 1993, 1994, 1995 International Business Machines Corp.-->
<!-- (c) Copyright 1993, 1994, 1995 Sun Microsystems, Inc.-->
<!-- (c) Copyright 1993, 1994, 1995 Novell, Inc.-->
<RefSynopsisDiv>
<FuncSynopsis Remap="ANSI">
<FuncSynopsisInfo>#include &lt;Tt/tt_c.h>
</FuncSynopsisInfo>
<FuncDef>void <Function>*tt_message_user</Function></FuncDef>
<ParamDef>Tt_message <Parameter>m</Parameter></ParamDef>
<ParamDef>int <Parameter>key</Parameter></ParamDef>
</FuncSynopsis>
</RefSynopsisDiv>
<RefSect1>
<Title>DESCRIPTION</Title>
<Para>The
<Function>tt_message_user</Function> function
retrieves the user information stored in data cells associated with the
specified message object.
</Para>
<Para>The user data is part of the message object
(that is, the storage buffer in the
application); it is not a part of the actual message.
The application can, therefore, only
retrieve user information that the application placed in the message.
</Para>
<Para>The
<Emphasis>m</Emphasis> argument is the opaque handle for the message involved in this operation.
The
<Symbol Role="Variable">key</Symbol> argument is the user data cell to be retrieved.
The user data cell must be unique for this message.
</Para>
</RefSect1>
<RefSect1>
<Title>RETURN VALUE</Title>
<Para>Upon successful completion, the
<Function>tt_message_user</Function> function returns the data cell,
a piece of arbitrary user data that can hold a
<Literal>void *</Literal>. The application can use
&cdeman.tt.ptr.error; to extract one of the following
<StructName Role="typedef">Tt_status</StructName> values from the returned data:
</Para>
<VariableList>
<VarListEntry>
<Term>TT_OK</Term>
<ListItem>
<Para>The operation completed successfully.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term>TT_ERR_NOMP</Term>
<ListItem>
<Para>The
&cdeman.ttsession; process is not running and the ToolTalk service cannot restart it.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term>TT_ERR_POINTER</Term>
<ListItem>
<Para>The pointer passed does not point to an object of
the correct type for this operation.
</Para>
</ListItem>
</VarListEntry>
</VariableList>
</RefSect1>
<RefSect1>
<Title>APPLICATION USAGE</Title>
<Para>The application should use
&cdeman.tt.free; to free any data stored in the address returned by the
ToolTalk API.
</Para>
<Para>The user data cell is intended to hold an address.
If the address selected is equal to one of the
<StructName Role="typedef">Tt_status</StructName> enumerated values, the result of the
&cdeman.tt.ptr.error; function will not be reliable.
</Para>
</RefSect1>
<RefSect1>
<Title>SEE ALSO</Title>
<Para>&cdeman.Tt.tt.c.h;, &cdeman.tt.ptr.error;, &cdeman.tt.free;.</Para>
</RefSect1>
</RefEntry>
<!--fickle 1.12 mancsf-to-docbook 1.2 08/07/95 23:18:47-->
