-
Notifications
You must be signed in to change notification settings - Fork 379
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #965 from flipm0de/support-methods-with-array-of-a…
…rray-params Added support for array of arrays parameters in methods and a test
- Loading branch information
Showing
3 changed files
with
54 additions
and
1 deletion.
There are no files selected for viewing
30 changes: 30 additions & 0 deletions
30
src/SoapCore.Tests/MessageContract/Models/IArrayOfArrayOfByteService.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
using System.ServiceModel; | ||
using System.Text; | ||
|
||
namespace SoapCore.Tests.MessageContract.Models | ||
{ | ||
[ServiceContract(Namespace = "http://tempuri.org")] | ||
public interface IArrayOfArrayOfByteService | ||
{ | ||
[OperationContract] | ||
string ArrayOfArrayOfByteMethod(byte[][] arrayOfArrayOfByteParam); | ||
} | ||
|
||
public class ArrayOfArrayOfByteService : IArrayOfArrayOfByteService | ||
{ | ||
public string ArrayOfArrayOfByteMethod(byte[][] arrayOfArrayOfByteParam) | ||
{ | ||
var ret = new StringBuilder(); | ||
ret.Append("["); | ||
foreach (var array in arrayOfArrayOfByteParam) | ||
{ | ||
ret.Append("["); | ||
ret.Append(string.Join(",", array)); | ||
ret.Append("]"); | ||
} | ||
|
||
ret.Append("]"); | ||
return ret.ToString(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters