code: def use_edns(self, edns=0, ednsflags=0, payload=1280, request_payload=None, options=None):
          
          if edns is None or edns is False:
              edns = -1
          if edns is True:
              edns = 0
          if request_payload is None:
              request_payload = payload
          if edns < 0:
              ednsflags = 0
              payload = 0
              request_payload = 0
              options = []
          else:
              # make sure the EDNS version in ednsflags agrees with edns
              ednsflags &= 0xFF00FFFFL
              ednsflags |= (edns << 16)
              if options is None:
                  options = []
          self.edns = edns
          self.ednsflags = ednsflags
          self.payload = payload
          self.options = options
          self.request_payload = request_payload
docs: Configure EDNS behavior.
          @param edns: The EDNS level to use.  Specifying None, False, or -1
          means 'do not use EDNS', and in this case the other parameters are
          ignored.  Specifying True is equivalent to specifying 0, i.e. 'use
          EDNS0'.
          @type edns: int or bool or None
          @param ednsflags: EDNS flag values.
          @type ednsflags: int
          @param payload: The EDNS sender's payload field, which is the maximum
          size of UDP datagram the sender can handle.
          @type payload: int
          @param request_payload: The EDNS payload size to use when sending
          this message.  If not specified, defaults to the value of payload.
          @type request_payload: int or None
          @param options: The EDNS options
          @type options: None or list of dns.edns.Option objects
          @see: RFC 2671