Class: RASN2::Types::Set

Inherits:
Sequence show all
Defined in:
lib/rasn2/types/set.rb

Overview

ASN.1 set

A set is a collection of another ASN.1 types.

To encode this ASN.1 example: Record ::= SET { id INTEGER, room [0] INTEGER OPTIONAL, house [1] IMPLICIT INTEGER DEFAULT 0 } do: set = RASN2::Types::Set.new set.value = [ RASN2::Types::Integer RASN2::Types::Integer(explicit: 0, optional: true), RASN2::Types::Integer(implicit: 1, default: 0) ]

Author:

  • Sylvain Daubert

Constant Summary collapse

ID =

Set id value

0x11

Constants inherited from Constructed

Constructed::ASN1_PC

Constants inherited from Base

Base::CLASSES, Base::CLASS_MASK, Base::INDEFINITE_LENGTH, Base::MULTI_OCTETS_ID

Instance Attribute Summary

Attributes inherited from Base

#asn1_class, #default, #model, #name, #options

Method Summary

Methods inherited from Sequence

#[], #der_to_value, #der_to_value_with_tracing, #initialize, #initialize_copy, start_tracing, stop_tracing, #void_value

Methods inherited from Constructed

#can_build?

Methods inherited from Base

#==, #asn1_class_to_s, #attributes, #bin2hex, #build, #can_build?, #check_id, #colorize, #common_inspect, constrained?, #constructed?, #der2name, #der_to_value, #do_parse, #do_parse_explicit, #do_parse_explicit_with_tracing, #do_parse_with_tracing, #encode_identifier_octets, #encode_size, encoded_type, #explicit?, #explicit_type, #find_type, #get_data, #get_length, #id, #id2octets, #id_value, #implicit?, #indent, #initialize, #initialize_copy, #inspect, #inspect_value, #msg_type, #optional?, parse, #parse!, #pc_bit, #primitive?, #private?, #raise_id_error, #raise_on_indefinite_length, #self2name, #set_class, #set_default, #set_optional, #set_tag, #set_value, #specific_initializer, start_tracing, stop_tracing, #tag_id_to_integer, #tagged?, #to_der, #trace, #trace_data, #trace_real, #tracer, type, #type, #universal?, #unpack, #unsigned_to_chained_octets, #value, #value=, #value?, #value_size, #value_to_der, #void_value

Methods included from Helpers::Colorize

#begin_colorizer, #brace_surround, #colorize, #colorize_attribute, #colorize_bool, #colorize_class, #colorize_default, #colorize_enum, #colorize_id, #colorize_name, #colorize_nil, #colorize_value, #colorizer, #colorizer=, #end_colorizer, #int_with_hex, #length_specifier, #parens_hex

Constructor Details

This class inherits a constructor from RASN2::Types::Sequence