-
Notifications
You must be signed in to change notification settings - Fork 270
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
…mCollection with attributes
- Loading branch information
Showing
6 changed files
with
306 additions
and
121 deletions.
There are no files selected for viewing
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,41 @@ | ||
/************************************************************************************************* | ||
Required Notice: Copyright (C) EPPlus Software AB. | ||
This software is licensed under PolyForm Noncommercial License 1.0.0 | ||
and may only be used for noncommercial purposes | ||
https://polyformproject.org/licenses/noncommercial/1.0.0/ | ||
A commercial license to use this software can be purchased at https://epplussoftware.com | ||
************************************************************************************************* | ||
Date Author Change | ||
************************************************************************************************* | ||
7/11/2023 EPPlus Software AB EPPlus 7 | ||
*************************************************************************************************/ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
|
||
namespace OfficeOpenXml.Attributes | ||
{ | ||
/// <summary> | ||
/// This attributes can only be used on properties that are of the type IDictionary<string, string>. | ||
/// Columns will be added based on the items in <see cref="EPPlusDictionaryColumnAttribute.ColumnHeaders"/> | ||
/// </summary> | ||
[AttributeUsage(AttributeTargets.Method | AttributeTargets.Property | AttributeTargets.Field)] | ||
internal class EPPlusDictionaryColumnAttribute : Attribute | ||
{ | ||
/// <summary> | ||
/// Order of the columns value, default value is 0 | ||
/// </summary> | ||
public int Order | ||
{ | ||
get; | ||
set; | ||
} | ||
|
||
/// <summary> | ||
/// The values of this array will be used to generate columns (one column for each item). | ||
/// </summary> | ||
public string[] ColumnHeaders { get; set; } | ||
} | ||
} |
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
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
Oops, something went wrong.