// Code generated by gotdgen, DO NOT EDIT.

package tg

import (
	
	
	
	
	

	

	
	
	
	
)

// No-op definition for keeping imports.
var (
	_ = bin.Buffer{}
	_ = context.Background()
	_ = fmt.Stringer(nil)
	_ = strings.Builder{}
	_ = errors.Is
	_ = multierr.AppendInto
	_ = sort.Ints
	_ = tdp.Format
	_ = tgerr.Error{}
	_ = tdjson.Encoder{}
)

// SecureValueTypePersonalDetails represents TL type `secureValueTypePersonalDetails#9d2a81e3`.
// Personal details
//
// See https://core.telegram.org/constructor/secureValueTypePersonalDetails for reference.
type SecureValueTypePersonalDetails struct {
}

// SecureValueTypePersonalDetailsTypeID is TL type id of SecureValueTypePersonalDetails.
const SecureValueTypePersonalDetailsTypeID = 0x9d2a81e3

// construct implements constructor of SecureValueTypeClass.
func ( SecureValueTypePersonalDetails) () SecureValueTypeClass { return & }

// Ensuring interfaces in compile-time for SecureValueTypePersonalDetails.
var (
	_ bin.Encoder     = &SecureValueTypePersonalDetails{}
	_ bin.Decoder     = &SecureValueTypePersonalDetails{}
	_ bin.BareEncoder = &SecureValueTypePersonalDetails{}
	_ bin.BareDecoder = &SecureValueTypePersonalDetails{}

	_ SecureValueTypeClass = &SecureValueTypePersonalDetails{}
)

func ( *SecureValueTypePersonalDetails) () bool {
	if  == nil {
		return true
	}

	return true
}

// String implements fmt.Stringer.
func ( *SecureValueTypePersonalDetails) () string {
	if  == nil {
		return "SecureValueTypePersonalDetails(nil)"
	}
	type  SecureValueTypePersonalDetails
	return fmt.Sprintf("SecureValueTypePersonalDetails%+v", (*))
}

// TypeID returns type id in TL schema.
//
// See https://core.telegram.org/mtproto/TL-tl#remarks.
func (*SecureValueTypePersonalDetails) () uint32 {
	return SecureValueTypePersonalDetailsTypeID
}

// TypeName returns name of type in TL schema.
func (*SecureValueTypePersonalDetails) () string {
	return "secureValueTypePersonalDetails"
}

// TypeInfo returns info about TL type.
func ( *SecureValueTypePersonalDetails) () tdp.Type {
	 := tdp.Type{
		Name: "secureValueTypePersonalDetails",
		ID:   SecureValueTypePersonalDetailsTypeID,
	}
	if  == nil {
		.Null = true
		return 
	}
	.Fields = []tdp.Field{}
	return 
}

// Encode implements bin.Encoder.
func ( *SecureValueTypePersonalDetails) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypePersonalDetails#9d2a81e3 as nil")
	}
	.PutID(SecureValueTypePersonalDetailsTypeID)
	return .EncodeBare()
}

// EncodeBare implements bin.BareEncoder.
func ( *SecureValueTypePersonalDetails) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypePersonalDetails#9d2a81e3 as nil")
	}
	return nil
}

// Decode implements bin.Decoder.
func ( *SecureValueTypePersonalDetails) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypePersonalDetails#9d2a81e3 to nil")
	}
	if  := .ConsumeID(SecureValueTypePersonalDetailsTypeID);  != nil {
		return fmt.Errorf("unable to decode secureValueTypePersonalDetails#9d2a81e3: %w", )
	}
	return .DecodeBare()
}

// DecodeBare implements bin.BareDecoder.
func ( *SecureValueTypePersonalDetails) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypePersonalDetails#9d2a81e3 to nil")
	}
	return nil
}

// SecureValueTypePassport represents TL type `secureValueTypePassport#3dac6a00`.
// Passport
//
// See https://core.telegram.org/constructor/secureValueTypePassport for reference.
type SecureValueTypePassport struct {
}

// SecureValueTypePassportTypeID is TL type id of SecureValueTypePassport.
const SecureValueTypePassportTypeID = 0x3dac6a00

// construct implements constructor of SecureValueTypeClass.
func ( SecureValueTypePassport) () SecureValueTypeClass { return & }

// Ensuring interfaces in compile-time for SecureValueTypePassport.
var (
	_ bin.Encoder     = &SecureValueTypePassport{}
	_ bin.Decoder     = &SecureValueTypePassport{}
	_ bin.BareEncoder = &SecureValueTypePassport{}
	_ bin.BareDecoder = &SecureValueTypePassport{}

	_ SecureValueTypeClass = &SecureValueTypePassport{}
)

func ( *SecureValueTypePassport) () bool {
	if  == nil {
		return true
	}

	return true
}

// String implements fmt.Stringer.
func ( *SecureValueTypePassport) () string {
	if  == nil {
		return "SecureValueTypePassport(nil)"
	}
	type  SecureValueTypePassport
	return fmt.Sprintf("SecureValueTypePassport%+v", (*))
}

// TypeID returns type id in TL schema.
//
// See https://core.telegram.org/mtproto/TL-tl#remarks.
func (*SecureValueTypePassport) () uint32 {
	return SecureValueTypePassportTypeID
}

// TypeName returns name of type in TL schema.
func (*SecureValueTypePassport) () string {
	return "secureValueTypePassport"
}

// TypeInfo returns info about TL type.
func ( *SecureValueTypePassport) () tdp.Type {
	 := tdp.Type{
		Name: "secureValueTypePassport",
		ID:   SecureValueTypePassportTypeID,
	}
	if  == nil {
		.Null = true
		return 
	}
	.Fields = []tdp.Field{}
	return 
}

// Encode implements bin.Encoder.
func ( *SecureValueTypePassport) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypePassport#3dac6a00 as nil")
	}
	.PutID(SecureValueTypePassportTypeID)
	return .EncodeBare()
}

// EncodeBare implements bin.BareEncoder.
func ( *SecureValueTypePassport) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypePassport#3dac6a00 as nil")
	}
	return nil
}

// Decode implements bin.Decoder.
func ( *SecureValueTypePassport) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypePassport#3dac6a00 to nil")
	}
	if  := .ConsumeID(SecureValueTypePassportTypeID);  != nil {
		return fmt.Errorf("unable to decode secureValueTypePassport#3dac6a00: %w", )
	}
	return .DecodeBare()
}

// DecodeBare implements bin.BareDecoder.
func ( *SecureValueTypePassport) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypePassport#3dac6a00 to nil")
	}
	return nil
}

// SecureValueTypeDriverLicense represents TL type `secureValueTypeDriverLicense#6e425c4`.
// Driver's license
//
// See https://core.telegram.org/constructor/secureValueTypeDriverLicense for reference.
type SecureValueTypeDriverLicense struct {
}

// SecureValueTypeDriverLicenseTypeID is TL type id of SecureValueTypeDriverLicense.
const SecureValueTypeDriverLicenseTypeID = 0x6e425c4

// construct implements constructor of SecureValueTypeClass.
func ( SecureValueTypeDriverLicense) () SecureValueTypeClass { return & }

// Ensuring interfaces in compile-time for SecureValueTypeDriverLicense.
var (
	_ bin.Encoder     = &SecureValueTypeDriverLicense{}
	_ bin.Decoder     = &SecureValueTypeDriverLicense{}
	_ bin.BareEncoder = &SecureValueTypeDriverLicense{}
	_ bin.BareDecoder = &SecureValueTypeDriverLicense{}

	_ SecureValueTypeClass = &SecureValueTypeDriverLicense{}
)

func ( *SecureValueTypeDriverLicense) () bool {
	if  == nil {
		return true
	}

	return true
}

// String implements fmt.Stringer.
func ( *SecureValueTypeDriverLicense) () string {
	if  == nil {
		return "SecureValueTypeDriverLicense(nil)"
	}
	type  SecureValueTypeDriverLicense
	return fmt.Sprintf("SecureValueTypeDriverLicense%+v", (*))
}

// TypeID returns type id in TL schema.
//
// See https://core.telegram.org/mtproto/TL-tl#remarks.
func (*SecureValueTypeDriverLicense) () uint32 {
	return SecureValueTypeDriverLicenseTypeID
}

// TypeName returns name of type in TL schema.
func (*SecureValueTypeDriverLicense) () string {
	return "secureValueTypeDriverLicense"
}

// TypeInfo returns info about TL type.
func ( *SecureValueTypeDriverLicense) () tdp.Type {
	 := tdp.Type{
		Name: "secureValueTypeDriverLicense",
		ID:   SecureValueTypeDriverLicenseTypeID,
	}
	if  == nil {
		.Null = true
		return 
	}
	.Fields = []tdp.Field{}
	return 
}

// Encode implements bin.Encoder.
func ( *SecureValueTypeDriverLicense) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeDriverLicense#6e425c4 as nil")
	}
	.PutID(SecureValueTypeDriverLicenseTypeID)
	return .EncodeBare()
}

// EncodeBare implements bin.BareEncoder.
func ( *SecureValueTypeDriverLicense) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeDriverLicense#6e425c4 as nil")
	}
	return nil
}

// Decode implements bin.Decoder.
func ( *SecureValueTypeDriverLicense) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeDriverLicense#6e425c4 to nil")
	}
	if  := .ConsumeID(SecureValueTypeDriverLicenseTypeID);  != nil {
		return fmt.Errorf("unable to decode secureValueTypeDriverLicense#6e425c4: %w", )
	}
	return .DecodeBare()
}

// DecodeBare implements bin.BareDecoder.
func ( *SecureValueTypeDriverLicense) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeDriverLicense#6e425c4 to nil")
	}
	return nil
}

// SecureValueTypeIdentityCard represents TL type `secureValueTypeIdentityCard#a0d0744b`.
// Identity card
//
// See https://core.telegram.org/constructor/secureValueTypeIdentityCard for reference.
type SecureValueTypeIdentityCard struct {
}

// SecureValueTypeIdentityCardTypeID is TL type id of SecureValueTypeIdentityCard.
const SecureValueTypeIdentityCardTypeID = 0xa0d0744b

// construct implements constructor of SecureValueTypeClass.
func ( SecureValueTypeIdentityCard) () SecureValueTypeClass { return & }

// Ensuring interfaces in compile-time for SecureValueTypeIdentityCard.
var (
	_ bin.Encoder     = &SecureValueTypeIdentityCard{}
	_ bin.Decoder     = &SecureValueTypeIdentityCard{}
	_ bin.BareEncoder = &SecureValueTypeIdentityCard{}
	_ bin.BareDecoder = &SecureValueTypeIdentityCard{}

	_ SecureValueTypeClass = &SecureValueTypeIdentityCard{}
)

func ( *SecureValueTypeIdentityCard) () bool {
	if  == nil {
		return true
	}

	return true
}

// String implements fmt.Stringer.
func ( *SecureValueTypeIdentityCard) () string {
	if  == nil {
		return "SecureValueTypeIdentityCard(nil)"
	}
	type  SecureValueTypeIdentityCard
	return fmt.Sprintf("SecureValueTypeIdentityCard%+v", (*))
}

// TypeID returns type id in TL schema.
//
// See https://core.telegram.org/mtproto/TL-tl#remarks.
func (*SecureValueTypeIdentityCard) () uint32 {
	return SecureValueTypeIdentityCardTypeID
}

// TypeName returns name of type in TL schema.
func (*SecureValueTypeIdentityCard) () string {
	return "secureValueTypeIdentityCard"
}

// TypeInfo returns info about TL type.
func ( *SecureValueTypeIdentityCard) () tdp.Type {
	 := tdp.Type{
		Name: "secureValueTypeIdentityCard",
		ID:   SecureValueTypeIdentityCardTypeID,
	}
	if  == nil {
		.Null = true
		return 
	}
	.Fields = []tdp.Field{}
	return 
}

