public SimpleCalculatorController(ISimpleCalculatorService simpleCalcService)
 {
     _simpleCalcService = simpleCalcService;
 }
示例#2
0
 public APIGatewayProxyResponse Subtract([FromHeader] int x, [FromHeader] int y, [FromServices] ISimpleCalculatorService simpleCalculatorService)
 {
     return(new APIGatewayProxyResponse
     {
         StatusCode = 200,
         Body = simpleCalculatorService.Subtract(x, y).ToString()
     });
 }
示例#3
0
 public double Pi([FromServices] ISimpleCalculatorService simpleCalculatorService)
 {
     return(simpleCalculatorService.PI());
 }
示例#4
0
 /// <summary>
 /// Default constructor that Lambda will invoke.
 /// </summary>
 public SimpleCalculator(ISimpleCalculatorService simpleCalculatorService)
 {
     this._simpleCalculatorService = simpleCalculatorService;
 }