code: def buffer(self, data=None, *, reserve=0, dynamic=False) -> Buffer:
          '''
              Create a :py:class:`Buffer` object.
  
              Args:
                  data (bytes): Content of the new buffer.
  
              Keyword Args:
                  reserve (int): The number of bytes to reserve.
                  dynamic (bool): Treat buffer as dynamic.
  
              Returns:
                  :py:class:`Buffer` object
          '''
  
          if type(reserve) is str:
              reserve = mgl.strsize(reserve)
  
          res = Buffer.__new__(Buffer)
          res.mglo, res._size, res._glo = self.mglo.buffer(data, reserve, dynamic)
          res._dynamic = dynamic
          res.ctx = self
          res.extra = None
          return ref buffer(self, data=None, *, reserve=0, dynamic=False) -> Buffer:
          '''
              Create a :py:class:`Buffer` object.
  
              Args:
                  data (bytes): Content of the new buffer.
  
              Keyword Args:
                  reserve (int): The number of bytes to reserve.
                  dynamic (bool): Treat buffer as dynamic.
  
              Returns:
                  :py:class:`Buffer` object
          '''
  
          if type(reserve) is str:
              reserve = mgl.strsize(reserve)
  
          res = Buffer.__new__(Buffer)
          res.mglo, res._size, res._glo = self.mglo.buffer(data, reserve, dynamic)
          res._dynamic = dynamic
          res.ctx = self
          res.extra = None
          return res
docs: Create a :py:class:`Buffer` object.
  
              Args:
                  data (bytes): Content of the new buffer.
  
              Keyword Args:
                  reserve (int): The number of bytes to reserve.
                  dynamic (bool): Treat buffer as dynamic.
  
              Returns:
                  :py:class:`Buffer` object