// Encode implements bin.Encoder.
func ( *SecureValueTypeIdentityCard) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeIdentityCard#a0d0744b as nil")
	}
	.PutID(SecureValueTypeIdentityCardTypeID)
	return .EncodeBare()
}

// EncodeBare implements bin.BareEncoder.
func ( *SecureValueTypeIdentityCard) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeIdentityCard#a0d0744b as nil")
	}
	return nil
}

// Decode implements bin.Decoder.
func ( *SecureValueTypeIdentityCard) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeIdentityCard#a0d0744b to nil")
	}
	if  := .ConsumeID(SecureValueTypeIdentityCardTypeID);  != nil {
		return fmt.Errorf("unable to decode secureValueTypeIdentityCard#a0d0744b: %w", )
	}
	return .DecodeBare()
}

// DecodeBare implements bin.BareDecoder.
func ( *SecureValueTypeIdentityCard) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeIdentityCard#a0d0744b to nil")
	}
	return nil
}

// SecureValueTypeInternalPassport represents TL type `secureValueTypeInternalPassport#99a48f23`.
// Internal passport¹
//
// Links:
//  1. https://core.telegram.org/passport
//
// See https://core.telegram.org/constructor/secureValueTypeInternalPassport for reference.
type SecureValueTypeInternalPassport struct {
}

// SecureValueTypeInternalPassportTypeID is TL type id of SecureValueTypeInternalPassport.
const SecureValueTypeInternalPassportTypeID = 0x99a48f23

// construct implements constructor of SecureValueTypeClass.
func ( SecureValueTypeInternalPassport) () SecureValueTypeClass { return & }

// Ensuring interfaces in compile-time for SecureValueTypeInternalPassport.
var (
	_ bin.Encoder     = &SecureValueTypeInternalPassport{}
	_ bin.Decoder     = &SecureValueTypeInternalPassport{}
	_ bin.BareEncoder = &SecureValueTypeInternalPassport{}
	_ bin.BareDecoder = &SecureValueTypeInternalPassport{}

	_ SecureValueTypeClass = &SecureValueTypeInternalPassport{}
)

func ( *SecureValueTypeInternalPassport) () bool {
	if  == nil {
		return true
	}

	return true
}

// String implements fmt.Stringer.
func ( *SecureValueTypeInternalPassport) () string {
	if  == nil {
		return "SecureValueTypeInternalPassport(nil)"
	}
	type  SecureValueTypeInternalPassport
	return fmt.Sprintf("SecureValueTypeInternalPassport%+v", (*))
}

// TypeID returns type id in TL schema.
//
// See https://core.telegram.org/mtproto/TL-tl#remarks.
func (*SecureValueTypeInternalPassport) () uint32 {
	return SecureValueTypeInternalPassportTypeID
}

// TypeName returns name of type in TL schema.
func (*SecureValueTypeInternalPassport) () string {
	return "secureValueTypeInternalPassport"
}

// TypeInfo returns info about TL type.
func ( *SecureValueTypeInternalPassport) () tdp.Type {
	 := tdp.Type{
		Name: "secureValueTypeInternalPassport",
		ID:   SecureValueTypeInternalPassportTypeID,
	}
	if  == nil {
		.Null = true
		return 
	}
	.Fields = []tdp.Field{}
	return 
}

// Encode implements bin.Encoder.
func ( *SecureValueTypeInternalPassport) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeInternalPassport#99a48f23 as nil")
	}
	.PutID(SecureValueTypeInternalPassportTypeID)
	return .EncodeBare()
}

// EncodeBare implements bin.BareEncoder.
func ( *SecureValueTypeInternalPassport) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeInternalPassport#99a48f23 as nil")
	}
	return nil
}

// Decode implements bin.Decoder.
func ( *SecureValueTypeInternalPassport) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeInternalPassport#99a48f23 to nil")
	}
	if  := .ConsumeID(SecureValueTypeInternalPassportTypeID);  != nil {
		return fmt.Errorf("unable to decode secureValueTypeInternalPassport#99a48f23: %w", )
	}
	return .DecodeBare()
}

// DecodeBare implements bin.BareDecoder.
func ( *SecureValueTypeInternalPassport) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeInternalPassport#99a48f23 to nil")
	}
	return nil
}

// SecureValueTypeAddress represents TL type `secureValueTypeAddress#cbe31e26`.
// Address
//
// See https://core.telegram.org/constructor/secureValueTypeAddress for reference.
type SecureValueTypeAddress struct {
}

// SecureValueTypeAddressTypeID is TL type id of SecureValueTypeAddress.
const SecureValueTypeAddressTypeID = 0xcbe31e26

// construct implements constructor of SecureValueTypeClass.
func ( SecureValueTypeAddress) () SecureValueTypeClass { return & }

// Ensuring interfaces in compile-time for SecureValueTypeAddress.
var (
	_ bin.Encoder     = &SecureValueTypeAddress{}
	_ bin.Decoder     = &SecureValueTypeAddress{}
	_ bin.BareEncoder = &SecureValueTypeAddress{}
	_ bin.BareDecoder = &SecureValueTypeAddress{}

	_ SecureValueTypeClass = &SecureValueTypeAddress{}
)

func ( *SecureValueTypeAddress) () bool {
	if  == nil {
		return true
	}

	return true
}

// String implements fmt.Stringer.
func ( *SecureValueTypeAddress) () string {
	if  == nil {
		return "SecureValueTypeAddress(nil)"
	}
	type  SecureValueTypeAddress
	return fmt.Sprintf("SecureValueTypeAddress%+v", (*))
}

// TypeID returns type id in TL schema.
//
// See https://core.telegram.org/mtproto/TL-tl#remarks.
func (*SecureValueTypeAddress) () uint32 {
	return SecureValueTypeAddressTypeID
}

// TypeName returns name of type in TL schema.
func (*SecureValueTypeAddress) () string {
	return "secureValueTypeAddress"
}

