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

PetscTokenFind

Locates next "token" in a string

Synopsis

#include "petscsys.h"   
PetscErrorCode  PetscTokenFind(PetscToken a,char *result[])
Not Collective Many br

Input Parameters

a -pointer to token Many br

Output Parameter

result -location of occurance, NULL if not found Many br

Notes

This version is different from the system version in that Many brit allows you to pass a read-only string into the function. Many br

This version also treats all characters etc. inside a double quote " Many bras a single token. Many br

For example if the separator character is + and the string is xxxx+y then the first fine will return a pointer to a null terminated xxxx and the Many brsecond will return a null terminated y Many br

If the separator character is + and the string is xxxx then the first and only token found will be a pointer to a null terminated xxxx Many br

Not for use in Fortran Many br

Many br

See Also

PetscTokenCreate(), PetscTokenDestroy()

Level:intermediate
Location:
src/sys/utils/str.c
Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages