Skip to content

Commit 64bbbc0

Browse files
committed
Merge remote-tracking branch 'upstream/master' into patch-1
2 parents b20f6be + 94670d7 commit 64bbbc0

File tree

142 files changed

+3155
-936
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

142 files changed

+3155
-936
lines changed

.travis.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,5 +36,4 @@ env:
3636
# git update-index --chmod=+x build.sh
3737
script:
3838
# Skip running tests due to tooling bug https://github.com/dotnet/cli/issues/3073
39-
- ./build.sh --target RunTool
4039
- ./build.sh

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -143,3 +143,4 @@ This magic is all carried out using the `Value<T>`, `Value<T1, T2>`, `Value<T1,
143143
## Contributions and Thanks
144144

145145
- [psampaio](https://github.com/psampaio) - Added deserialization support and unit tests.
146+
- [icunningham88](https://github.com/icunningham88) - Improved a test.

Source/Schema.NET.Tool/Schema.NET.Tool.csproj

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22

33
<PropertyGroup Label="Build">
44
<OutputType>Exe</OutputType>
5-
<TargetFramework>netcoreapp2.0</TargetFramework>
5+
<TargetFramework>netcoreapp2.1</TargetFramework>
66
<CodeAnalysisRuleSet>../../MinimumRecommendedRulesWithStyleCop.ruleset</CodeAnalysisRuleSet>
77
<IsPackable>false</IsPackable>
88
<LangVersion>latest</LangVersion>
99
</PropertyGroup>
1010

1111
<ItemGroup Label="Package References">
12-
<PackageReference Include="Newtonsoft.Json" Version="10.0.3" />
13-
<PackageReference Include="StyleCop.Analyzers" PrivateAssets="All" Version="1.1.0-beta004" />
12+
<PackageReference Include="Newtonsoft.Json" Version="11.0.2" />
13+
<PackageReference Include="StyleCop.Analyzers" PrivateAssets="all" Version="1.1.0-beta009" />
1414
</ItemGroup>
1515

1616
</Project>

Source/Schema.NET.Tool/Services/SchemaService.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -268,6 +268,8 @@ private static Class TranslateClass(
268268
})
269269
.Where(x => x.Types.Count > 0)
270270
.OrderBy(x => x.Name, new PropertyNameComparer())
271+
.GroupBy(x => x.Name) // Remove duplicates.
272+
.Select(x => x.First())
271273
.ToList();
272274
@class.Properties.AddRange(properties);
273275
return @class;

Source/Schema.NET/Schema.NET.csproj

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,16 @@
1-
<Project Sdk="Microsoft.NET.Sdk">
1+
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup Label="Build">
4-
<TargetFramework>netstandard1.1</TargetFramework>
4+
<TargetFrameworks>netstandard1.1;netstandard2.0</TargetFrameworks>
5+
<NoWarn>$(NoWarn);SA1629</NoWarn>
56
<CodeAnalysisRuleSet>../../MinimumRecommendedRulesWithStyleCop.ruleset</CodeAnalysisRuleSet>
67
<GenerateDocumentationFile>true</GenerateDocumentationFile>
78
<LangVersion>latest</LangVersion>
89
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
910
</PropertyGroup>
1011

1112
<PropertyGroup Label="Package">
12-
<VersionPrefix>3.4.0</VersionPrefix>
13+
<VersionPrefix>3.5.0</VersionPrefix>
1314
<Authors>Muhammad Rehan Saeed (RehanSaeed.com)</Authors>
1415
<Product>Schema.NET</Product>
1516
<Description>Schema.org objects turned into strongly typed C# POCO classes for use in .NET. All classes can be serialized into JSON/JSON-LD and XML, typically used to represent structured data in the head section of html page.</Description>
@@ -31,8 +32,8 @@
3132
</PropertyGroup>
3233

3334
<ItemGroup Label="Package References">
34-
<PackageReference Include="Newtonsoft.Json" Version="10.0.3" />
35-
<PackageReference Include="StyleCop.Analyzers" PrivateAssets="All" Version="1.1.0-beta004" />
35+
<PackageReference Include="Newtonsoft.Json" Version="11.0.2" />
36+
<PackageReference Include="StyleCop.Analyzers" PrivateAssets="all" Version="1.1.0-beta009" />
3637
</ItemGroup>
3738

3839
</Project>

Source/Schema.NET/auto/BusOrCoach.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ public partial class BusOrCoach : Vehicle
2424
public OneOrMany<string>? AcrissCode { get; set; }
2525

2626
/// <summary>
27-
/// &lt;p&gt;The permitted total weight of cargo and installations (e.g. a roof rack) on top of the vehicle.&lt;/p&gt;
28-
/// &lt;p&gt;Typical unit code(s): KGM for kilogram, LBR for pound&lt;/p&gt;
27+
/// The permitted total weight of cargo and installations (e.g. a roof rack) on top of the vehicle.&lt;br/&gt;&lt;br/&gt;
28+
/// Typical unit code(s): KGM for kilogram, LBR for pound&lt;br/&gt;&lt;br/&gt;
2929
/// &lt;ul&gt;
3030
/// &lt;li&gt;Note 1: You can indicate additional information in the &lt;a class="localLink" href="http://schema.org/name"&gt;name&lt;/a&gt; of the &lt;a class="localLink" href="http://schema.org/QuantitativeValue"&gt;QuantitativeValue&lt;/a&gt; node.&lt;/li&gt;
3131
/// &lt;li&gt;Note 2: You may also link to a &lt;a class="localLink" href="http://schema.org/QualitativeValue"&gt;QualitativeValue&lt;/a&gt; node that provides additional information using &lt;a class="localLink" href="http://schema.org/valueReference"&gt;valueReference&lt;/a&gt;&lt;/li&gt;

Source/Schema.NET/core/AcceptAction.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ namespace Schema.NET
55
using Newtonsoft.Json;
66

77
/// <summary>
8-
/// &lt;p&gt;The act of committing to/adopting an object.&lt;/p&gt;
9-
/// &lt;p&gt;Related actions:&lt;/p&gt;
8+
/// The act of committing to/adopting an object.&lt;br/&gt;&lt;br/&gt;
9+
/// Related actions:&lt;br/&gt;&lt;br/&gt;
1010
/// &lt;ul&gt;
1111
/// &lt;li&gt;&lt;a class="localLink" href="http://schema.org/RejectAction"&gt;RejectAction&lt;/a&gt;: The antonym of AcceptAction.&lt;/li&gt;
1212
/// &lt;/ul&gt;

Source/Schema.NET/core/Accommodation.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ public partial class Accommodation : Place
3535
public OneOrMany<QuantitativeValue>? FloorSize { get; set; }
3636

3737
/// <summary>
38-
/// The number of rooms (excluding bathrooms and closets) of the acccommodation or lodging business.
38+
/// The number of rooms (excluding bathrooms and closets) of the accommodation or lodging business.
3939
/// Typical unit code(s): ROM for room or C62 for no unit. The type of room can be put in the unitText property of the QuantitativeValue.
4040
/// </summary>
4141
[DataMember(Name = "numberOfRooms", Order = 208)]

Source/Schema.NET/core/AccountingService.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ namespace Schema.NET
55
using Newtonsoft.Json;
66

77
/// <summary>
8-
/// Accountancy business.&lt;/p&gt;
9-
/// &lt;p&gt;As a &lt;a class="localLink" href="http://schema.org/LocalBusiness"&gt;LocalBusiness&lt;/a&gt; it can be described as a &lt;a class="localLink" href="http://schema.org/provider"&gt;provider&lt;/a&gt; of one or more &lt;a class="localLink" href="http://schema.org/Service"&gt;Service&lt;/a&gt;(s).
8+
/// Accountancy business.&lt;br/&gt;&lt;br/&gt;
9+
/// As a &lt;a class="localLink" href="http://schema.org/LocalBusiness"&gt;LocalBusiness&lt;/a&gt; it can be described as a &lt;a class="localLink" href="http://schema.org/provider"&gt;provider&lt;/a&gt; of one or more &lt;a class="localLink" href="http://schema.org/Service"&gt;Service&lt;/a&gt;(s).
1010
/// </summary>
1111
[DataContract]
1212
public partial class AccountingService : FinancialService

Source/Schema.NET/core/Action.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ namespace Schema.NET
55
using Newtonsoft.Json;
66

77
/// <summary>
8-
/// An action performed by a direct agent and indirect participants upon a direct object. Optionally happens at a location with the help of an inanimate instrument. The execution of the action may produce a result. Specific action sub-type documentation specifies the exact expectation of each argument/role.&lt;/p&gt;
9-
/// &lt;p&gt;See also &lt;a href="http://blog.schema.org/2014/04/announcing-schemaorg-actions.html"&gt;blog post&lt;/a&gt; and &lt;a href="http://schema.org/docs/actions.html"&gt;Actions overview document&lt;/a&gt;.
8+
/// An action performed by a direct agent and indirect participants upon a direct object. Optionally happens at a location with the help of an inanimate instrument. The execution of the action may produce a result. Specific action sub-type documentation specifies the exact expectation of each argument/role.&lt;br/&gt;&lt;br/&gt;
9+
/// See also &lt;a href="http://blog.schema.org/2014/04/announcing-schemaorg-actions.html"&gt;blog post&lt;/a&gt; and &lt;a href="http://schema.org/docs/actions.html"&gt;Actions overview document&lt;/a&gt;.
1010
/// </summary>
1111
[DataContract]
1212
public partial class Action : Thing
@@ -32,8 +32,8 @@ public partial class Action : Thing
3232
public Values<Organization, Person>? Agent { get; set; }
3333

3434
/// <summary>
35-
/// The endTime of something. For a reserved event or service (e.g. FoodEstablishmentReservation), the time that it is expected to end. For actions that span a period of time, when the action was performed. e.g. John wrote a book from January to &lt;em&gt;December&lt;/em&gt;.&lt;/p&gt;
36-
/// &lt;p&gt;Note that Event uses startDate/endDate instead of startTime/endTime, even when describing dates with times. This situation may be clarified in future revisions.
35+
/// The endTime of something. For a reserved event or service (e.g. FoodEstablishmentReservation), the time that it is expected to end. For actions that span a period of time, when the action was performed. e.g. John wrote a book from January to &lt;em&gt;December&lt;/em&gt;.&lt;br/&gt;&lt;br/&gt;
36+
/// Note that Event uses startDate/endDate instead of startTime/endTime, even when describing dates with times. This situation may be clarified in future revisions.
3737
/// </summary>
3838
[DataMember(Name = "endTime", Order = 108)]
3939
[JsonConverter(typeof(ValuesConverter))]
@@ -82,8 +82,8 @@ public partial class Action : Thing
8282
public OneOrMany<Thing>? Result { get; set; }
8383

8484
/// <summary>
85-
/// The startTime of something. For a reserved event or service (e.g. FoodEstablishmentReservation), the time that it is expected to start. For actions that span a period of time, when the action was performed. e.g. John wrote a book from &lt;em&gt;January&lt;/em&gt; to December.&lt;/p&gt;
86-
/// &lt;p&gt;Note that Event uses startDate/endDate instead of startTime/endTime, even when describing dates with times. This situation may be clarified in future revisions.
85+
/// The startTime of something. For a reserved event or service (e.g. FoodEstablishmentReservation), the time that it is expected to start. For actions that span a period of time, when the action was performed. e.g. John wrote a book from &lt;em&gt;January&lt;/em&gt; to December.&lt;br/&gt;&lt;br/&gt;
86+
/// Note that Event uses startDate/endDate instead of startTime/endTime, even when describing dates with times. This situation may be clarified in future revisions.
8787
/// </summary>
8888
[DataMember(Name = "startTime", Order = 115)]
8989
[JsonConverter(typeof(ValuesConverter))]

0 commit comments

Comments
 (0)