// TypeInfo returns info about TL type.
func ( *SecureValueTypeAddress) () tdp.Type {
	 := tdp.Type{
		Name: "secureValueTypeAddress",
		ID:   SecureValueTypeAddressTypeID,
	}
	if  == nil {
		.Null = true
		return 
	}
	.Fields = []tdp.Field{}
	return 
}

// Encode implements bin.Encoder.
func ( *SecureValueTypeAddress) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeAddress#cbe31e26 as nil")
	}
	.PutID(SecureValueTypeAddressTypeID)
	return .EncodeBare()
}

// EncodeBare implements bin.BareEncoder.
func ( *SecureValueTypeAddress) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeAddress#cbe31e26 as nil")
	}
	return nil
}

// Decode implements bin.Decoder.
func ( *SecureValueTypeAddress) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeAddress#cbe31e26 to nil")
	}
	if  := .ConsumeID(SecureValueTypeAddressTypeID);  != nil {
		return fmt.Errorf("unable to decode secureValueTypeAddress#cbe31e26: %w", )
	}
	return .DecodeBare()
}

// DecodeBare implements bin.BareDecoder.
func ( *SecureValueTypeAddress) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeAddress#cbe31e26 to nil")
	}
	return nil
}

// SecureValueTypeUtilityBill represents TL type `secureValueTypeUtilityBill#fc36954e`.
// Utility bill
//
// See https://core.telegram.org/constructor/secureValueTypeUtilityBill for reference.
type SecureValueTypeUtilityBill struct {
}

// SecureValueTypeUtilityBillTypeID is TL type id of SecureValueTypeUtilityBill.
const SecureValueTypeUtilityBillTypeID = 0xfc36954e

// construct implements constructor of SecureValueTypeClass.
func ( SecureValueTypeUtilityBill) () SecureValueTypeClass { return & }

// Ensuring interfaces in compile-time for SecureValueTypeUtilityBill.
var (
	_ bin.Encoder     = &SecureValueTypeUtilityBill{}
	_ bin.Decoder     = &SecureValueTypeUtilityBill{}
	_ bin.BareEncoder = &SecureValueTypeUtilityBill{}
	_ bin.BareDecoder = &SecureValueTypeUtilityBill{}

	_ SecureValueTypeClass = &SecureValueTypeUtilityBill{}
)

func ( *SecureValueTypeUtilityBill) () bool {
	if  == nil {
		return true
	}

	return true
}

// String implements fmt.Stringer.
func ( *SecureValueTypeUtilityBill) () string {
	if  == nil {
		return "SecureValueTypeUtilityBill(nil)"
	}
	type  SecureValueTypeUtilityBill
	return fmt.Sprintf("SecureValueTypeUtilityBill%+v", (*))
}

// TypeID returns type id in TL schema.
//
// See https://core.telegram.org/mtproto/TL-tl#remarks.
func (*SecureValueTypeUtilityBill) () uint32 {
	return SecureValueTypeUtilityBillTypeID
}

// TypeName returns name of type in TL schema.
func (*SecureValueTypeUtilityBill) () string {
	return "secureValueTypeUtilityBill"
}

// TypeInfo returns info about TL type.
func ( *SecureValueTypeUtilityBill) () tdp.Type {
	 := tdp.Type{
		Name: "secureValueTypeUtilityBill",
		ID:   SecureValueTypeUtilityBillTypeID,
	}
	if  == nil {
		.Null = true
		return 
	}
	.Fields = []tdp.Field{}
	return 
}

// Encode implements bin.Encoder.
func ( *SecureValueTypeUtilityBill) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeUtilityBill#fc36954e as nil")
	}
	.PutID(SecureValueTypeUtilityBillTypeID)
	return .EncodeBare()
}

// EncodeBare implements bin.BareEncoder.
func ( *SecureValueTypeUtilityBill) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeUtilityBill#fc36954e as nil")
	}
	return nil
}

// Decode implements bin.Decoder.
func ( *SecureValueTypeUtilityBill) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeUtilityBill#fc36954e to nil")
	}
	if  := .ConsumeID(SecureValueTypeUtilityBillTypeID);  != nil {
		return fmt.Errorf("unable to decode secureValueTypeUtilityBill#fc36954e: %w", )
	}
	return .DecodeBare()
}

// DecodeBare implements bin.BareDecoder.
func ( *SecureValueTypeUtilityBill) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeUtilityBill#fc36954e to nil")
	}
	return nil
}

// SecureValueTypeBankStatement represents TL type `secureValueTypeBankStatement#89137c0d`.
// Bank statement
//
// See https://core.telegram.org/constructor/secureValueTypeBankStatement for reference.
type SecureValueTypeBankStatement struct {
}

// SecureValueTypeBankStatementTypeID is TL type id of SecureValueTypeBankStatement.
const SecureValueTypeBankStatementTypeID = 0x89137c0d

// construct implements constructor of SecureValueTypeClass.
func ( SecureValueTypeBankStatement) () SecureValueTypeClass { return & }

// Ensuring interfaces in compile-time for SecureValueTypeBankStatement.
var (
	_ bin.Encoder     = &SecureValueTypeBankStatement{}
	_ bin.Decoder     = &SecureValueTypeBankStatement{}
	_ bin.BareEncoder = &SecureValueTypeBankStatement{}
	_ bin.BareDecoder = &SecureValueTypeBankStatement{}

	_ SecureValueTypeClass = &SecureValueTypeBankStatement{}
)

func ( *SecureValueTypeBankStatement) () bool {
	if  == nil {
		return true
	}

	return true
}

// String implements fmt.Stringer.
func ( *SecureValueTypeBankStatement) () string {
	if  == nil {
		return "SecureValueTypeBankStatement(nil)"
	}
	type  SecureValueTypeBankStatement
	return fmt.Sprintf("SecureValueTypeBankStatement%+v", (*))
}

// TypeID returns type id in TL schema.
//
// See https://core.telegram.org/mtproto/TL-tl#remarks.
func (*SecureValueTypeBankStatement) () uint32 {
	return SecureValueTypeBankStatementTypeID
}

