// Copyright (c) Microsoft Open Technologies, Inc. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
using System;
using Microsoft.AspNet.Mvc.ApplicationModels;
using Microsoft.Framework.Internal;
using Microsoft.Framework.Logging;
namespace Microsoft.AspNet.Mvc.Logging
{
///
/// Logging representation of a . Logged as a substructure of
/// , this contains the name, type, and
/// binder metadata of the property.
///
public class PropertyModelValues : ReflectionBasedLogValues
{
public PropertyModelValues([NotNull] PropertyModel inner)
{
PropertyName = inner.PropertyName;
PropertyType = inner.PropertyInfo.PropertyType;
}
///
/// The name of the property. See .
///
public string PropertyName { get; }
///
/// The of the property.
///
public Type PropertyType { get; }
public override string Format()
{
return LogFormatter.FormatLogValues(this);
}
}
}