Something that is hopefully a DHCP server package
[invirt/packages/invirt-dhcp.git] / code / pydhcplib / examples / strlist_example.py
diff --git a/code/pydhcplib/examples/strlist_example.py b/code/pydhcplib/examples/strlist_example.py
new file mode 100755 (executable)
index 0000000..9a597ad
--- /dev/null
@@ -0,0 +1,25 @@
+#!/usr/bin/python
+
+from pydhcplib.type_strlist import strlist
+
+
+word = strlist()
+print "a0 : ",word
+
+word1 = strlist("azerty")
+print "a1 : ",word1
+
+word2 = strlist("qwerty")
+print "a2 : ",word2
+
+word3 = strlist([97, 122, 101, 114, 116, 121])
+print "a3 : ",word3
+
+if word1 == word2 : print "test 1 : ",word1, "==",word2
+else : print "test 1 : " ,word1, "!=",word2
+
+if word1 == word3 : print "test 2 : ", word1, "==",word3
+else : print "test 2 : ", word1, "!=",word3
+
+
+