asMap method

Map asMap()

Map asMap() is a method that returns a Map representation of the ClientAccountRegisterContext object. It includes all the properties of the object as key-value pairs in the returned Map. If a property is null, it will not be included in the returned Map. The agreements property is converted to a Map using its own asMap() method, and the attributes property is included as is.

Implementation

Map asMap() => {
      'email': email,
      'password': password,
      'firstName': firstName,
      'lastName': lastName,
      'sex': sex,
      'phone': phone,
      'company': company,
      'address': address,
      'city': city,
      'zipcode': zipcode,
      'countrycode': countrycode,
      'province': province,
      'uuid': uuid,
      'customId': customId,
      'agreements': agreements?.asMap(),
      'attributes': attributes
    };