Sideband/sbapp/plyer/platforms/macosx/devicename.py

24 lines
394 B
Python
Raw Normal View History

2022-09-16 10:07:57 -06:00
'''
Module of MacOSX API for plyer.devicename.
'''
import socket
2024-06-02 10:31:58 -06:00
from sbapp.plyer.facades import DeviceName
2022-09-16 10:07:57 -06:00
class OSXDeviceName(DeviceName):
'''
Implementation of MacOSX DeviceName API.
'''
def _get_device_name(self):
hostname = socket.gethostname()
return hostname
def instance():
'''
Instance for facade proxy.
'''
return OSXDeviceName()