encode<V> static method

V encode<V>(
  1. SessionCustomText instance,
  2. Encoder<V> encoder
)

Implementation

static V encode<V>(
  SessionCustomText instance,
  Encoder<V> encoder,
) {
  final container = encoder.container<String>();
  if (instance.afterSubmit != null) {
    SigmaScheduledQueryRunError.encode(
      instance.afterSubmit!,
      container.nestedSingleValueContainer('after_submit').encoder,
    );
  }
  if (instance.shippingAddress != null) {
    SigmaScheduledQueryRunError.encode(
      instance.shippingAddress!,
      container.nestedSingleValueContainer('shipping_address').encoder,
    );
  }
  if (instance.submit != null) {
    SigmaScheduledQueryRunError.encode(
      instance.submit!,
      container.nestedSingleValueContainer('submit').encoder,
    );
  }
  if (instance.termsOfServiceAcceptance != null) {
    SigmaScheduledQueryRunError.encode(
      instance.termsOfServiceAcceptance!,
      container
          .nestedSingleValueContainer('terms_of_service_acceptance')
          .encoder,
    );
  }
  return container.value;
}