示例#1
0
 public override bool Equals(object obj)
 {
     return((obj is DimensionInformation dimensionInformation) &&
            LengthExponent.Equals(dimensionInformation.LengthExponent) &&
            MassExponent.Equals(dimensionInformation.MassExponent) &&
            TimeExponent.Equals(dimensionInformation.TimeExponent) &&
            ElectricCurrentExponent.Equals(dimensionInformation.ElectricCurrentExponent) &&
            TemperatureExponent.Equals(dimensionInformation.TemperatureExponent) &&
            AmountExponent.Equals(dimensionInformation.AmountExponent) &&
            LuminousIntensityExponent.Equals(dimensionInformation.LuminousIntensityExponent));
 }
示例#2
0
 public override int GetHashCode()
 {
     unchecked
     {
         var hashCode = LengthExponent.GetHashCode();
         hashCode = (hashCode * 397) ^ MassExponent.GetHashCode();
         hashCode = (hashCode * 397) ^ TimeExponent.GetHashCode();
         hashCode = (hashCode * 397) ^ ElectricCurrentExponent.GetHashCode();
         hashCode = (hashCode * 397) ^ TemperatureExponent.GetHashCode();
         hashCode = (hashCode * 397) ^ AmountExponent.GetHashCode();
         hashCode = (hashCode * 397) ^ LuminousIntensityExponent.GetHashCode();
         return(hashCode);
     }
 }
示例#3
0
        public override string GetStepParameters()
        {
            var parameters = new List <string>();

            parameters.Add(LengthExponent.ToStepValue());
            parameters.Add(MassExponent.ToStepValue());
            parameters.Add(TimeExponent.ToStepValue());
            parameters.Add(ElectricCurrentExponent.ToStepValue());
            parameters.Add(ThermodynamicTemperatureExponent.ToStepValue());
            parameters.Add(AmountOfSubstanceExponent.ToStepValue());
            parameters.Add(LuminousIntensityExponent.ToStepValue());

            return(string.Join(", ", parameters.ToArray()));
        }