0

When i open my default model class (ErrorViewModel) i found => operator. What is that actually ? What is the use of it ?

using System;

namespace MvcCoreApp.Models
{
    public class ErrorViewModel
    {
        public string RequestId { get; set; }

        public bool ShowRequestId => !string.IsNullOrEmpty(RequestId);
    }
}

What is the use of this => operator here ?

Lazy Programer
  • 171
  • 1
  • 1
  • 12
  • (Expression-bodied members)[https://learn.microsoft.com/en-us/dotnet/csharp/programming-guide/statements-expressions-operators/expression-bodied-members] – tchelidze Mar 18 '20 at 07:35
  • @tchelidze Your link has no data, And i searched for 'Expression-bodied members' and got enough details. Thanks – Lazy Programer Mar 18 '20 at 07:51

0 Answers0