Date: 2025-03-28T21:11:11+00:00

Actual source code: petscviewer.h

      1: !
      2: !  Used by petscsysmod.F90 to create Fortran module file
      3: !
      4: #include "petsc/finclude/petscviewer.h"

      6:       type, extends(tPetscObject) :: tPetscViewer
      7:       end type tPetscViewer
      8:       PetscViewer, parameter :: PETSC_NULL_VIEWER = tPetscViewer(0)
      9: #if defined(_WIN32) && defined(PETSC_USE_SHARED_LIBRARIES)
     10: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_NULL_VIEWER
     11: #endif
     12: !
     13: !     The numbers used below should match those in
     14: !     petsc/private/fortranimpl.h
     15: !
     16:       PetscViewer, parameter :: PETSC_VIEWER_STDOUT_SELF  = tPetscViewer(9)
     17:       PetscViewer, parameter :: PETSC_VIEWER_DRAW_WORLD   = tPetscViewer(4)
     18:       PetscViewer, parameter :: PETSC_VIEWER_DRAW_SELF    = tPetscViewer(5)
     19:       PetscViewer, parameter :: PETSC_VIEWER_SOCKET_WORLD = tPetscViewer(6)
     20:       PetscViewer, parameter :: PETSC_VIEWER_SOCKET_SELF  = tPetscViewer(7)
     21:       PetscViewer, parameter :: PETSC_VIEWER_STDOUT_WORLD = tPetscViewer(8)
     22:       PetscViewer, parameter :: PETSC_VIEWER_STDERR_WORLD = tPetscViewer(10)
     23:       PetscViewer, parameter :: PETSC_VIEWER_STDERR_SELF  = tPetscViewer(11)
     24:       PetscViewer, parameter :: PETSC_VIEWER_BINARY_WORLD = tPetscViewer(12)
     25:       PetscViewer, parameter :: PETSC_VIEWER_BINARY_SELF  = tPetscViewer(13)
     26:       PetscViewer, parameter :: PETSC_VIEWER_MATLAB_WORLD = tPetscViewer(14)
     27:       PetscViewer, parameter :: PETSC_VIEWER_MATLAB_SELF  = tPetscViewer(15)

     29:       PetscViewer PETSC_VIEWER_STDOUT_
     30:       PetscViewer PETSC_VIEWER_DRAW_
     31:       external PETSC_VIEWER_STDOUT_
     32:       external PETSC_VIEWER_DRAW_
     33:       external PetscViewerAndFormatDestroy
     34: !
     35: !  Flags for binary I/O
     36: !
     37:       PetscEnum, parameter :: FILE_MODE_READ = 0
     38:       PetscEnum, parameter :: FILE_MODE_WRITE = 1
     39:       PetscEnum, parameter :: FILE_MODE_APPEND = 2
     40:       PetscEnum, parameter :: FILE_MODE_UPDATE = 3
     41:       PetscEnum, parameter :: FILE_MODE_APPEND_UPDATE = 4
     42: !
     43: !  PetscViewer formats
     44: !
     45:       PetscEnum, parameter :: PETSC_VIEWER_DEFAULT = 0
     46:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_MATLAB = 1
     47:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_MATHEMATICA = 2
     48:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_IMPL = 3
     49:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_INFO = 4
     50:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_INFO_DETAIL = 5
     51:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_COMMON = 6
     52:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_SYMMODU = 7
     53:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_INDEX = 8
     54:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_DENSE = 9
     55:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_MATRIXMARKET = 10
     56:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_VTK = 11
     57:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_VTK_CELL = 12
     58:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_VTK_COORDS = 13
     59:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_PCICE = 14
     60:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_PYTHON = 15
     61:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_FACTOR_INFO = 16
     62:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_LATEX = 17
     63:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_XML = 18
     64:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_GLVIS = 19
     65:       PetscEnum, parameter :: PETSC_VIEWER_ASCII_CSV = 20
     66:       PetscEnum, parameter :: PETSC_VIEWER_DRAW_BASIC = 21
     67:       PetscEnum, parameter :: PETSC_VIEWER_DRAW_LG = 22
     68:       PetscEnum, parameter :: PETSC_VIEWER_DRAW_LG_XRANGE = 23
     69:       PetscEnum, parameter :: PETSC_VIEWER_DRAW_CONTOUR = 24
     70:       PetscEnum, parameter :: PETSC_VIEWER_DRAW_PORTS = 25
     71:       PetscEnum, parameter :: PETSC_VIEWER_VTK_VTS = 26
     72:       PetscEnum, parameter :: PETSC_VIEWER_VTK_VTR = 27
     73:       PetscEnum, parameter :: PETSC_VIEWER_VTK_VTU = 28
     74:       PetscEnum, parameter :: PETSC_VIEWER_BINARY_MATLAB = 29
     75:       PetscEnum, parameter :: PETSC_VIEWER_NATIVE = 30
     76:       PetscEnum, parameter :: PETSC_VIEWER_HDF5_PETSC = 31
     77:       PetscEnum, parameter :: PETSC_VIEWER_HDF5_VIZ = 32
     78:       PetscEnum, parameter :: PETSC_VIEWER_HDF5_XDMF = 33
     79:       PetscEnum, parameter :: PETSC_VIEWER_HDF5_MAT = 34
     80:       PetscEnum, parameter :: PETSC_VIEWER_NOFORMAT = 35
     81:       PetscEnum, parameter :: PETSC_VIEWER_LOAD_BALANCE = 36
     82:       PetscEnum, parameter :: PETSC_VIEWER_LOAD_ALL = 37

     84: #if defined(_WIN32) && defined(PETSC_USE_SHARED_LIBRARIES)
     85: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_STDOUT_SELF
     86: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_DRAW_WORLD
     87: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_DRAW_SELF
     88: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_SOCKET_WORLD
     89: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_SOCKET_SELF
     90: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_STDOUT_WORLD
     91: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_STDERR_WORLD
     92: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_STDERR_SELF
     93: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_BINARY_WORLD
     94: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_BINARY_SELF
     95: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_MATLAB_WORLD
     96: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_MATLAB_SELF
     97: !DEC$ ATTRIBUTES DLLEXPORT::FILE_MODE_READ
     98: !DEC$ ATTRIBUTES DLLEXPORT::FILE_MODE_WRITE
     99: !DEC$ ATTRIBUTES DLLEXPORT::FILE_MODE_APPEND
    100: !DEC$ ATTRIBUTES DLLEXPORT::FILE_MODE_UPDATE
    101: !DEC$ ATTRIBUTES DLLEXPORT::FILE_MODE_APPEND_UPDATE
    102: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_DEFAULT
    103: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_MATLAB
    104: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_MATHEMATICA
    105: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_IMPL
    106: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_INFO
    107: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_INFO_DETAIL
    108: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_COMMON
    109: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_SYMMODU
    110: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_INDEX
    111: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_DENSE
    112: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_MATRIXMARKET
    113: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_VTK
    114: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_VTK_CELL
    115: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_VTK_COORDS
    116: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_PCICE
    117: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_PYTHON
    118: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_FACTOR_INFO
    119: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_LATEX
    120: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_XML
    121: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ASCII_GLVIS
    122: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_DRAW_BASIC
    123: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_DRAW_LG
    124: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_DRAW_CONTOUR
    125: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_DRAW_PORTS
    126: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_VTK_VTS
    127: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_VTK_VTR
    128: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_VTK_VTU
    129: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_BINARY_MATLAB
    130: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_NATIVE
    131: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_HDF5_VIZ
    132: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_NOFORMAT
    133: !DEC$ ATTRIBUTES DLLEXPORT::PETSC_VIEWER_ALL
    134: #endif