-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a81375c
commit 25d4517
Showing
6 changed files
with
198 additions
and
168 deletions.
There are no files selected for viewing
36 changes: 36 additions & 0 deletions
36
src/DotNetStac/Extensions/Disaster/DisasterStacExtensionExtensions.cs
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,36 @@ | ||
// Copyright (c) by Terradue Srl. All Rights Reserved. | ||
// License under the AGPL, Version 3.0. | ||
// File Name: DisasterStacExtensionExtensions.cs | ||
|
||
namespace Stac.Extensions.Disaster | ||
{ | ||
/// <summary> | ||
/// Extension methods for accessing EO extension | ||
/// </summary> | ||
public static class DisasterStacExtensionExtensions | ||
{ | ||
/// <summary> | ||
/// Initilize a DisastersCharterStacExtension class from a STAC item | ||
/// </summary> | ||
/// <param name="stacObject">The STAC item</param> | ||
/// <returns>The DisastersCharterStacExtension class</returns> | ||
public static DisastersCharterStacExtension DisasterExtension(this IStacObject stacObject) | ||
{ | ||
return new DisastersCharterStacExtension(stacObject); | ||
} | ||
|
||
/// <summary> | ||
/// Initilize a DisastersCharterStacExtension | ||
/// </summary> | ||
/// <param name="disasterStacExtension">The DisastersCharterStacExtension to initilize</param> | ||
/// <param name="disastersItemClass">The class of the item</param> | ||
/// <param name="activationId">The activation id</param> | ||
/// <param name="callIds">The call ids</param> | ||
public static void Init(this DisastersCharterStacExtension disasterStacExtension, DisastersItemClass disastersItemClass, int activationId, int[] callIds) | ||
{ | ||
disasterStacExtension.Class = disastersItemClass; | ||
disasterStacExtension.ActivationId = activationId; | ||
disasterStacExtension.CallIds = callIds; | ||
} | ||
} | ||
} |
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.