petsc-3.7.1 2016-05-15
Report Typos and Errors

# PetscViewerBinaryGetDescriptor

Extracts the file descriptor from a PetscViewer.

### Synopsis

    #include "petscviewer.h"
    PetscErrorCode PetscViewerBinaryGetDescriptor(PetscViewer viewer,int *fdes)

Collective On PetscViewer Many br

### Input Parameter

viewer -PetscViewer context, obtained from PetscViewerBinaryOpen() Many br

### Output Parameter

fdes -file descriptor Many br

Many br

### Notes

For writable binary PetscViewers, the descriptor will only be valid for the Many brfirst processor in the communicator that shares the PetscViewer. For readable Many brfiles it will only be valid on nodes that have the file. If node 0 does not Many brhave the file it generates an error even if another node does have the file. Many br

### Fortran Note

This routine is not supported in Fortran. Many br

Developer Notes: This must be called on all processes because Dave May changed Many brthe source code that this may be trigger a PetscViewerSetUp() call if it was not previously triggered. Many br

### See Also

PetscViewerBinaryOpen(),PetscViewerBinaryGetInfoPointer()

Level:advanced
Location:src/sys/classes/viewer/impls/binary/binv.c
Index of all Viewer routines
Table of Contents for all manual pages
Index of all manual pages

### Examples

src/vec/vec/examples/tutorials/ex6.c.html
src/mat/examples/tutorials/ex5.c.html