// TypeName returns name of type in TL schema.
func (*SecureValueTypeBankStatement) () string {
	return "secureValueTypeBankStatement"
}

// TypeInfo returns info about TL type.
func ( *SecureValueTypeBankStatement) () tdp.Type {
	 := tdp.Type{
		Name: "secureValueTypeBankStatement",
		ID:   SecureValueTypeBankStatementTypeID,
	}
	if  == nil {
		.Null = true
		return 
	}
	.Fields = []tdp.Field{}
	return 
}

// Encode implements bin.Encoder.
func ( *SecureValueTypeBankStatement) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeBankStatement#89137c0d as nil")
	}
	.PutID(SecureValueTypeBankStatementTypeID)
	return .EncodeBare()
}

// EncodeBare implements bin.BareEncoder.
func ( *SecureValueTypeBankStatement) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeBankStatement#89137c0d as nil")
	}
	return nil
}

// Decode implements bin.Decoder.
func ( *SecureValueTypeBankStatement) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeBankStatement#89137c0d to nil")
	}
	if  := .ConsumeID(SecureValueTypeBankStatementTypeID);  != nil {
		return fmt.Errorf("unable to decode secureValueTypeBankStatement#89137c0d: %w", )
	}
	return .DecodeBare()
}

// DecodeBare implements bin.BareDecoder.
func ( *SecureValueTypeBankStatement) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeBankStatement#89137c0d to nil")
	}
	return nil
}

// SecureValueTypeRentalAgreement represents TL type `secureValueTypeRentalAgreement#8b883488`.
// Rental agreement
//
// See https://core.telegram.org/constructor/secureValueTypeRentalAgreement for reference.
type SecureValueTypeRentalAgreement struct {
}

// SecureValueTypeRentalAgreementTypeID is TL type id of SecureValueTypeRentalAgreement.
const SecureValueTypeRentalAgreementTypeID = 0x8b883488

// construct implements constructor of SecureValueTypeClass.
func ( SecureValueTypeRentalAgreement) () SecureValueTypeClass { return & }

// Ensuring interfaces in compile-time for SecureValueTypeRentalAgreement.
var (
	_ bin.Encoder     = &SecureValueTypeRentalAgreement{}
	_ bin.Decoder     = &SecureValueTypeRentalAgreement{}
	_ bin.BareEncoder = &SecureValueTypeRentalAgreement{}
	_ bin.BareDecoder = &SecureValueTypeRentalAgreement{}

	_ SecureValueTypeClass = &SecureValueTypeRentalAgreement{}
)

func ( *SecureValueTypeRentalAgreement) () bool {
	if  == nil {
		return true
	}

	return true
}

// String implements fmt.Stringer.
func ( *SecureValueTypeRentalAgreement) () string {
	if  == nil {
		return "SecureValueTypeRentalAgreement(nil)"
	}
	type  SecureValueTypeRentalAgreement
	return fmt.Sprintf("SecureValueTypeRentalAgreement%+v", (*))
}

// TypeID returns type id in TL schema.
//
// See https://core.telegram.org/mtproto/TL-tl#remarks.
func (*SecureValueTypeRentalAgreement) () uint32 {
	return SecureValueTypeRentalAgreementTypeID
}

// TypeName returns name of type in TL schema.
func (*SecureValueTypeRentalAgreement) () string {
	return "secureValueTypeRentalAgreement"
}

// TypeInfo returns info about TL type.
func ( *SecureValueTypeRentalAgreement) () tdp.Type {
	 := tdp.Type{
		Name: "secureValueTypeRentalAgreement",
		ID:   SecureValueTypeRentalAgreementTypeID,
	}
	if  == nil {
		.Null = true
		return 
	}
	.Fields = []tdp.Field{}
	return 
}

// Encode implements bin.Encoder.
func ( *SecureValueTypeRentalAgreement) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeRentalAgreement#8b883488 as nil")
	}
	.PutID(SecureValueTypeRentalAgreementTypeID)
	return .EncodeBare()
}

// EncodeBare implements bin.BareEncoder.
func ( *SecureValueTypeRentalAgreement) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeRentalAgreement#8b883488 as nil")
	}
	return nil
}

// Decode implements bin.Decoder.
func ( *SecureValueTypeRentalAgreement) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeRentalAgreement#8b883488 to nil")
	}
	if  := .ConsumeID(SecureValueTypeRentalAgreementTypeID);  != nil {
		return fmt.Errorf("unable to decode secureValueTypeRentalAgreement#8b883488: %w", )
	}
	return .DecodeBare()
}

// DecodeBare implements bin.BareDecoder.
func ( *SecureValueTypeRentalAgreement) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeRentalAgreement#8b883488 to nil")
	}
	return nil
}

// SecureValueTypePassportRegistration represents TL type `secureValueTypePassportRegistration#99e3806a`.
// Internal registration passport¹
//
// Links:
//  1. https://core.telegram.org/passport
//
// See https://core.telegram.org/constructor/secureValueTypePassportRegistration for reference.
type SecureValueTypePassportRegistration struct {
}

// SecureValueTypePassportRegistrationTypeID is TL type id of SecureValueTypePassportRegistration.
const SecureValueTypePassportRegistrationTypeID = 0x99e3806a

// construct implements constructor of SecureValueTypeClass.
func ( SecureValueTypePassportRegistration) () SecureValueTypeClass { return & }

// Ensuring interfaces in compile-time for SecureValueTypePassportRegistration.
var (
	_ bin.Encoder     = &SecureValueTypePassportRegistration{}
	_ bin.Decoder     = &SecureValueTypePassportRegistration{}
	_ bin.BareEncoder = &SecureValueTypePassportRegistration{}
	_ bin.BareDecoder = &SecureValueTypePassportRegistration{}

	_ SecureValueTypeClass = &SecureValueTypePassportRegistration{}
)

func ( *SecureValueTypePassportRegistration) () bool {
	if  == nil {
		return true
	}

	return true
}

