Skip to main content
`Ctrl`+`K`

# PetscContainerGetPointer

Gets the pointer value contained in the container that was provided with `PetscContainerSetPointer()`

## Synopsis

    #include "petscsys.h"
    PetscErrorCode PetscContainerGetPointer(PetscContainer obj, PeCtx ptr)

Not Collective, No Fortran Support

## Input Parameter

- obj - the object created with `PetscContainerCreate()`

## Output Parameter

- ptr - the pointer value

## See Also

`PetscContainerCreate()`, `PetscContainerDestroy()`, `PetscObject`, `PetscContainerSetPointer()`, `PetscObjectContainerCompose()`, `PetscObjectContainerQuery()`

## Level

advanced

## Location

src/sys/objects/inherit.c

## Examples

src/dm/impls/plex/tutorials/ex19.c
src/snes/tutorials/ex7.c
src/dm/impls/plex/tutorials/ex18.c

Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages