s3:net_idmap_delete do not lock two records at the same time
[Samba/gebeck_regimport.git] / lib / dnspython / examples / name.py
blobb099c49d16675abdbb27e9fe635cc8cab6b422d9
1 #!/usr/bin/env python
3 import dns.name
5 n = dns.name.from_text('www.dnspython.org')
6 o = dns.name.from_text('dnspython.org')
7 print n.is_subdomain(o) # True
8 print n.is_superdomain(o) # False
9 print n > o # True
10 rel = n.relativize(o) # rel is the relative name www
11 n2 = rel + o
12 print n2 == n # True
13 print n.labels # ['www', 'dnspython', 'org', '']