// String implements fmt.Stringer.
func ( *SecureValueTypePassportRegistration) () string {
	if  == nil {
		return "SecureValueTypePassportRegistration(nil)"
	}
	type  SecureValueTypePassportRegistration
	return fmt.Sprintf("SecureValueTypePassportRegistration%+v", (*))
}

// TypeID returns type id in TL schema.
//
// See https://core.telegram.org/mtproto/TL-tl#remarks.
func (*SecureValueTypePassportRegistration) () uint32 {
	return SecureValueTypePassportRegistrationTypeID
}

// TypeName returns name of type in TL schema.
func (*SecureValueTypePassportRegistration) () string {
	return "secureValueTypePassportRegistration"
}

// TypeInfo returns info about TL type.
func ( *SecureValueTypePassportRegistration) () tdp.Type {
	 := tdp.Type{
		Name: "secureValueTypePassportRegistration",
		ID:   SecureValueTypePassportRegistrationTypeID,
	}
	if  == nil {
		.Null = true
		return 
	}
	.Fields = []tdp.Field{}
	return 
}

// Encode implements bin.Encoder.
func ( *SecureValueTypePassportRegistration) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypePassportRegistration#99e3806a as nil")
	}
	.PutID(SecureValueTypePassportRegistrationTypeID)
	return .EncodeBare()
}

// EncodeBare implements bin.BareEncoder.
func ( *SecureValueTypePassportRegistration) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypePassportRegistration#99e3806a as nil")
	}
	return nil
}

// Decode implements bin.Decoder.
func ( *SecureValueTypePassportRegistration) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypePassportRegistration#99e3806a to nil")
	}
	if  := .ConsumeID(SecureValueTypePassportRegistrationTypeID);  != nil {
		return fmt.Errorf("unable to decode secureValueTypePassportRegistration#99e3806a: %w", )
	}
	return .DecodeBare()
}

// DecodeBare implements bin.BareDecoder.
func ( *SecureValueTypePassportRegistration) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypePassportRegistration#99e3806a to nil")
	}
	return nil
}

// SecureValueTypeTemporaryRegistration represents TL type `secureValueTypeTemporaryRegistration#ea02ec33`.
// Temporary registration
//
// See https://core.telegram.org/constructor/secureValueTypeTemporaryRegistration for reference.
type SecureValueTypeTemporaryRegistration struct {
}

// SecureValueTypeTemporaryRegistrationTypeID is TL type id of SecureValueTypeTemporaryRegistration.
const SecureValueTypeTemporaryRegistrationTypeID = 0xea02ec33

// construct implements constructor of SecureValueTypeClass.
func ( SecureValueTypeTemporaryRegistration) () SecureValueTypeClass { return & }

// Ensuring interfaces in compile-time for SecureValueTypeTemporaryRegistration.
var (
	_ bin.Encoder     = &SecureValueTypeTemporaryRegistration{}
	_ bin.Decoder     = &SecureValueTypeTemporaryRegistration{}
	_ bin.BareEncoder = &SecureValueTypeTemporaryRegistration{}
	_ bin.BareDecoder = &SecureValueTypeTemporaryRegistration{}

	_ SecureValueTypeClass = &SecureValueTypeTemporaryRegistration{}
)

func ( *SecureValueTypeTemporaryRegistration) () bool {
	if  == nil {
		return true
	}

	return true
}

// String implements fmt.Stringer.
func ( *SecureValueTypeTemporaryRegistration) () string {
	if  == nil {
		return "SecureValueTypeTemporaryRegistration(nil)"
	}
	type  SecureValueTypeTemporaryRegistration
	return fmt.Sprintf("SecureValueTypeTemporaryRegistration%+v", (*))
}

// TypeID returns type id in TL schema.
//
// See https://core.telegram.org/mtproto/TL-tl#remarks.
func (*SecureValueTypeTemporaryRegistration) () uint32 {
	return SecureValueTypeTemporaryRegistrationTypeID
}

// TypeName returns name of type in TL schema.
func (*SecureValueTypeTemporaryRegistration) () string {
	return "secureValueTypeTemporaryRegistration"
}

// TypeInfo returns info about TL type.
func ( *SecureValueTypeTemporaryRegistration) () tdp.Type {
	 := tdp.Type{
		Name: "secureValueTypeTemporaryRegistration",
		ID:   SecureValueTypeTemporaryRegistrationTypeID,
	}
	if  == nil {
		.Null = true
		return 
	}
	.Fields = []tdp.Field{}
	return 
}

// Encode implements bin.Encoder.
func ( *SecureValueTypeTemporaryRegistration) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeTemporaryRegistration#ea02ec33 as nil")
	}
	.PutID(SecureValueTypeTemporaryRegistrationTypeID)
	return .EncodeBare()
}

// EncodeBare implements bin.BareEncoder.
func ( *SecureValueTypeTemporaryRegistration) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeTemporaryRegistration#ea02ec33 as nil")
	}
	return nil
}

// Decode implements bin.Decoder.
func ( *SecureValueTypeTemporaryRegistration) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeTemporaryRegistration#ea02ec33 to nil")
	}
	if  := .ConsumeID(SecureValueTypeTemporaryRegistrationTypeID);  != nil {
		return fmt.Errorf("unable to decode secureValueTypeTemporaryRegistration#ea02ec33: %w", )
	}
	return .DecodeBare()
}

// DecodeBare implements bin.BareDecoder.
func ( *SecureValueTypeTemporaryRegistration) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeTemporaryRegistration#ea02ec33 to nil")
	}
	return nil
}

// SecureValueTypePhone represents TL type `secureValueTypePhone#b320aadb`.
// Phone
//
// See https://core.telegram.org/constructor/secureValueTypePhone for reference.
type SecureValueTypePhone struct {
}

// SecureValueTypePhoneTypeID is TL type id of SecureValueTypePhone.
const SecureValueTypePhoneTypeID = 0xb320aadb

// construct implements constructor of SecureValueTypeClass.
func ( SecureValueTypePhone) () SecureValueTypeClass { return & }

