src/umbraco.presentation.xslt.Exslt/ExsltDatesAndTimes.cs
/// <summary>
/// Implements the following function 
///		string date:sum(node-set)
/// </summary>
/// <param name="iterator">The nodeset</param>
/// <returns>The sum of the values within the node set treated as </returns>
Implements the following function
string date:sum(node-set)
Implements the following function string date : sum ( node - set )
public static string sum(XPathNodeIterator iterator){
			TimeSpan sum = new TimeSpan(0,0,0,0); 
			if(iterator.Count == 0){
				return ""; 
			}
			try{ 
				while(iterator.MoveNext()){
					sum = XmlConvert.ToTimeSpan(iterator.Current.Value).Add(sum);
				}
			}catch(FormatException){
				return ""; 
			}
			return XmlConvert.ToString(sum) ; 
			}
public static string sum ( XPathNodeIterator iterator ) { TimeSpan sum = new TimeSpan ( 0 , 0 , 0 , 0 ) ; if ( iterator . Count == 0 ) { return " " ; } try { while ( iterator . MoveNext ( ) ) { sum = XmlConvert . ToTimeSpan ( iterator . Current . Value ) . Add ( sum ) ; } } catch ( FormatException ) { return " " ; } return XmlConvert . ToString ( sum ) ; }
Implements the following function
string date:sum(node-set)
Implements the following function string date : sum ( node - set )
//XmlConvert.ToString(sum);
The sum of the values within the node set treated as
The sum of the values within the node set treated as
iterator
XPathNodeIterator
None