API Reference | developer.brewmp.com API Reference | developer.brewmp.com

Developer

API Reference

IPUBKEYUTIL_SERIALIZE()

Brew Release
Brew MP 1.0.2
See Also
IPubKeyUtil_Parse()
Description
Serializes the key material stored in piIn to key format specified by nType, stores the output in buffer pointed by pOut, and updates the size in pOutLen.
Params
pif
[]:
[in] interface pointer
nType
[]:
[in] encoding type to generate
piIn
[]:
[in] interface pointer of input
pOut
[]:
[out] pointer where encoded data is to be stored if operation is successful. Buffer is caller provided.
nOutBufSize
[]:
[in] The length of pOut
pnOutLen
[]:
[in/out] Pointer to the full length of the parameter data.
Interface
Prototype
  • int IPubKeyUtil_Serialize(IPubKeyUtil *pif, int nType, const IParameters1 *piIn,
                              uint8 *pOut, int nOutBufSize, int *pnOutLen)
    
Return
  • AEE_SUCCESS: Parse completed successfully
    AEE_EBADPARM: Invalid parameter
    AEE_EUNSUPPORTED: Api not supported in this version of implemenation
    -- other error codes as returned by implementation
Side Effect
  • None
Comments
See IPubKeyUtil_Parse() for possible values for parameter nType. The length of the data copied is always MIN(nOutBufSize, *pnOutLen) whether a full or partial copy is performed. The length copied is the smaller of the buffer size passed and the full length of serialized data.