packet lib: dhcp: fix reversibility about json
packet lib: dhcp: fix reversibility about json

although DHCP is using internal classes, no class is registered into '_class_prefixes'.
therefore, from_jsondict() does not work correctly.
this patch makes from_jsondict() to work correctly by registering internal classes into '_class_prefixes'.

examination code:

    from ryu.lib.packet import dhcp
    msg1 = dhcp.dhcp(op=dhcp.DHCP_BOOT_REQUEST, chaddr='00:00:00:00:00:00', options=dhcp.options())
    print msg1
    jsondict = msg1.to_jsondict()
    msg2 = dhcp.dhcp.from_jsondict(jsondict['dhcp'])
    print msg2
    print str(msg1) == str(msg2)

before applying this patch:

    dhcp(boot_file='',chaddr='00:00:00:00:00:00',ciaddr='0.0.0.0',flags=0,giaddr='0.0.0.0',hlen=17,hops=0,htype=1,op=1,options=options(magic_cookie='99.130.83.99',option_list=[],options_len=0),secs=0,siaddr='0.0.0.0',sname='',xid=2430470794,yiaddr='0.0.0.0')
    dhcp(boot_file='',chaddr='00:00:00:00:00:00',ciaddr='0.0.0.0',flags=0,giaddr='0.0.0.0',hlen=17,hops=0,htype=1,op=1,options={'options': {'option_list': [], 'magic_cookie': '99.130.83.99', 'options_len': 0}},secs=0,siaddr='0.0.0.0',sname='',xid=2430470794,yiaddr='0.0.0.0')
    False

after applying this patch:

    dhcp(boot_file='',chaddr='00:00:00:00:00:00',ciaddr='0.0.0.0',flags=0,giaddr='0.0.0.0',hlen=17,hops=0,htype=1,op=1,options=options(magic_cookie='99.130.83.99',option_list=[],options_len=0),secs=0,siaddr='0.0.0.0',sname='',xid=1161619526,yiaddr='0.0.0.0')
    dhcp(boot_file='',chaddr='00:00:00:00:00:00',ciaddr='0.0.0.0',flags=0,giaddr='0.0.0.0',hlen=17,hops=0,htype=1,op=1,options=options(magic_cookie='99.130.83.99',option_list=[],options_len=0),secs=0,siaddr='0.0.0.0',sname='',xid=1161619526,yiaddr='0.0.0.0')
    True

Signed-off-by: Yuichi Ito <7a83edf5b53f0b21d4182a3da7518164ce03dc3a@gmail.com>
Signed-off-by: FUJITA Tomonori <93dac1fe9c4b2a3957982200319981492ad4976e@lab.ntt.co.jp>

