///
/// Copyright © 2003-2008 JetBrains s.r.o.
/// You may distribute under the terms of the GNU General Public License, as published by the Free Software Foundation, version 2 (see License.txt in the repository root folder).
///
using System.Collections.Generic;
using JetBrains.Build.Omea.Util;
using Microsoft.Build.Framework;
using Microsoft.Build.Utilities;
namespace JetBrains.Build.Omea.Infra
{
///
/// Implements a task that requires the path to the product assemblies.
///
public abstract class ProductTask : ProbingTask
{
#region Attributes
///
/// The list of assemblies to be published, as well as their characteristics.
///
[Required]
public ITaskItem AllAssembliesXml
{
get
{
return (TaskItem)Bag.Get(AttributeName.AllAssembliesXml);
}
set
{
Bag.Set(AttributeName.AllAssembliesXml, new TaskItemByValue(value.ItemSpec));
}
}
///
/// Gets or sets the folder where the product binaries are located.
///
[Required]
public ITaskItem ProductBinariesDir
{
get
{
return Bag.Get(AttributeName.ProductBinariesDir);
}
set
{
Bag.Set(AttributeName.ProductBinariesDir, value);
}
}
#endregion
#region Overrides
///
/// Gets the list of attributes that must contain the probing directories.
///
protected override ICollection ProbingDirectoryAttributes
{
get
{
var retval = new List(base.ProbingDirectoryAttributes);
retval.Add(AttributeName.ProductBinariesDir);
return retval;
}
}
#endregion
}
}