Data Fields

Detailed Description

The PP_VAR struct is a variant data type and can contain any value of one of the types named in the PP_VarType enum.

This structure is for passing data between native code which can be strongly typed and the browser (JavaScript) which isn't strongly typed.

JavaScript has a "number" type for holding a number, and does not differentiate between floating point and integer numbers. The JavaScript operations will try to optimize operations by using integers when possible, but could end up with doubles. Therefore, you can't assume a numeric PP_Var will be the type you expect. Your code should be capable of handling either int32_t or double for numeric PP_Vars sent from JavaScript.

Field Documentation

The padding ensures value is aligned on an 8-byte boundary relative to the start of the struct.

Some compilers align doubles on 8-byte boundaries for 32-bit x86, and some align on 4-byte boundaries.

This value represents the contents of the PP_Var.

Only one of the fields of value is valid at a time based upon type.

The documentation for this struct was generated from the following file:
We serve cookies on this site to analyze traffic, remember your preferences, and optimize your experience.