JasPer: Tag-Value Pair (TVP) Parsing

JasPer 3.0.6 |

Classes | Functions
Tag-Value Pair (TVP) Parsing

Tag-Value Pair (TVP) Parsing. More...

## Classes
struct | jas_taginfo_t
| Tag information type. More...
struct | jas_tvparser_t
| Tag-value parser type. More...

## Functions
JAS_ATTRIBUTE_PURE JAS_EXPORT const jas_taginfo_t * | jas_taginfos_lookup (const jas_taginfo_t *taginfos, const char *name)
| Lookup a tag by name. More...
JAS_ATTRIBUTE_PURE JAS_EXPORT const jas_taginfo_t * | jas_taginfo_nonull (const jas_taginfo_t *taginfo)
| Ensure a nonnull taginfo pointer. More...
JAS_EXPORT jas_tvparser_t * | jas_tvparser_create (const char *s)
| Create a tag-value parser for the specified string. More...
JAS_EXPORT void | jas_tvparser_destroy (jas_tvparser_t *tvparser)
| Destroy a tag-value parser. More...
JAS_EXPORT int | jas_tvparser_next (jas_tvparser_t *tvparser)
| Get the next tag-value pair. More...
JAS_ATTRIBUTE_PURE JAS_EXPORT const char * | jas_tvparser_gettag (const jas_tvparser_t *tvparser)
| Get the tag name for the current tag-value pair. More...
JAS_ATTRIBUTE_PURE JAS_EXPORT const char * | jas_tvparser_getval (const jas_tvparser_t *tvparser)
| Get the value for the current tag-value pair. More...

## Detailed Description

Tag-Value Pair (TVP) Parsing.

General information can be found here.

## Function Documentation

## ◆ jas_taginfo_nonull()

JAS_ATTRIBUTE_PURE JAS_EXPORT const jas_taginfo_t * jas_taginfo_nonull | ( | const jas_taginfo_t * | taginfo | ) |

Ensure a nonnull taginfo pointer.

This function returns a pointer to the specified taginfo object if it exists (i.e., the pointer is nonnull); otherwise, a pointer to a dummy object is returned. This is useful in some situations to avoid checking for a null pointer.

## ◆ jas_taginfos_lookup()

JAS_ATTRIBUTE_PURE JAS_EXPORT const jas_taginfo_t * jas_taginfos_lookup | ( | const jas_taginfo_t * | taginfos,
|  | const char * | name
| ) |  |

Lookup a tag by name.

## ◆ jas_tvparser_create()

JAS_EXPORT jas_tvparser_t * jas_tvparser_create | ( | const char * | s | ) |

Create a tag-value parser for the specified string.

## ◆ jas_tvparser_destroy()

JAS_EXPORT void jas_tvparser_destroy | ( | jas_tvparser_t * | tvparser | ) |

Destroy a tag-value parser.

## ◆ jas_tvparser_gettag()

JAS_ATTRIBUTE_PURE JAS_EXPORT const char * jas_tvparser_gettag | ( | const jas_tvparser_t * | tvparser | ) |

Get the tag name for the current tag-value pair.

## ◆ jas_tvparser_getval()

JAS_ATTRIBUTE_PURE JAS_EXPORT const char * jas_tvparser_getval | ( | const jas_tvparser_t * | tvparser | ) |

Get the value for the current tag-value pair.

## ◆ jas_tvparser_next()

JAS_EXPORT int jas_tvparser_next | ( | jas_tvparser_t * | tvparser | ) |

Get the next tag-value pair.