Skip to content

Commit

Permalink
Merge pull request #13 from jpdillingham/master
Browse files Browse the repository at this point in the history
Implemented IPackageManifest interface
  • Loading branch information
jpdillingham authored Jul 8, 2017
2 parents da2f655 + 9a1820d commit 11a051f
Show file tree
Hide file tree
Showing 4 changed files with 125 additions and 2 deletions.
122 changes: 122 additions & 0 deletions OpenIIoT.SDK.Packaging/Manifest/IPackageManifest.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,122 @@
/*
█▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀ ▀▀▀ ▀ ▀ ▀▀
█ ▄█ ▄███████▄ ▄▄▄▄███▄▄▄▄
█ ███ ███ ███ ▄██▀▀▀███▀▀▀██▄
█ ███▌ ███ ███ ▄█████ ▄██████ █ █▄ ▄█████ ▄████▄ ▄█████ ███ ███ ███ ▄█████ ██▄▄▄▄ █ ▄█████ ▄█████ ▄█████ ██
█ ███▌ ███ ███ ██ ██ ██ ██ ██ ▄██▀ ██ ██ ██ ▀ ██ █ ███ ███ ███ ██ ██ ██▀▀▀█▄ ██ ██ ▀█ ██ █ ██ ▀ ▀███████▄
█ ███▌ ▀█████████▀ ██ ██ ██ ▀ ██▐█▀ ██ ██ ▄██ ▄██▄▄ ███ ███ ███ ██ ██ ██ ██ ██▌ ▄██▄▄ ▄██▄▄ ██ ██ ▀
█ ███ ███ ▀████████ ██ ▄ ▀▀████ ▀████████ ▀▀██ ███▄ ▀▀██▀▀ ███ ███ ███ ▀████████ ██ ██ ██ ▀▀██▀▀ ▀▀██▀▀ ▀███████ ██
█ ███ ███ ██ ██ ██ ██ ██ ▀██▄ ██ ██ ██ ██ ██ █ ███ ███ ███ ██ ██ ██ ██ ██ ██ ██ █ ▄ ██ ██
█ █▀ ▄████▀ ██ █▀ ██████▀ ▀█ ▀█▀ ██ █▀ ██████▀ ███████ ▀█ ███ █▀ ██ █▀ █ █ █ ██ ███████ ▄████▀ ▄██▀
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄ ▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄ ▄▄ ▄▄ ▄▄ ▄▄▄▄ ▄▄ ▄▄ ▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄ ▄ ▄
█████████████████████████████████████████████████████████████ ███████████████ ██ ██ ██ ████ ██ ██ ████████████████ █ █
█ A Manifest which describes the contents of a Package file.
█▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀ ▀▀▀▀▀▀▀▀▀▀▀ ▀ ▀▀▀ ▀▀ ▀
█ The GNU Affero General Public License (GNU AGPL)
█ Copyright (C) 2016-2017 JP Dillingham ([email protected])
█ This program is free software: you can redistribute it and/or modify
█ it under the terms of the GNU Affero General Public License as published by
█ the Free Software Foundation, either version 3 of the License, or
█ (at your option) any later version.
█ This program is distributed in the hope that it will be useful,
█ but WITHOUT ANY WARRANTY; without even the implied warranty of
█ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
█ GNU Affero General Public License for more details.
█ You should have received a copy of the GNU Affero General Public License
█ along with this program. If not, see <http://www.gnu.org/licenses/>.
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀ ▀▀ ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀██
██
▀█▄ ██ ▄█▀
▀████▀
▀▀ */

using System.Collections.Generic;
using Newtonsoft.Json;

namespace OpenIIoT.SDK.Packaging.Manifest
{
/// <summary>
/// A Manifest which describes the contents of a Package file.
/// </summary>
public interface IPackageManifest
{
#region Public Properties

/// <summary>
/// Gets or sets the checksum of the payload file.
/// </summary>
[JsonProperty(Order = 9)]
string Checksum { get; set; }

/// <summary>
/// Gets or sets the Package copyright.
/// </summary>
[JsonProperty(Order = 6)]
string Copyright { get; set; }

/// <summary>
/// Gets or sets the Package description.
/// </summary>
[JsonProperty(Order = 4)]
string Description { get; set; }

/// <summary>
/// Gets or sets the collection of <see cref="PackageManifestFile"/> instances representing the files in the Package payload.
/// </summary>
[JsonProperty(Order = 11)]
IList<PackageManifestFile> Files { get; set; }

/// <summary>
/// Gets or sets the Package license.
/// </summary>
[JsonProperty(Order = 7)]
string License { get; set; }

/// <summary>
/// Gets or sets the Package namespace.
/// </summary>
[JsonProperty(Order = 3)]
string Namespace { get; set; }

/// <summary>
/// Gets or sets the Package publisher.
/// </summary>
[JsonProperty(Order = 5)]
string Publisher { get; set; }

/// <summary>
/// Gets or sets the Package <see cref="PackageManifestSignature"/>.
/// </summary>
[JsonProperty(Order = 10)]
PackageManifestSignature Signature { get; set; }

/// <summary>
/// Gets or sets the Package title.
/// </summary>
[JsonProperty(Order = 1)]
string Title { get; set; }

/// <summary>
/// Gets or sets the Package url.
/// </summary>
[JsonProperty(Order = 8)]
string Url { get; set; }

/// <summary>
/// Gets or sets the Package version.
/// </summary>
[JsonProperty(Order = 2)]
string Version { get; set; }

#endregion Public Properties
}
}
2 changes: 1 addition & 1 deletion OpenIIoT.SDK.Packaging/Manifest/PackageManifest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ namespace OpenIIoT.SDK.Packaging.Manifest
/// <summary>
/// A Manifest which describes the contents of a Package file.
/// </summary>
public class PackageManifest
public class PackageManifest : IPackageManifest
{
#region Public Properties

Expand Down
1 change: 1 addition & 0 deletions OpenIIoT.SDK.Packaging/OpenIIoT.SDK.Packaging.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
</ItemGroup>
<ItemGroup>
<Compile Include="ArgumentValidator.cs" />
<Compile Include="Manifest\IPackageManifest.cs" />
<Compile Include="Manifest\PackageManifest.cs" />
<Compile Include="Manifest\PackageManifestBuilder.cs" />
<Compile Include="Manifest\PackageManifestFile.cs" />
Expand Down
2 changes: 1 addition & 1 deletion OpenIIoT.SDK.Packaging/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@
[assembly: AssemblyCulture("")]
[assembly: ComVisible(false)]
[assembly: Guid("6d80d90e-aa21-4557-a319-c7520d9eb8e4")]
[assembly: AssemblyVersion("0.9.2.*")]
[assembly: AssemblyVersion("0.9.3.*")]

0 comments on commit 11a051f

Please sign in to comment.