Flutter Engine
The Flutter Engine
Public Member Functions | List of all members
utils.IncreasedNumberOfFileDescriptors Class Reference
Inheritance diagram for utils.IncreasedNumberOfFileDescriptors:

Public Member Functions

def __init__ (self, nofiles)
 
def __enter__ (self)
 
def __exit__ (self, *_)
 

Detailed Description

Definition at line 954 of file utils.py.

Constructor & Destructor Documentation

◆ __init__()

def utils.IncreasedNumberOfFileDescriptors.__init__ (   self,
  nofiles 
)

Definition at line 956 of file utils.py.

956 def __init__(self, nofiles):
957 self._old_limits = None
958 self._limits = (nofiles, nofiles)
959

Member Function Documentation

◆ __enter__()

def utils.IncreasedNumberOfFileDescriptors.__enter__ (   self)

Definition at line 960 of file utils.py.

960 def __enter__(self):
961 self._old_limits = resource.getrlimit(resource.RLIMIT_NOFILE)
962 resource.setrlimit(resource.RLIMIT_NOFILE, self._limits)
963

◆ __exit__()

def utils.IncreasedNumberOfFileDescriptors.__exit__ (   self,
_ 
)

Definition at line 964 of file utils.py.

964 def __exit__(self, *_):
965 resource.setrlimit(resource.RLIMIT_CORE, self._old_limits)
966
967
968@contextlib.contextmanager

The documentation for this class was generated from the following file: