-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathmo_kuai1.py
More file actions
38 lines (30 loc) · 798 Bytes
/
mo_kuai1.py
File metadata and controls
38 lines (30 loc) · 798 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2020 ubuntu <ubuntu@VM-0-13-ubuntu>
#
# Distributed under terms of the MIT license.
"""
Clang is a module for name, age
only jiekou for info get_name
pelase ues it
"""
class Clang:
def __init__(self, name, age):
self.__name = name
self.__age = age
def __get_info(self):
return (self.__name, self.__age)
def __set_info(self, args):
self.__name, self.__age = args
def __del_info(self):
self.__name = 'xxx'
self.__age = 0
def get_name(self):
print('name is ',__name__)
info = property(__get_info, __set_info, __del_info)
if __name__ == '__main__':
test = Clang('wmsj100', 32)
print(test.info)
print('name is ',__name__)