encode<V> static method

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

Implementation

static V encode<V>(
  PersonalizationDesignsPreferences instance,
  Encoder<V> encoder,
) {
  final container = encoder.container<String>();
  if (instance.isDefault != null) {
    container.encodeBool(
      'is_default',
      instance.isDefault!,
    );
  }
  if (instance.isPlatformDefault != null) {
    container.encodeBool(
      'is_platform_default',
      instance.isPlatformDefault!,
    );
  }
  return container.value;
}