def flag_color=(flag_color)
      validator = EnumAttributeValidator.new('String', ['red', 'orange', 'yellow', 'green', 'blue', 'purple'])
      unless validator.valid?(flag_color)
        fail ArgumentError, 'invalid value for "flag_color", must be one of #{validator.allowable_values}.'
      end
      @flag_color = flag_color
    end
def flag_color=(flag_color)
      validator = EnumAttributeValidator.new('String', ['red', 'orange', 'yellow', 'green', 'blue', 'purple'])
      unless validator.valid?(flag_color)
        fail ArgumentError, 'invalid value for "flag_color", must be one of #{validator.allowable_values}.'
      end
      @flag_color = flag_color
    end
Custom attribute writer method checking allowed values (enum).
 @param [Object] flag_color Object to be assigned