PHP 7.4.33
Preview: patterns.py Size: 335 B
/lib/python3.6/site-packages/tuned/patterns.py

class Singleton(object):
	"""
	Singleton design pattern.
	"""

	_instance = None

	def __init__(self):
		if self.__class__ is Singleton:
			raise TypeError("Cannot instantiate directly.")

	@classmethod
	def get_instance(cls):
		"""Get the class instance."""
		if cls._instance is None:
			cls._instance = cls()
		return cls._instance

Directory Contents

Dirs: 12 × Files: 6

Name Size Perms Modified Actions
admin DIR
- drwxr-xr-x 2025-03-13 05:57:38
Edit Download
daemon DIR
- drwxr-xr-x 2025-03-13 05:57:38
Edit Download
exports DIR
- drwxr-xr-x 2025-03-13 05:57:38
Edit Download
hardware DIR
- drwxr-xr-x 2025-03-13 05:57:38
Edit Download
monitors DIR
- drwxr-xr-x 2025-03-13 05:57:38
Edit Download
plugins DIR
- drwxr-xr-x 2025-03-13 05:57:38
Edit Download
ppd DIR
- drwxr-xr-x 2025-03-13 05:57:38
Edit Download
profiles DIR
- drwxr-xr-x 2025-03-13 05:57:38
Edit Download
storage DIR
- drwxr-xr-x 2025-03-13 05:57:38
Edit Download
units DIR
- drwxr-xr-x 2025-03-13 05:57:38
Edit Download
utils DIR
- drwxr-xr-x 2025-03-13 05:57:38
Edit Download
- drwxr-xr-x 2025-03-13 05:57:38
Edit Download
7.84 KB lrw-r--r-- 2025-03-11 07:42:24
Edit Download
568 B lrw-r--r-- 2024-02-22 12:23:28
Edit Download
3.75 KB lrw-r--r-- 2024-02-22 12:23:28
Edit Download
335 B lrw-r--r-- 2024-02-22 12:23:28
Edit Download
171 B lrw-r--r-- 2024-02-22 12:23:28
Edit Download
953 B lrw-r--r-- 2024-02-22 12:23:28
Edit Download

If ZipArchive is unavailable, a .tar will be created (no compression).