lzppp/mylearning,StephenKing/summerschool-2015-ryu,shinpeimuraoka/ryu,castroflavio/ryu,castroflavio/ryu,sivaramakrishnansr/ryu,lsqtongxin/ryu,yamt/ryu,evanscottgray/ryu,o3project/ryu-oe,umkcdcrg01/ryu_openflow,zangree/ryu,TakeshiTseng/ryu,fujita/ryu,pichuang/ryu,fujita/ryu,Zouyiran/ryu,jkoelker/ryu,fkakuma/ryu,lzppp/mylearning,zangree/ryu,haniehrajabi/ryu,shinpeimuraoka/ryu,torufuru/oolhackathon,lagopus/ryu-lagopus-ext,ynkjm/ryu,yamada-h/ryu,ttsubo/ryu,sivaramakrishnansr/ryu,openvapour/ryu,diogommartins/ryu,elahejalalpour/ELRyu,gareging/SDN_Framework,lzppp/mylearning,TakeshiTseng/ryu,jalilm/ryu,lsqtongxin/ryu,hisaharu/ryu,jalilm/ryu,shinpeimuraoka/ryu,haniehrajabi/ryu,zangree/ryu,evanscottgray/ryu,takahashiminoru/ryu,TakeshiTseng/ryu,o3project/ryu-oe,jalilm/ryu,torufuru/OFPatchPanel,gopchandani/ryu,fkakuma/ryu,umkcdcrg01/ryu_openflow,darjus-amzn/ryu,diogommartins/ryu,fkakuma/ryu,OpenState-SDN/ryu,Tejas-Subramanya/RYU_MEC,gareging/SDN_Framework,torufuru/oolhackathon,shinpeimuraoka/ryu,alanquillin/ryu,umkcdcrg01/ryu_openflow,darjus-amzn/ryu,John-Lin/ryu,gopchandani/ryu,diogommartins/ryu,fujita/ryu,habibiefaried/ryu,TakeshiTseng/ryu,osrg/ryu,openvapour/ryu,Tesi-Luca-Davide/ryu,osrg/ryu,alanquillin/ryu,sivaramakrishnansr/ryu,zyq001/ryu,Tejas-Subramanya/RYU_MEC,ntts-clo/ryu,torufuru/OFPatchPanel,Tejas-Subramanya/RYU_MEC,OpenState-SDN/ryu,ntts-clo/mld-ryu,StephenKing/ryu,TakeshiTseng/ryu,gareging/SDN_Framework,habibiefaried/ryu,lagopus/ryu-lagopus-ext,alyosha1879/ryu,torufuru/oolhackathon,StephenKing/summerschool-2015-ryu,John-Lin/ryu,alanquillin/ryu,iwaseyusuke/ryu,lagopus/ryu-lagopus-ext,elahejalalpour/ELRyu,diogommartins/ryu,Tesi-Luca-Davide/ryu,diogommartins/ryu,darjus-amzn/ryu,evanscottgray/ryu,Tesi-Luca-Davide/ryu,ysywh/ryu,alyosha1879/ryu,gareging/SDN_Framework,Tejas-Subramanya/RYU_MEC,gareging/SDN_Framework,zangree/ryu,ynkjm/ryu,iwaseyusuke/ryu,fkakuma/ryu,pichuang/ryu,pichuang/ryu,yamt/ryu,openvapour/ryu,takahashiminoru/ryu,umkcdcrg01/ryu_openflow,muzixing/ryu,hisaharu/ryu,osrg/ryu,elahejalalpour/ELRyu,StephenKing/ryu,OpenState-SDN/ryu,zyq001/ryu,mikhaelharswanto/ryu,habibiefaried/ryu,ysywh/ryu,openvapour/ryu,habibiefaried/ryu,ttsubo/ryu,alanquillin/ryu,fkakuma/ryu,ynkjm/ryu,ttsubo/ryu,alyosha1879/ryu,sivaramakrishnansr/ryu,lzppp/mylearning,Tejas-Subramanya/RYU_MEC,ntts-clo/ryu,StephenKing/ryu,zangree/ryu,haniehrajabi/ryu,takahashiminoru/ryu,zyq001/ryu,ntts-clo/mld-ryu,zyq001/ryu,ttsubo/ryu,muzixing/ryu,habibiefaried/ryu,yamada-h/ryu,yamt/ryu,jalilm/ryu,StephenKing/summerschool-2015-ryu,jazzmes/ryu,mikhaelharswanto/ryu,openvapour/ryu,zyq001/ryu,Tesi-Luca-Davide/ryu,shinpeimuraoka/ryu,alanquillin/ryu,ysywh/ryu,gopchandani/ryu,ysywh/ryu,umkcdcrg01/ryu_openflow,muzixing/ryu,ynkjm/ryu,osrg/ryu,StephenKing/summerschool-2015-ryu,StephenKing/ryu,haniehrajabi/ryu,gopchandani/ryu,StephenKing/summerschool-2015-ryu,Tesi-Luca-Davide/ryu,sivaramakrishnansr/ryu,takahashiminoru/ryu,John-Lin/ryu,Zouyiran/ryu,yamt/ryu,hisaharu/ryu,OpenState-SDN/ryu,darjus-amzn/ryu,darjus-amzn/ryu,pichuang/ryu,lagopus/ryu-lagopus-ext,takahashiminoru/ryu,OpenState-SDN/ryu,iwaseyusuke/ryu,jkoelker/ryu,pichuang/ryu,lagopus/ryu-lagopus-ext,hisaharu/ryu,lsqtongxin/ryu,iwaseyusuke/ryu,Zouyiran/ryu,yamt/ryu,ttsubo/ryu,fujita/ryu,iwaseyusuke/ryu,StephenKing/ryu,hisaharu/ryu,jkoelker/ryu,ysywh/ryu,jazzmes/ryu,lzppp/mylearning,ynkjm/ryu,Zouyiran/ryu,haniehrajabi/ryu,John-Lin/ryu,osrg/ryu,alyosha1879/ryu,jalilm/ryu,gopchandani/ryu,John-Lin/ryu,lsqtongxin/ryu,castroflavio/ryu,elahejalalpour/ELRyu,muzixing/ryu,elahejalalpour/ELRyu,jazzmes/ryu,fujita/ryu,lsqtongxin/ryu,Zouyiran/ryu,muzixing/ryu