Skip to content

Commit

Permalink
Promoting Abstractions to 2.1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
ENikS committed Oct 28, 2017
1 parent 3982716 commit 34a2b2c
Showing 1 changed file with 11 additions and 14 deletions.
25 changes: 11 additions & 14 deletions src/Policy/IPolicyList.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved. See License.txt in the project root for license information.

using System;
using Unity.Builder;

namespace Unity.Policy
{
Expand All @@ -10,24 +9,11 @@ namespace Unity.Policy
/// </summary>
public interface IPolicyList
{
/// <summary>
/// Removes an individual policy type for a build key.
/// </summary>
/// <param name="policyInterface">The type of policy to remove.</param>
/// <param name="buildKey">The key the policy applies.</param>
void Clear(Type policyInterface, object buildKey);

/// <summary>
/// Removes all policies from the list.
/// </summary>
void ClearAll();

/// <summary>
/// GetOrDefault the non default policy.
/// </summary>
/// <param name="policyInterface">The interface the policy is registered under.</param>
/// <param name="buildKey">The key the policy applies to.</param>
/// <param name="localOnly">True if the search should be in the local policy list only; otherwise false to search up the parent chain.</param>
/// <param name="containingPolicyList">The policy list in the chain that the searched for policy was found in, null if the policy was
/// not found.</param>
/// <returns>The policy in the list if present; returns null otherwise.</returns>
Expand All @@ -40,5 +26,16 @@ public interface IPolicyList
/// <param name="policy">The policy to be registered.</param>
/// <param name="buildKey">The key the policy applies.</param>
void Set(Type policyInterface, IBuilderPolicy policy, object buildKey = null);
/// <summary>
/// Removes an individual policy type for a build key.
/// </summary>
/// <param name="policyInterface">The type of policy to remove.</param>
/// <param name="buildKey">The key the policy applies.</param>
void Clear(Type policyInterface, object buildKey);

/// <summary>
/// Removes all policies from the list.
/// </summary>
void ClearAll();
}
}

0 comments on commit 34a2b2c

Please sign in to comment.