-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathclasses.py
More file actions
59 lines (46 loc) · 1.53 KB
/
classes.py
File metadata and controls
59 lines (46 loc) · 1.53 KB
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
import constants as DZ
import inspect
import pprint
class MyNewClass:
'''Docstring here ...'''
# local namespace
pass
class User:
'''User docstring'''
age = 10
def greet(self):
print('hello there')
# Output: 10
DZ.LINE(User.age)
DZ.LINE(User.greet)
DZ.LINE(User.__doc__)
dueminalov = User()
DZ.LINE(dueminalov.greet())
class api_SmartSheet:
'''Connection to SmartSheet and it's API endpoints'''
__dbPdo = '-connection to sql-'
__logErr = "-E_ALL-"
__steUser = '0xb5589228'
__auditLog = []
__pp = pprint.PrettyPrinter(indent=4)
def __init__(self):
curframe = inspect.currentframe()
calframe = inspect.getouterframes(curframe, 2)
self.__auditLog.append(str(calframe[1][4][-1]).strip())
def sync_sheets(self):
curframe = inspect.currentframe()
calframe = inspect.getouterframes(curframe, 2)
self.__auditLog.append(str(calframe[1][4][-1]).strip())
def process_newSheet(self):
curframe = inspect.currentframe()
calframe = inspect.getouterframes(curframe, 2)
self.__auditLog.append(str(calframe[1][4][-1]).strip())
def audit(self):
curframe = inspect.currentframe()
calframe = inspect.getouterframes(curframe, 2)
self.__auditLog.append(str(calframe[1][4][-1]).strip())
self.__pp.pprint(self.__auditLog)
SmartSheet = api_SmartSheet()
#SmartSheet.__auditLog.append('test') # __ is private attribute
SmartSheet.sync_sheets()
SmartSheet.audit()