using System;
using System.Runtime.Serialization;
namespace GitHub.DistributedTask.WebApi
{
[DataContract]
public class TaskDefinitionEndpoint
{
///
/// The scope as understood by Connected Services.
/// Essentialy, a project-id for now.
///
[DataMember]
public String Scope
{
get;
set;
}
///
/// URL to GET.
///
[DataMember]
public String Url
{
get;
set;
}
///
/// An XPath/Json based selector to filter response returned by fetching
/// the endpoint Url. An XPath based selector must be prefixed with
/// the string "xpath:". A Json based selector must be prefixed with "jsonpath:".
///
/// The following selector defines an XPath for extracting nodes named 'ServiceName'.
///
/// endpoint.Selector = "xpath://ServiceName";
///
///
///
[DataMember]
public String Selector
{
get;
set;
}
///
/// An Json based keyselector to filter response returned by fetching
/// the endpoint Url.A Json based keyselector must be prefixed with "jsonpath:".
/// KeySelector can be used to specify the filter to get the keys for the values specified with Selector.
///
/// The following keyselector defines an Json for extracting nodes named 'ServiceName'.
///
/// endpoint.KeySelector = "jsonpath://ServiceName";
///
///
///
[DataMember]
public String KeySelector
{
get;
set;
}
///
/// An ID that identifies a service connection to be used for authenticating
/// endpoint requests.
///
[DataMember]
public String ConnectionId
{
get;
set;
}
///
/// TaskId that this endpoint belongs to.
///
[DataMember]
public String TaskId
{
get;
set;
}
}
}