samples/client/petstore/csharp-dotnet2/SwaggerClientTest/Lib/SwaggerClient/src/main/CsharpDotNet2/IO/Swagger/Api/PetApi.cs
/// <summary>
/// Finds Pets by tags Muliple tags can be provided with comma separated strings. Use\\ \\ tag1, tag2, tag3 for testing.
/// </summary>
/// <param name="tags">Tags to filter by</param>
/// <returns>List&lt;Pet&gt;</returns>
Finds Pets by tags Muliple tags can be provided with comma separated strings. Use\\ \\ tag1, tag2, tag3 for testing.
Finds Pets by tags Muliple tags can be provided with comma separated strings . Use \\ \\ tag1 tag2 tag3 for testing .
public List<Pet> FindPetsByTags (List<string> tags)
        {
            if (tags == null) throw new ApiException(400, "Missing required parameter 'tags' when calling FindPetsByTags");
            var path = "/pet/findByTags";
            path = path.Replace("{format}", "json");
            var queryParams = new Dictionary<String, String>();
            var headerParams = new Dictionary<String, String>();
            var formParams = new Dictionary<String, String>();
            var fileParams = new Dictionary<String, FileParameter>();
            String postBody = null;
             if (tags != null) queryParams.Add("tags", ApiClient.ParameterToString(tags)); 
            String[] authSettings = new String[] { "petstore_auth" };
            IRestResponse response = (IRestResponse) ApiClient.CallApi(path, Method.GET, queryParams, postBody, headerParams, formParams, fileParams, authSettings);
            if (((int)response.StatusCode) >= 400)
                throw new ApiException ((int)response.StatusCode, "Error calling FindPetsByTags: " + response.Content, response.Content);
            else if (((int)response.StatusCode) == 0)
                throw new ApiException ((int)response.StatusCode, "Error calling FindPetsByTags: " + response.ErrorMessage, response.ErrorMessage);
            return (List<Pet>) ApiClient.Deserialize(response.Content, typeof(List<Pet>), response.Headers);
        }
public List < Pet > FindPetsByTags ( List < string > tags ) { if ( tags == null ) throw new ApiException ( 400 , " " ) ; var path = " " ; path = path . Replace ( " " , " " ) ; var queryParams = new Dictionary < String , String > ( ) ; var headerParams = new Dictionary < String , String > ( ) ; var formParams = new Dictionary < String , String > ( ) ; var fileParams = new Dictionary < String , FileParameter > ( ) ; String postBody = null ; if ( tags != null ) queryParams . Add ( " " , ApiClient . ParameterToString ( tags ) ) ; String [ ] authSettings = new String [ ] { " " } ; IRestResponse response = ( IRestResponse ) ApiClient . CallApi ( path , Method . GET , queryParams , postBody , headerParams , formParams , fileParams , authSettings ) ; if ( ( ( int ) response . StatusCode ) >= 400 ) throw new ApiException ( ( int ) response . StatusCode , " " + response . Content , response . Content ) ; else if ( ( ( int ) response . StatusCode ) == 0 ) throw new ApiException ( ( int ) response . StatusCode , " " + response . ErrorMessage , response . ErrorMessage ) ; return ( List < Pet > ) ApiClient . Deserialize ( response . Content , typeof ( List < Pet > ) , response . Headers ) ; }
Finds Pets by tags Muliple tags can be provided with comma separated strings.
Finds Pets by tags Muliple tags can be provided with comma separated strings .
// verify the required parameter 'tags' is set // query parameter // authentication setting, if any // make the HTTP request
None
tags
List<string>
Tags to filter by
Tags to filter by