1234567891011121314151617181920212223242526272829 |
- using System;
- using System.Collections.Generic;
- using System.Runtime.Serialization;
- namespace WingServerCommon.Config.Parameters
- {
- /// <summary>
- /// string enum parameter
- /// </summary>
- [DataContract]
- public class EnumStringParameter : EnumParameterBase<string>
- {
- public override void ChangeParameterValue(object value)
- {
- var stringParameter = value as StringParameter;
- if (stringParameter != null)
- {
- Value = stringParameter.Value;
- }
- }
- public void ChangeSource(IEnumerable<string> newSource, string defaultValue)
- {
- Source = new List<string>(newSource);
- Value = defaultValue;
- }
- }
- }
|