class_docstr: A BytesIO-like object, backed by an in-memory file.
  
  This allows formatted files to be read and written without I/O.
  
  A MemoryFile created with initial bytes becomes immutable. A
  MemoryFile created without initial bytes may be written to using
  either file-like or dataset interfaces.
  
  Parameters
  ----------
  file_or_bytes : an open Python file, bytes, or None
      If not None, the MemoryFile becomes immutable and read-only.
      If None, it is write-only.
  filename : str
      An optional filename. The default is a UUID-based name.
  ext : str
      An optional file extension. Some format drivers require a
      specific value.
class_docstr_tok: ["A","BytesIO-like","object",",","backed","by","an","in-memory","file",".","This","allows","formatted","files","to","be","read","and","written","without","I\/O",".","A","MemoryFile","created","with","initial","bytes","becomes","immutable",".","A","MemoryFile","created","without","initial","bytes","may","be","written","to","using","either","file-like","or","dataset","interfaces",".","Parameters","--","--","--","--","--","file_or_bytes",":","an","open","Python","file",",","bytes",",","or","None","If","not","None",",","the","MemoryFile","becomes","immutable","and","read-only",".","If","None",",","it","is","write-only",".","filename",":","str","An","optional","filename",".","The","default","is","a","UUID-based","name",".","ext",":","str","An","optional","file","extension",".","Some","format","drivers","require","a","specific","value","."]
code: def __enter__(self):
      return self
  
file_path: Fiona/fiona/io.py
imports: import logging
  from fiona.ogrext import MemoryFileBase, _listdir, _listlayers
  from fiona.collection import Collection
  from fiona.meta import supports_vsi
  from fiona.errors import DriverError
label_desc: Use image node_id 5 for calling the MemoryFile obj's underlying member method code with example usage: obj.__enter__() and returns: self