Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MarshalContainerNamesForField ¶
func MarshalContainerNamesForField( modelType reflect.Type, indexPath []int, resolve func(reflect.StructField) (string, bool), flatten bool, ) ([]string, bool)
MarshalContainerNamesForField resolves legacy anonymous-container names for a promoted field. Every ancestor container is examined for an exclusion tag even when flat encoding is enabled: flat encoding writes the promoted field directly into the root map, so a skipped container must suppress the field rather than merely omitting the nested container names.
func RequestsFlatEncoding ¶
RequestsFlatEncoding returns true when the supplied value opts into flat anonymous-embed encoding.
func SetMarshaledAttributeValue ¶
func SetMarshaledAttributeValue( root map[string]types.AttributeValue, containerNames []string, fieldName string, av types.AttributeValue, flatten bool, ) error
SetMarshaledAttributeValue writes a field AttributeValue either directly into the root map for flat encoding or into the nested legacy anonymous-container path for compatibility encoding.
Types ¶
type FlatEncodingLookup ¶
type FlatEncodingLookup interface {
FlatAnonymousEmbedEncodingEnabled() bool
}
FlatEncodingLookup reports whether a converter or option carrier requests flat promoted-field encoding for exported anonymous embedded structs.