toString method

  1. @override
String toString()
override

A string representation of this object.

Some classes have a default textual representation, often paired with a static parse function (like int.parse). These classes will provide the textual representation as their string representation.

Other classes have no meaningful textual representation that a program will care about. Such classes will typically override toString to provide useful information when inspecting the object, mainly for debugging or logging.

Implementation

@override
String toString() {
  final $buf = StringBuffer()..writeln('TokenPerson(');
  if (additionalTosAcceptances != null) {
    $buf
      ..writeln()
      ..write('  additional_tos_acceptances: ')
      ..write(additionalTosAcceptances)
      ..write(',');
  }
  if (address != null) {
    $buf
      ..writeln()
      ..write('  address: ')
      ..write(address)
      ..write(',');
  }
  if (addressKana != null) {
    $buf
      ..writeln()
      ..write('  address_kana: ')
      ..write(addressKana)
      ..write(',');
  }
  if (addressKanji != null) {
    $buf
      ..writeln()
      ..write('  address_kanji: ')
      ..write(addressKanji)
      ..write(',');
  }
  if (dob != null) {
    $buf
      ..writeln()
      ..write('  dob: ')
      ..write(dob)
      ..write(',');
  }
  if (documents != null) {
    $buf
      ..writeln()
      ..write('  documents: ')
      ..write(documents)
      ..write(',');
  }
  if (email != null) {
    $buf
      ..writeln()
      ..write('  email: ')
      ..write(email)
      ..write(',');
  }
  if (firstName != null) {
    $buf
      ..writeln()
      ..write('  first_name: ')
      ..write(firstName)
      ..write(',');
  }
  if (firstNameKana != null) {
    $buf
      ..writeln()
      ..write('  first_name_kana: ')
      ..write(firstNameKana)
      ..write(',');
  }
  if (firstNameKanji != null) {
    $buf
      ..writeln()
      ..write('  first_name_kanji: ')
      ..write(firstNameKanji)
      ..write(',');
  }
  if (fullNameAliases != null) {
    $buf
      ..writeln()
      ..write('  full_name_aliases: ')
      ..write(fullNameAliases)
      ..write(',');
  }
  if (gender != null) {
    $buf
      ..writeln()
      ..write('  gender: ')
      ..write(gender)
      ..write(',');
  }
  if (idNumber != null) {
    $buf
      ..writeln()
      ..write('  id_number: ')
      ..write(idNumber)
      ..write(',');
  }
  if (idNumberSecondary != null) {
    $buf
      ..writeln()
      ..write('  id_number_secondary: ')
      ..write(idNumberSecondary)
      ..write(',');
  }
  if (lastName != null) {
    $buf
      ..writeln()
      ..write('  last_name: ')
      ..write(lastName)
      ..write(',');
  }
  if (lastNameKana != null) {
    $buf
      ..writeln()
      ..write('  last_name_kana: ')
      ..write(lastNameKana)
      ..write(',');
  }
  if (lastNameKanji != null) {
    $buf
      ..writeln()
      ..write('  last_name_kanji: ')
      ..write(lastNameKanji)
      ..write(',');
  }
  if (maidenName != null) {
    $buf
      ..writeln()
      ..write('  maiden_name: ')
      ..write(maidenName)
      ..write(',');
  }
  if (metadata != null) {
    $buf
      ..writeln()
      ..write('  metadata: ')
      ..write(metadata)
      ..write(',');
  }
  if (nationality != null) {
    $buf
      ..writeln()
      ..write('  nationality: ')
      ..write(nationality)
      ..write(',');
  }
  if (phone != null) {
    $buf
      ..writeln()
      ..write('  phone: ')
      ..write(phone)
      ..write(',');
  }
  if (politicalExposure != null) {
    $buf
      ..writeln()
      ..write('  political_exposure: ')
      ..write(politicalExposure)
      ..write(',');
  }
  if (registeredAddress != null) {
    $buf
      ..writeln()
      ..write('  registered_address: ')
      ..write(registeredAddress)
      ..write(',');
  }
  if (relationship != null) {
    $buf
      ..writeln()
      ..write('  relationship: ')
      ..write(relationship)
      ..write(',');
  }
  if (ssnLast4 != null) {
    $buf
      ..writeln()
      ..write('  ssn_last_4: ')
      ..write(ssnLast4)
      ..write(',');
  }
  if (verification != null) {
    $buf
      ..writeln()
      ..write('  verification: ')
      ..write(verification)
      ..write(',');
  }
  $buf.write(')');
  return $buf.toString();
}