github.com/mdaxf/iac@v0.0.0-20240519030858-58a061660378/vendor_skip/go.mongodb.org/mongo-driver/bson/bsoncodec/proxy.go (about) 1 // Copyright (C) MongoDB, Inc. 2017-present. 2 // 3 // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 // not use this file except in compliance with the License. You may obtain 5 // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 7 package bsoncodec 8 9 // Proxy is an interface implemented by types that cannot themselves be directly encoded. Types 10 // that implement this interface with have ProxyBSON called during the encoding process and that 11 // value will be encoded in place for the implementer. 12 type Proxy interface { 13 ProxyBSON() (interface{}, error) 14 }