/Songhay.Data.GenericWeb/Procedures/List/List.FragmentsBySegmentId.cs
C# | 33 lines | 19 code | 5 blank | 9 comment | 2 complexity | 8d7109992ad928588075afef00ca2ae7 MD5 | raw file
- using System;
- using System.Collections.Generic;
- using System.Data.Common;
-
- namespace Songhay.Data.GenericWeb.Procedures
- {
- using Songhay.Data.GenericWeb.Properties;
-
- /// <summary>
- /// List procedures into the DBMS.
- /// </summary>
- public static partial class List
- {
- /// <summary>
- /// Lists all fragments associated with the specified Segment.
- /// </summary>
- /// <param name="commonConnection">The Common connection.</param>
- /// <param name="uniqueIdentifier">The unique identifier.</param>
- /// <returns>Returns an XML <see cref="System.String"/>.</returns>
- public static string FragmentsBySegmentId(DbConnection commonConnection, string uniqueIdentifier)
- {
- if(uniqueIdentifier == null) throw new ArgumentNullException("uniqueIdentifier", "The unique identifer is null.");
-
- Dictionary<String, Object> paramSet = new Dictionary<string, object>(2);
- paramSet.Add("@SegmentId", uniqueIdentifier);
- paramSet.Add("@GlobalDateFormat", CommandHandler.GlobalDateFormat);
-
- string s = Common.CommonScalar.GetString(commonConnection, Resources.ListChildFragments, paramSet);
-
- return s;
- }
- }
- }