3 # Copyright 2011 Facebook
5 # Licensed under the Apache License, Version 2.0 (the "License"); you may
6 # not use this file except in compliance with the License. You may obtain
7 # a copy of the License at
9 # http://www.apache.org/licenses/LICENSE-2.0
11 # Unless required by applicable law or agreed to in writing, software
12 # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13 # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14 # License for the specific language governing permissions and limitations
17 """Implementation of platform-specific functionality.
19 For each function or class described in `tornado.platform.interface`,
20 the appropriate platform-specific implementation exists in this module.
21 Most code that needs access to this functionality should do e.g.::
23 from tornado.platform.auto import set_close_exec
26 from __future__ import absolute_import, division, print_function, with_statement
31 from .common import Waker
32 from .windows import set_close_exec
34 from .posix import set_close_exec, Waker
37 # monotime monkey-patches the time module to have a monotonic function
38 # in versions of python before 3.3.
43 from time import monotonic as monotonic_time