encode method

void encode(
  1. KeyedArchive object
)
override

Implementation

void encode(KeyedArchive object) {
  super.encode(object);

  if (title == null || version == null) {
    throw new ArgumentError(
        "APIInfo must have non-null values for: 'title', 'version'.");
  }

  object.encode("title", title);
  object.encode("description", description);
  object.encode("version", version);
  object.encode("termsOfService", termsOfServiceURL);
  object.encodeObject("contact", contact);
  object.encodeObject("license", license);
}