Beispiel #1
0
        public async Task <MathParts> Put(int id, [FromBody] MathParts values)
        {
            await Task.Delay(1000);

            return(new MathParts()
            {
                x = values.x / id,
                y = values.y
            });
        }
Beispiel #2
0
        public async Task <double> Post([FromBody] MathParts values)
        {
            await Task.Delay(1000);

            return((double)values.x / (double)values.y);
        }
Beispiel #3
0
 public int Operations(MathOperation id, [FromBody] MathParts data)
 {
     return(data.x / data.y);
 }
Beispiel #4
0
 public int Divide([FromBody] MathParts data)
 {
     return(data.x / data.y);
 }
Beispiel #5
0
 public int  Add([FromBody] MathParts data)
 {
     return(data.x + data.y);
 }
Beispiel #6
0
 public MathParts Operation(MathOperation id, int x, [FromBody] MathParts data)
 {
     return(ExecuteOperation(id, x, data));
 }
Beispiel #7
0
 private MathParts ExecuteOperation(MathOperation op, int x, MathParts data)
 {
     return(null);
 }