packet lib: ipv6: fix reversibility about json
packet lib: ipv6: fix reversibility about json

although IPv6 is using internal classes, no class is registered into '_class_prefixes'.
therefore, AssertionError occurs in from_jsondict() when the argument 'ext_hdrs' was processed.
this patch makes from_jsondict() to work correctly by registering internal classes into '_class_prefixes'.

examination code:

    from ryu.lib.packet import ipv6
    msg1 = ipv6.ipv6(ext_hdrs=[ipv6.hop_opts()])
    print msg1
    jsondict = msg1.to_jsondict()
    msg2 = ipv6.ipv6.from_jsondict(jsondict['ipv6'])
    print msg2
    print str(msg1) == str(msg2)

before applying this patch:

    ipv6(dst='::',ext_hdrs=[hop_opts(data=None,nxt=6,size=0)],flow_label=0,hop_limit=255,nxt=6,payload_length=0,src='::',traffic_class=0,version=6)
    Traceback (most recent call last):
      File "<stdin>", line 1, in <module>
      File "/usr/local/lib/python2.7/dist-packages/ryu/lib/stringify.py", line 293, in from_jsondict
        return cls(**dict(kwargs, **additional_args))
      File "/usr/local/lib/python2.7/dist-packages/ryu/lib/packet/ipv6.py", line 86, in __init__
        assert isinstance(ext_hdr, header)
    AssertionError

after applying this patch:

    ipv6(dst='::',ext_hdrs=[hop_opts(data=None,nxt=6,size=0)],flow_label=0,hop_limit=255,nxt=6,payload_length=0,src='::',traffic_class=0,version=6)
    ipv6(dst='::',ext_hdrs=[hop_opts(data=None,nxt=6,size=0)],flow_label=0,hop_limit=255,nxt=6,payload_length=0,src='::',traffic_class=0,version=6)
    True

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

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