GetOpnFl man page on DigitalUNIX

Man page or keyword search:  
man Server   12896 pages
apropos Keyword Search (all sections)
Output format
DigitalUNIX logo
[printable version]

Tcl_GetOpenFile(3)	    Tcl Library Procedures	    Tcl_GetOpenFile(3)

______________________________________________________________________________

NAME
       Tcl_GetOpenFile - Get a standard IO File * handle from a channel. (Unix
       only)

SYNOPSIS
       #include <tcl.h>

       int
       Tcl_GetOpenFile(interp, string, write, checkUsage, filePtr)

ARGUMENTS
       Tcl_Interp   *interp	 (in)	   Tcl	interpreter  from  which  file
					   handle is to be obtained.

       char	    *string	 (in)	   String identifying channel, such as
					   stdin or file4.

       int	    write	 (in)	   Non-zero means  the	file  will  be
					   used	 for  writing,	zero  means it
					   will be used for reading.

       int	    checkUsage	 (in)	   If non-zero, then an error will  be
					   generated if the file wasn't opened
					   for the access indicated by write.

       ClientData   *filePtr	 (out)	   Points to word in  which  to	 store
					   pointer  to	FILE structure for the
					   file given by string.
_________________________________________________________________

DESCRIPTION
       Tcl_GetOpenFile takes  as  argument  a  file  identifier	 of  the  form
       returned	 by  the open command and returns at *filePtr a pointer to the
       FILE structure for the file.  The write argument indicates whether  the
       FILE  pointer will be used for reading or writing.  In some cases, such
       as a channel that connects to a	pipeline  of  subprocesses,  different
       FILE  pointers  will be returned for reading and writing.  Tcl_GetOpen‐
       File normally returns TCL_OK.  If an error  occurs  in  Tcl_GetOpenFile
       (e.g.  string  didn't make any sense or checkUsage was set and the file
       wasn't opened for the access specified  by  write)  then	 TCL_ERROR  is
       returned and interp->result will contain an error message.  In the cur‐
       rent implementation checkUsage is ignored and  consistency  checks  are
       always performed.						       │

       Note that this interface is only supported on the Unix platform.

KEYWORDS
       channel, file handle, permissions, pipeline, read, write

Tcl				      8.0		    Tcl_GetOpenFile(3)
[top]

List of man pages available for DigitalUNIX

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net