encodeImageRepeat static method

String? encodeImageRepeat(
  1. ImageRepeat? value
)

Encodes the given value into a String representation. Supported values are:

  • noRepeat
  • repeat
  • repeatX
  • repeatY

Implementation

static String? encodeImageRepeat(ImageRepeat? value) {
  String? result;

  if (value != null) {
    switch (value) {
      case ImageRepeat.noRepeat:
        result = 'noRepeat';
        break;
      case ImageRepeat.repeat:
        result = 'repeat';
        break;
      case ImageRepeat.repeatX:
        result = 'repeatX';
        break;
      case ImageRepeat.repeatY:
        result = 'repeatY';
        break;
    }
  }

  return result;
}