Skip to content

Commit c3dbdd9

Browse files
Denis-AverinIvan Kamkin
andauthored
Release 24.6 (#89)
* Version of SDK updated * Use the latest SDK in Makefile for test * EnforceCodeStyleInBuild --------- Co-authored-by: Ivan Kamkin <[email protected]>
1 parent b991d3f commit c3dbdd9

File tree

11 files changed

+34
-16
lines changed

11 files changed

+34
-16
lines changed

Makefile

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
LATEST_SDK_VERSION=$(shell dotnet --list-sdks | awk -F. '{print $$1 "." $$2}' | sort -n | tail -n 1)
2+
13
.PHONY: all
24
all: test
35

@@ -18,7 +20,11 @@ format-doc:
1820

1921
.PHONY: test
2022
test:
21-
dotnet test
23+
dotnet test -v normal --framework=net$(LATEST_SDK_VERSION)
24+
25+
.PHONY: build
26+
build:
27+
dotnet build -v normal --framework=net$(LATEST_SDK_VERSION)
2228

2329
.PHONY: insert-examples
2430
insert-examples:
@@ -34,7 +40,7 @@ update:
3440

3541
.PHONY: lint
3642
lint:
37-
dotnet build --warnaserror Aspose.BarCode.Cloud.Sdk.sln
43+
dotnet build --warnaserror Aspose.BarCode.Cloud.Sdk.sln --framework=net$(LATEST_SDK_VERSION)
3844

3945
.PHONY: clean
4046
clean:

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
[![Nuget](https://img.shields.io/nuget/v/Aspose.BarCode-Cloud)](https://www.nuget.org/packages/Aspose.BarCode-Cloud/)
77

88
- API version: 3.0
9-
- SDK version: 24.5.0
9+
- SDK version: 24.6.0
1010

1111
## Demo applications
1212

examples/GenerateQR/GenerateQR.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
</PropertyGroup>
88

99
<ItemGroup>
10-
<PackageReference Include="Aspose.BarCode-Cloud" Version="24.5.0" />
10+
<PackageReference Include="Aspose.BarCode-Cloud" Version="24.6.0" />
1111
</ItemGroup>
1212

1313
</Project>

examples/ReadQR/ReadQR.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
</PropertyGroup>
88

99
<ItemGroup>
10-
<PackageReference Include="Aspose.BarCode-Cloud" Version="24.5.0" />
10+
<PackageReference Include="Aspose.BarCode-Cloud" Version="24.6.0" />
1111
</ItemGroup>
1212

1313
</Project>

src/Api/BarcodeApi.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -861,7 +861,7 @@ public async Task<BarcodeResponseList> ScanBarcodeAsync(ScanBarcodeRequest reque
861861
}
862862
if (request.timeout != null)
863863
{
864-
formParams.Add(new StringContent(request.timeout.ToString()), "timeout");
864+
formParams.Add(new StringContent($"{request.timeout}"), "timeout");
865865
}
866866
string response = await _apiInvoker.InvokeApiAsync(
867867
resourcePath,

src/Api/Configuration.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
using System;
12
using System.Collections.Generic;
23
using Newtonsoft.Json;
34
using Newtonsoft.Json.Converters;
@@ -90,7 +91,7 @@ public string GetApiRootUrl()
9091
{
9192
string result = ApiBaseUrl + "/v" + ApiVersion;
9293

93-
return result.EndsWith("/") ? result.Substring(0, result.Length - 1) : result;
94+
return result.EndsWith("/", StringComparison.InvariantCulture) ? result.Substring(0, result.Length - 1) : result;
9495
}
9596

9697
private string _jwtToken;

src/Aspose.BarCode.Cloud.Sdk.csproj

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
<PropertyGroup>
44
<TargetFrameworks>netstandard2.0</TargetFrameworks>
55
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
6+
<EnforceCodeStyleInBuild>true</EnforceCodeStyleInBuild>
7+
<AnalysisLevel>latest-Recommended</AnalysisLevel>
8+
69
<Company>Aspose</Company>
710
<Title>Aspose.BarCode Cloud SDK for .NET</Title>
811
<Description>Aspose.Barcode for Cloud is a REST API for barcode generation and recognition. It helps you generate barcode images from scratch in linear (1D), two dimensional (2D), and postal formats. Generate barcode images in a variety of image formats: JPEG, PNG, GIF, BMP, TIFF and SVG. Recognize barcodes from different image types.
@@ -20,11 +23,11 @@ Aspose.Barcode for Cloud allows you to control all aspects of the image and barc
2023
<PackageId>Aspose.BarCode-Cloud</PackageId>
2124
<Product>Aspose.BarCode Cloud SDK for .NET</Product>
2225
<PackageIcon>PackageIcon.png</PackageIcon>
23-
<Version>24.5.0</Version>
26+
<Version>24.6.0</Version>
2427
<Authors>Aspose</Authors>
25-
<AssemblyVersion>24.5.0.0</AssemblyVersion>
28+
<AssemblyVersion>24.6.0.0</AssemblyVersion>
2629
<PackageReadmeFile>README.md</PackageReadmeFile>
27-
<PackageReleaseNotes>https://github.com/aspose-barcode-cloud/aspose-barcode-cloud-dotnet/releases/tag/v24.5.0</PackageReleaseNotes>
30+
<PackageReleaseNotes>https://github.com/aspose-barcode-cloud/aspose-barcode-cloud-dotnet/releases/tag/v24.6.0</PackageReleaseNotes>
2831
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
2932
<PackageLicenseFile>LICENSE.txt</PackageLicenseFile>
3033
<GenerateDocumentationFile>true</GenerateDocumentationFile>

src/GlobalSuppressions.cs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
// This file is used by Code Analysis to maintain SuppressMessage
2+
// attributes that are applied to this project.
3+
// Project-level suppressions either have no target or are given
4+
// a specific target and scoped to a namespace, type, member, etc.
5+
6+
using System.Diagnostics.CodeAnalysis;
7+
8+
[assembly: SuppressMessage("Naming", "CA1716:Identifiers should not match keywords", Justification = "<Pending>", Scope = "type", Target = "~T:Aspose.BarCode.Cloud.Sdk.Model.Error")]
9+
[assembly: SuppressMessage("Naming", "CA1707:Identifiers should not contain underscores", Justification = "<Pending>", Scope = "namespaceanddescendants", Target = "~N:Aspose.BarCode.Cloud.Sdk.Model")]

src/Internal/ApiInvoker.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ public string InvokeApi(
4949
private static byte[] GetMultipartFormData(Dictionary<string, object> postParameters, string boundary)
5050
{
5151
// TODO: stream is not disposed
52-
Stream formDataStream = new MemoryStream();
52+
MemoryStream formDataStream = new MemoryStream();
5353
var needsCrlf = false;
5454

5555
if (postParameters.Count > 0)

src/Internal/RequestHandlers/DebugLogRequestHandler.cs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
using System;
21
using System.Collections.Specialized;
32
using System.Diagnostics;
43
using System.IO;
@@ -48,7 +47,7 @@ public void ProcessResponse(HttpWebResponse response, Stream resultStream)
4847
}
4948
}
5049

51-
private void LogRequest(WebRequest request, Stream streamToSend)
50+
private static void LogRequest(WebRequest request, Stream streamToSend)
5251
{
5352
var header = $"{request.Method}: {request.RequestUri}";
5453
var sb = new StringBuilder();
@@ -116,7 +115,7 @@ public async Task ProcessResponseAsync(HttpResponseMessage response)
116115
}
117116
}
118117

119-
private async Task LogRequestAsync(HttpRequestMessage request)
118+
private static async Task LogRequestAsync(HttpRequestMessage request)
120119
{
121120
var header = $"{request.Method}: {request.RequestUri}";
122121
var sb = new StringBuilder();
@@ -132,7 +131,7 @@ private async Task LogRequestAsync(HttpRequestMessage request)
132131
Log(header, sb);
133132
}
134133

135-
private async Task LogResponseAsync(HttpResponseMessage response)
134+
private static async Task LogResponseAsync(HttpResponseMessage response)
136135
{
137136
var header = $"\r\nResponse {(int)response.StatusCode}: {response.StatusCode}";
138137
var sb = new StringBuilder();

0 commit comments

Comments
 (0)