// Ensuring interfaces in compile-time for SecureValueTypePhone.
var (
	_ bin.Encoder     = &SecureValueTypePhone{}
	_ bin.Decoder     = &SecureValueTypePhone{}
	_ bin.BareEncoder = &SecureValueTypePhone{}
	_ bin.BareDecoder = &SecureValueTypePhone{}

	_ SecureValueTypeClass = &SecureValueTypePhone{}
)

func ( *SecureValueTypePhone) () bool {
	if  == nil {
		return true
	}

	return true
}

// String implements fmt.Stringer.
func ( *SecureValueTypePhone) () string {
	if  == nil {
		return "SecureValueTypePhone(nil)"
	}
	type  SecureValueTypePhone
	return fmt.Sprintf("SecureValueTypePhone%+v", (*))
}

// TypeID returns type id in TL schema.
//
// See https://core.telegram.org/mtproto/TL-tl#remarks.
func (*SecureValueTypePhone) () uint32 {
	return SecureValueTypePhoneTypeID
}

// TypeName returns name of type in TL schema.
func (*SecureValueTypePhone) () string {
	return "secureValueTypePhone"
}

// TypeInfo returns info about TL type.
func ( *SecureValueTypePhone) () tdp.Type {
	 := tdp.Type{
		Name: "secureValueTypePhone",
		ID:   SecureValueTypePhoneTypeID,
	}
	if  == nil {
		.Null = true
		return 
	}
	.Fields = []tdp.Field{}
	return 
}

// Encode implements bin.Encoder.
func ( *SecureValueTypePhone) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypePhone#b320aadb as nil")
	}
	.PutID(SecureValueTypePhoneTypeID)
	return .EncodeBare()
}

// EncodeBare implements bin.BareEncoder.
func ( *SecureValueTypePhone) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypePhone#b320aadb as nil")
	}
	return nil
}

// Decode implements bin.Decoder.
func ( *SecureValueTypePhone) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypePhone#b320aadb to nil")
	}
	if  := .ConsumeID(SecureValueTypePhoneTypeID);  != nil {
		return fmt.Errorf("unable to decode secureValueTypePhone#b320aadb: %w", )
	}
	return .DecodeBare()
}

// DecodeBare implements bin.BareDecoder.
func ( *SecureValueTypePhone) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypePhone#b320aadb to nil")
	}
	return nil
}

// SecureValueTypeEmail represents TL type `secureValueTypeEmail#8e3ca7ee`.
// Email
//
// See https://core.telegram.org/constructor/secureValueTypeEmail for reference.
type SecureValueTypeEmail struct {
}

// SecureValueTypeEmailTypeID is TL type id of SecureValueTypeEmail.
const SecureValueTypeEmailTypeID = 0x8e3ca7ee

// construct implements constructor of SecureValueTypeClass.
func ( SecureValueTypeEmail) () SecureValueTypeClass { return & }

// Ensuring interfaces in compile-time for SecureValueTypeEmail.
var (
	_ bin.Encoder     = &SecureValueTypeEmail{}
	_ bin.Decoder     = &SecureValueTypeEmail{}
	_ bin.BareEncoder = &SecureValueTypeEmail{}
	_ bin.BareDecoder = &SecureValueTypeEmail{}

	_ SecureValueTypeClass = &SecureValueTypeEmail{}
)

func ( *SecureValueTypeEmail) () bool {
	if  == nil {
		return true
	}

	return true
}

// String implements fmt.Stringer.
func ( *SecureValueTypeEmail) () string {
	if  == nil {
		return "SecureValueTypeEmail(nil)"
	}
	type  SecureValueTypeEmail
	return fmt.Sprintf("SecureValueTypeEmail%+v", (*))
}

// TypeID returns type id in TL schema.
//
// See https://core.telegram.org/mtproto/TL-tl#remarks.
func (*SecureValueTypeEmail) () uint32 {
	return SecureValueTypeEmailTypeID
}

// TypeName returns name of type in TL schema.
func (*SecureValueTypeEmail) () string {
	return "secureValueTypeEmail"
}

// TypeInfo returns info about TL type.
func ( *SecureValueTypeEmail) () tdp.Type {
	 := tdp.Type{
		Name: "secureValueTypeEmail",
		ID:   SecureValueTypeEmailTypeID,
	}
	if  == nil {
		.Null = true
		return 
	}
	.Fields = []tdp.Field{}
	return 
}

// Encode implements bin.Encoder.
func ( *SecureValueTypeEmail) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeEmail#8e3ca7ee as nil")
	}
	.PutID(SecureValueTypeEmailTypeID)
	return .EncodeBare()
}

// EncodeBare implements bin.BareEncoder.
func ( *SecureValueTypeEmail) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't encode secureValueTypeEmail#8e3ca7ee as nil")
	}
	return nil
}

// Decode implements bin.Decoder.
func ( *SecureValueTypeEmail) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeEmail#8e3ca7ee to nil")
	}
	if  := .ConsumeID(SecureValueTypeEmailTypeID);  != nil {
		return fmt.Errorf("unable to decode secureValueTypeEmail#8e3ca7ee: %w", )
	}
	return .DecodeBare()
}

// DecodeBare implements bin.BareDecoder.
func ( *SecureValueTypeEmail) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("can't decode secureValueTypeEmail#8e3ca7ee to nil")
	}
	return nil
}

// SecureValueTypeClassName is schema name of SecureValueTypeClass.
const SecureValueTypeClassName = "SecureValueType"

