-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathLogPoint.py
More file actions
34 lines (28 loc) · 740 Bytes
/
LogPoint.py
File metadata and controls
34 lines (28 loc) · 740 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
'''
Created on Dec 21, 2012
@author: mama
'''
class LogPoint:
def __init__(self, ip, name=None):
"""
logpoint ip address
logpoint name
"""
self.ip = ip
if name:
self.name = name
else:
self.name = self.ip.replace(".", "_")
def get_ip(self):
return self.ip
def get_name(self):
return self.name
def get_repos(self):
from LogPointSearcher import LogPointSearcher
searcher = LogPointSearcher()
return searcher.get_repos([self])
def __str__(self):
info = 'LogPoint Info\n'
info += '\tName : ' + self.name + '\n'
info += '\tIP : ' + self.ip + '\n'
return info