Ejemplo n.º 1
0
        private ArgumentInfo(
            AppSettings settings,
            ICustomAttributeProvider attributeProvider,
            string propertyOrArgumentName,
            Type type,
            object defaultValue)
        {
            Settings = settings;

            AttributeProvider      = attributeProvider;
            PropertyOrArgumentName = propertyOrArgumentName;
            Type         = type;
            DefaultValue = defaultValue;

            IsMultipleType = GetIsMultipleType();
            UnderlyingType = GetUnderlyingType(Type);

            _typeDescriptor = Settings.ArgumentTypeDescriptors
                              .GetDescriptorOrThrow(UnderlyingType);
        }
Ejemplo n.º 2
0
 public ListParser(Type type, Type underlyingType, IArgumentTypeDescriptor argumentTypeDescriptor)
 {
     _type                   = type;
     _underlyingType         = underlyingType;
     _argumentTypeDescriptor = argumentTypeDescriptor;
 }
 public ErrorReportingDescriptor(IArgumentTypeDescriptor innerDescriptor)
 {
     _innerDescriptor = innerDescriptor;
 }
Ejemplo n.º 4
0
 /// <summary>Registers your customer descriptor</summary>
 public void Add(IArgumentTypeDescriptor argumentTypeDescriptor)
 {
     _customDescriptors.Add(new ErrorReportingDescriptor(argumentTypeDescriptor));
 }
 public SingleValueParser(IArgumentTypeDescriptor argumentTypeDescriptor)
 {
     _argumentTypeDescriptor = argumentTypeDescriptor;
 }
Ejemplo n.º 6
0
 public void Add(IArgumentTypeDescriptor argumentTypeDescriptor)
 {
     _customDescriptors.Add(argumentTypeDescriptor);
 }