encode<V> static method

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

Implementation

static V encode<V>(
  SessionP24 instance,
  Encoder<V> encoder,
) {
  final container = encoder.container<String>();
  if (instance.setupFutureUsage != null) {
    container.encodeString(
      'setup_future_usage',
      'none',
    );
  }
  if (instance.tosShownAndAccepted != null) {
    container.encodeBool(
      'tos_shown_and_accepted',
      instance.tosShownAndAccepted!,
    );
  }
  return container.value;
}