ASN1IpAddress constructor

ASN1IpAddress(
  1. List<int> octets, {
  2. int tag = IP_ADDRESS,
})

Create an ASN1IpAddress initialized with a String or a List<int>. Optionally override the tag

Implementation

ASN1IpAddress(List<int> octets, {int tag = IP_ADDRESS})
    : super(octets, tag: tag) {
  _assertValidLength(this.octets);
  for (var o in octets) {
    if (0 > o || o > 255) {
      throw ArgumentError('Octet out of range!.');
    }
  }
}