Skip to content

Commit 02dd1d2

Browse files
committed
update to latest version
1 parent 322bb81 commit 02dd1d2

4 files changed

Lines changed: 20 additions & 3 deletions

File tree

v2/rscg_examples/Maestria.TypeProviders/src/DemoExcel/DemoExcel.csproj

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@
1010
<ItemGroup>
1111
<PackageReference Include="ClosedXML" Version="0.105.0" />
1212
<PackageReference Include="Maestria.Extensions" Version="3.7.2.0" />
13-
<PackageReference Include="Maestria.TypeProviders" Version="1.2.1">
13+
<PackageReference Include="Maestria.TypeProviders" Version="1.3.1">
14+
<PrivateAssets>all</PrivateAssets>
15+
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
1416
</PackageReference>
1517
</ItemGroup>
1618

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
namespace DemoExcel;
2+
3+
public partial class MyExcelPerson
4+
{
5+
public string FullName() => $"{FirstName} {LastName}";
6+
}

v2/rscg_examples/Maestria.TypeProviders/src/DemoExcel/Person.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
namespace DemoExcel;
66

7-
[ExcelProvider(TemplatePath = @"Excel.xlsx")]
7+
[ExcelProvider(TemplatePath = @"MyExcel.xlsx")]
88
public partial class MyExcelPerson
99
{
1010
}
Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,10 @@
1-
Console.WriteLine("Hello, World!");
1+
using DemoExcel;
2+
3+
Console.WriteLine("Hello, World!");
4+
var persons = MyExcelPersonFactory.Load("MyExcel.xlsx").ToArray();
5+
6+
foreach (var person in persons)
7+
{
8+
Console.WriteLine(person.ID + person.FullName());
9+
10+
}

0 commit comments

Comments
 (0)