Beispiel #1
0
 public AdditionOfConvertersConverter(UnitConverter first, UnitConverter second)
 {
     this.first  = first;
     this.second = second;
 }
Beispiel #2
0
 public ProductOfConvertersConverter(UnitConverter first, UnitConverter second)
 {
     this.first  = first;
     this.second = second;
 }
Beispiel #3
0
 internal CompoundConverter(UnitConverter first, UnitConverter second)
 {
     this.first  = first;
     this.second = second;
 }
Beispiel #4
0
 /// <summary>
 /// Concatenates this converter with another converter. The resulting converter
 /// is equivalent to the first converter concatenated with this converter.
 ///
 /// Implementations must ensure that the IDENTITY instance is returned if the
 /// resulting converter is an identity converter.
 /// </summary>
 /// <param name="converter">The converter to concatenate with this converter.</param>
 /// <returns>The concatenation of this converter with the other</returns>
 public virtual UnitConverter Concatenate(UnitConverter converter)
 {
     return(converter == IDENTITY ? this : new CompoundConverter(converter, this));
 }
Beispiel #5
0
 public override UnitConverter Concatenate(UnitConverter converter)
 {
     return(converter);
 }