/// <summary>
        /// Adds an operation descriptor to the list of operation descriptors.
        /// </summary>
        /// <param name="operationDescriptor">the operation descriptor to add.</param>
        internal void AddOperationDescriptor(OperationDescriptor operationDescriptor)
        {
            Debug.Assert(operationDescriptor != null, "operationDescriptor != null");

            if (this.operationDescriptors == null)
            {
                this.operationDescriptors = new List <OperationDescriptor>();
            }

            // The protocol allows multiple descriptors with the same rel, so we don't check for duplicate entries here.
            this.operationDescriptors.Add(operationDescriptor);
        }
 public MyOperationDescriptor(OperationDescriptor od)
 {
     this.Title = od.Title;
     this.Metadata = od.Metadata.IsAbsoluteUri ? od.Metadata.AbsoluteUri : od.Metadata.OriginalString;
     this.Target = od.Target.AbsoluteUri;
 }
Exemplo n.º 3
0
        /// <summary>
        /// Adds an operation descriptor to the list of operation descriptors.
        /// </summary>
        /// <param name="operationDescriptor">the operation descriptor to add.</param>
        internal void AddOperationDescriptor(OperationDescriptor operationDescriptor)
        {
            Debug.Assert(operationDescriptor != null, "operationDescriptor != null");

            if (this.operationDescriptors == null)
            {
                this.operationDescriptors = new List<OperationDescriptor>();
            }

            // The protocol allows multiple descriptors with the same rel, so we don't check for duplicate entries here.
            this.operationDescriptors.Add(operationDescriptor);
        }