mirror of
https://github.com/prebid/openrtb.git
synced 2026-06-14 14:06:38 +03:00
1efc868257
At least, it's more convenient to use with time std pkg. Also, API implementations better never rely on machine-dependent types.
43 lines
1.2 KiB
Go
43 lines
1.2 KiB
Go
package adcom1
|
|
|
|
import "encoding/json"
|
|
|
|
// DataAsset object identifies the native asset as a data asset.
|
|
// A data asset is used for all miscellaneous elements such as brand name, ratings, stars, review count, downloads, price, counts, etc.
|
|
// It is purposefully generic to support native elements not currently contemplated by this specification.
|
|
type DataAsset struct {
|
|
// Attribute:
|
|
// value
|
|
// Type:
|
|
// string; required
|
|
// Definition:
|
|
// A formatted string of data to be displayed (e.g., “5 stars”, “3.4 stars out of 5”, “$10”, etc.).
|
|
Value string `json:"value"`
|
|
|
|
// Attribute:
|
|
// len
|
|
// Type:
|
|
// integer
|
|
// Definition:
|
|
// The length of the value contents.
|
|
// This length should conform to recommendations provided in List: Native Data Asset Types
|
|
Len int64 `json:"len,omitempty"`
|
|
|
|
// Attribute:
|
|
// type
|
|
// Type:
|
|
// integer
|
|
// Definition:
|
|
// The type of data represented by this asset.
|
|
// Refer to List: Native Data Asset Types.
|
|
Type NativeDataAssetType `json:"type,omitempty"`
|
|
|
|
// Attribute:
|
|
// ext
|
|
// Type:
|
|
// object
|
|
// Definition:
|
|
// Optional vendor-specific extensions.
|
|
Ext json.RawMessage `json:"ext,omitempty"`
|
|
}
|