original_docstring: Build IPv6 ACL match data with hexstring format.
  
          :param int nh: next header number with valid option "x"
          :param str src_ip: source ip6 address with format of "xxx:xxxx::xxxx"
          :param str dst_ip: destination ip6 address with format of
              "xxx:xxxx::xxxx"
          :param int src_port: source port number "x"
          :param int dst_port: destination port number "x"
          
docstring: Build IPv6 ACL match data with hexstring format.
docstring_tokens: Build IPv6 ACL match data with hexstring format .
code: def build_ip6_match(nh=0, src_ip='', dst_ip='',
                          src_port=0, dst_port=0):
          """Build IPv6 ACL match data with hexstring format.
  
          :param int nh: next header number with valid option "x"
          :param str src_ip: source ip6 address with format of "xxx:xxxx::xxxx"
          :param str dst_ip: destination ip6 address with format of
              "xxx:xxxx::xxxx"
          :param int src_port: source port number "x"
          :param int dst_port: destination port number "x"
          """
          if src_ip:
              if sys.version_info[0] == 2:
                  src_ip = binascii.hexlify(socket.inet_pton(
                      socket.AF_INET6, src_ip))
              else:
                  src_ip = socket.inet_pton(socket.AF_INET6, src_ip).hex()
  
          if dst_ip:
              if sys.version_info[0] == 2:
                  dst_ip = binascii.hexlify(socket.inet_pton(
                      socket.AF_INET6, dst_ip))
              else:
                  dst_ip = socket.inet_pton(socket.AF_INET6, dst_ip).hex()
  
          return ('{!s:0>14}{!s:0>34}{!s:0>32}{!s:0>4}{!s:0>4}'.format(
              hex(nh)[2:], src_ip, dst_ip, hex(src_port)[2:],
              hex(dst_port)[2:])).rstrip('0')
code_tokens: def build_ip6_match ( nh = 0 , src_ip = '' , dst_ip = '' , src_port = 0 , dst_port = 0 ) : if src_ip : if sys . version_info [ 0 ] == 2 : src_ip = binascii . hexlify ( socket . inet_pton ( socket . AF_INET6 , src_ip ) ) else : src_ip = socket . inet_pton ( socket . AF_INET6 , src_ip ) . hex ( ) if dst_ip : if sys . version_info [ 0 ] == 2 : dst_ip = binascii . hexlify ( socket . inet_pton ( socket . AF_INET6 , dst_ip ) ) else : dst_ip = socket . inet_pton ( socket . AF_INET6 , dst_ip ) . hex ( ) return ( '{!s:0>14}{!s:0>34}{!s:0>32}{!s:0>4}{!s:0>4}' . format ( hex ( nh ) [ 2 : ] , src_ip , dst_ip , hex ( src_port ) [ 2 : ] , hex ( dst_port ) [ 2 : ] ) ) . rstrip ( '0' )
short_docstring: Build IPv6 ACL match data with hexstring format.
short_docstring_tokens: Build IPv6 ACL match data with hexstring format .
comment: """Build IPv6 ACL match data with hexstring format.
  
          :param int nh: next header number with valid option "x"
          :param str src_ip: source ip6 address with format of "xxx:xxxx::xxxx"
          :param str dst_ip: destination ip6 address with format of
              "xxx:xxxx::xxxx"
          :param int src_port: source port number "x"
          :param int dst_port: destination port number "x"
          """