code: def _itodq(self, n):
          
          if self.v == 4:
              return '.'.join(map(str, [
                  (n >> 24) & 0xff,
                  (n >> 16) & 0xff,
                  (n >> 8) & 0xff,
                  n & 0xff,
              ]))
          else:
              n = '%032x' % n
              return ':'.join(n[4 * x:4 * x + 4] for x in range(0, 8))
docs: Convert long to dotquad or hextet.