// SecureValueTypeClass represents SecureValueType generic type.
//
// See https://core.telegram.org/type/SecureValueType for reference.
//
// Example:
//
//	g, err := tg.DecodeSecureValueType(buf)
//	if err != nil {
//	    panic(err)
//	}
//	switch v := g.(type) {
//	case *tg.SecureValueTypePersonalDetails: // secureValueTypePersonalDetails#9d2a81e3
//	case *tg.SecureValueTypePassport: // secureValueTypePassport#3dac6a00
//	case *tg.SecureValueTypeDriverLicense: // secureValueTypeDriverLicense#6e425c4
//	case *tg.SecureValueTypeIdentityCard: // secureValueTypeIdentityCard#a0d0744b
//	case *tg.SecureValueTypeInternalPassport: // secureValueTypeInternalPassport#99a48f23
//	case *tg.SecureValueTypeAddress: // secureValueTypeAddress#cbe31e26
//	case *tg.SecureValueTypeUtilityBill: // secureValueTypeUtilityBill#fc36954e
//	case *tg.SecureValueTypeBankStatement: // secureValueTypeBankStatement#89137c0d
//	case *tg.SecureValueTypeRentalAgreement: // secureValueTypeRentalAgreement#8b883488
//	case *tg.SecureValueTypePassportRegistration: // secureValueTypePassportRegistration#99e3806a
//	case *tg.SecureValueTypeTemporaryRegistration: // secureValueTypeTemporaryRegistration#ea02ec33
//	case *tg.SecureValueTypePhone: // secureValueTypePhone#b320aadb
//	case *tg.SecureValueTypeEmail: // secureValueTypeEmail#8e3ca7ee
//	default: panic(v)
//	}
type SecureValueTypeClass interface {
	bin.Encoder
	bin.Decoder
	bin.BareEncoder
	bin.BareDecoder
	construct() SecureValueTypeClass

	// TypeID returns type id in TL schema.
	//
	// See https://core.telegram.org/mtproto/TL-tl#remarks.
	TypeID() uint32
	// TypeName returns name of type in TL schema.
	TypeName() string
	// String implements fmt.Stringer.
	String() string
	// Zero returns true if current object has a zero value.
	Zero() bool
}

// DecodeSecureValueType implements binary de-serialization for SecureValueTypeClass.
func ( *bin.Buffer) (SecureValueTypeClass, error) {
	,  := .PeekID()
	if  != nil {
		return nil, 
	}
	switch  {
	case SecureValueTypePersonalDetailsTypeID:
		// Decoding secureValueTypePersonalDetails#9d2a81e3.
		 := SecureValueTypePersonalDetails{}
		if  := .Decode();  != nil {
			return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", )
		}
		return &, nil
	case SecureValueTypePassportTypeID:
		// Decoding secureValueTypePassport#3dac6a00.
		 := SecureValueTypePassport{}
		if  := .Decode();  != nil {
			return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", )
		}
		return &, nil
	case SecureValueTypeDriverLicenseTypeID:
		// Decoding secureValueTypeDriverLicense#6e425c4.
		 := SecureValueTypeDriverLicense{}
		if  := .Decode();  != nil {
			return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", )
		}
		return &, nil
	case SecureValueTypeIdentityCardTypeID:
		// Decoding secureValueTypeIdentityCard#a0d0744b.
		 := SecureValueTypeIdentityCard{}
		if  := .Decode();  != nil {
			return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", )
		}
		return &, nil
	case SecureValueTypeInternalPassportTypeID:
		// Decoding secureValueTypeInternalPassport#99a48f23.
		 := SecureValueTypeInternalPassport{}
		if  := .Decode();  != nil {
			return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", )
		}
		return &, nil
	case SecureValueTypeAddressTypeID:
		// Decoding secureValueTypeAddress#cbe31e26.
		 := SecureValueTypeAddress{}
		if  := .Decode();  != nil {
			return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", )
		}
		return &, nil
	case SecureValueTypeUtilityBillTypeID:
		// Decoding secureValueTypeUtilityBill#fc36954e.
		 := SecureValueTypeUtilityBill{}
		if  := .Decode();  != nil {
			return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", )
		}
		return &, nil
	case SecureValueTypeBankStatementTypeID:
		// Decoding secureValueTypeBankStatement#89137c0d.
		 := SecureValueTypeBankStatement{}
		if  := .Decode();  != nil {
			return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", )
		}
		return &, nil
	case SecureValueTypeRentalAgreementTypeID:
		// Decoding secureValueTypeRentalAgreement#8b883488.
		 := SecureValueTypeRentalAgreement{}
		if  := .Decode();  != nil {
			return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", )
		}
		return &, nil
	case SecureValueTypePassportRegistrationTypeID:
		// Decoding secureValueTypePassportRegistration#99e3806a.
		 := SecureValueTypePassportRegistration{}
		if  := .Decode();  != nil {
			return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", )
		}
		return &, nil
	case SecureValueTypeTemporaryRegistrationTypeID:
		// Decoding secureValueTypeTemporaryRegistration#ea02ec33.
		 := SecureValueTypeTemporaryRegistration{}
		if  := .Decode();  != nil {
			return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", )
		}
		return &, nil
	case SecureValueTypePhoneTypeID:
		// Decoding secureValueTypePhone#b320aadb.
		 := SecureValueTypePhone{}
		if  := .Decode();  != nil {
			return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", )
		}
		return &, nil
	case SecureValueTypeEmailTypeID:
		// Decoding secureValueTypeEmail#8e3ca7ee.
		 := SecureValueTypeEmail{}
		if  := .Decode();  != nil {
			return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", )
		}
		return &, nil
	default:
		return nil, fmt.Errorf("unable to decode SecureValueTypeClass: %w", bin.NewUnexpectedID())
	}
}

// SecureValueType boxes the SecureValueTypeClass providing a helper.
type SecureValueTypeBox struct {
	SecureValueType SecureValueTypeClass
}

// Decode implements bin.Decoder for SecureValueTypeBox.
func ( *SecureValueTypeBox) ( *bin.Buffer) error {
	if  == nil {
		return fmt.Errorf("unable to decode SecureValueTypeBox to nil")
	}
	,  := DecodeSecureValueType()
	if  != nil {
		return fmt.Errorf("unable to decode boxed value: %w", )
	}
	.SecureValueType = 
	return nil
}

// Encode implements bin.Encode for SecureValueTypeBox.
func ( *SecureValueTypeBox) ( *bin.Buffer) error {
	if  == nil || .SecureValueType == nil {
		return fmt.Errorf("unable to encode SecureValueTypeClass as nil")
	}
	return .SecureValueType.Encode()
}