예제 #1
0
 def addresses(self):
     # Since range will stop one before the endpoint, passing it
     # self.bcast effectively means that the addresses run from
     # the network start to last_host.
     return [
         int_to_dq(i)
         for i in range(dq_to_int(self.ip), dq_to_int(self.bcast))
     ]
예제 #2
0
파일: network.py 프로젝트: jrha/aquilon
 def addresses(self):
     # Since range will stop one before the endpoint, passing it
     # self.bcast effectively means that the addresses run from
     # the network start to last_host.
     return [int_to_dq(i) for i in range(dq_to_int(self.ip),
                                         dq_to_int(self.bcast))]
예제 #3
0
파일: network.py 프로젝트: jrha/aquilon
 def last_host(self):
     return int_to_dq(dq_to_int(self.bcast)-1)
예제 #4
0
파일: network.py 프로젝트: jrha/aquilon
 def first_host(self):
     return int_to_dq(dq_to_int(self.ip)+1)
예제 #5
0
 def last_host(self):
     return int_to_dq(dq_to_int(self.bcast) - 1)
예제 #6
0
 def first_host(self):
     return int_to_dq(dq_to_int(self.ip) + 1)