public override VolumeError validateCommandAndUpdateCommandStatus(VolumeLimits volumeLimits, int sampleVolumeMin, int sampleVolumeMax) { VolumeError err = VolumeError.NO_ERROR; this.CommandCheckStatus = VolumeCheck.VOLUMES_VALID; this.CommandStatus = ""; int acceptableVolSrc = volumeLimits.getCapacity(SourceVial) - volumeLimits.getDeadVolume(SourceVial); if (VolumeTypeSpecifier == VolumeType.Absolute) { if (isVolumeAbove(acceptableVolSrc, VolumeTypeSpecifier, AbsoluteVolume_uL, 0.0f, 0)) { err = getErrorFromSpecifier(VolumeTypeSpecifier); this.CommandCheckStatus = VolumeCheck.VOLUMES_WARNINGS; this.CommandStatus = "vol > src cap of " + acceptableVolSrc + " uL"; } else if (!isSmallVial(SourceVial)) { err = VolumeError.MIXING_WITH_ABSOLUTE_AMOUNT; this.CommandCheckStatus = VolumeCheck.VOLUMES_WARNINGS; this.CommandStatus = "using abs vol for mixing"; } } else if (VolumeTypeSpecifier == VolumeType.Relative) { int acceptableTipVol = volumeLimits.maximumCapacity_SampleTipVolume_ul; if (isSmallVial(SourceVial)) { acceptableTipVol = volumeLimits.maximumCapacity_ReagentTipVolume_ul; } if (isVolumeAbove(acceptableTipVol, VolumeTypeSpecifier, 0, RelativeVolumeProportion, sampleVolumeMax)) { err = getErrorFromSpecifier(VolumeTypeSpecifier); this.CommandCheckStatus = VolumeCheck.VOLUMES_WARNINGS; this.CommandStatus = "vol > tip cap of " + acceptableTipVol + " uL"; } } return(err); }
public override VolumeError validateCommandAndUpdateCommandStatus(VolumeLimits volumeLimits, int sampleVolumeMin, int sampleVolumeMax) { VolumeError err = VolumeError.NO_ERROR; this.CommandCheckStatus = VolumeCheck.VOLUMES_VALID; this.CommandStatus = ""; int acceptableVolDst = volumeLimits.getCapacity(DestinationVial); if (VolumeTypeSpecifier == VolumeType.Relative) { if (isVolumeAbove(acceptableVolDst - sampleVolumeMin, VolumeTypeSpecifier, 0, RelativeVolumeProportion, sampleVolumeMin)) { err = getErrorFromSpecifier(VolumeTypeSpecifier); this.CommandCheckStatus = VolumeCheck.VOLUMES_WARNINGS; this.CommandStatus = msg_prefix + " vol > dst cap of " + acceptableVolDst + " uL"; } } return(err); }
public override VolumeError validateCommandAndUpdateCommandStatus(VolumeLimits volumeLimits, int sampleVolumeMin, int sampleVolumeMax) { VolumeError err = VolumeError.NO_ERROR; this.CommandCheckStatus = VolumeCheck.VOLUMES_VALID; this.CommandStatus = ""; if (CalculatedVolumeBelowRecommended(volumeLimits, sampleVolumeMin, sampleVolumeMax)) { err = VolumeError.BELOW_AMOUNT; return(err); } else if (CalculatedVolumeAboveRecommended(volumeLimits, sampleVolumeMin, sampleVolumeMax, out err)) { return(err); } else if (isSmallVial(DestinationVial) && !canReagentVialBeTransportDestination()) { this.CommandCheckStatus = VolumeCheck.VOLUMES_WARNINGS; this.CommandStatus = "dst is reagent vial"; err = VolumeError.DEST_SMALL_VIAL; return(err); } return(err); }
/// <inheritdoc /> /// <summary> /// Initializes a new instance of the <see cref="T:Zeiss.IMT.PiWeb.Volume.VolumeException" /> class. /// </summary> /// <param name="error">The error.</param> /// <param name="message">The message.</param> /// <param name="innerException">The inner exception.</param> internal VolumeException(VolumeError error, string message, Exception innerException) : base(message, innerException) { Error = error; }
/// <inheritdoc /> /// <summary> /// Initializes a new instance of the <see cref="T:Zeiss.IMT.PiWeb.Volume.VolumeException" /> class. /// </summary> /// <param name="error">The error.</param> /// <param name="message">The message.</param> internal VolumeException(VolumeError error, string message) : base(message) { Error = error; }
/// <inheritdoc /> /// <summary> /// Initializes a new instance of the <see cref="T:Zeiss.IMT.PiWeb.Volume.VolumeException" /> class. /// </summary> /// <param name="error">The error.</param> internal VolumeException(VolumeError error) { Error = error; }
private bool CalculatedVolumeAboveRecommended(VolumeLimits volumeLimits, int sampleVolumeMin, int sampleVolumeMax, out VolumeError err) { bool result = false; int acceptableVolSrc = volumeLimits.getCapacity(SourceVial) - volumeLimits.getDeadVolume(SourceVial); int acceptableVolDst = volumeLimits.getCapacity(DestinationVial); err = VolumeError.NO_ERROR; if (isVolumeAbove(acceptableVolSrc, VolumeTypeSpecifier, AbsoluteVolume_uL, RelativeVolumeProportion, sampleVolumeMax)) { err = getErrorFromSpecifier(VolumeTypeSpecifier); this.CommandCheckStatus = VolumeCheck.VOLUMES_WARNINGS; this.CommandStatus = "vol > src cap of " + acceptableVolSrc + " uL"; result = true; } else if (isVolumeAbove(acceptableVolDst, VolumeTypeSpecifier, AbsoluteVolume_uL, RelativeVolumeProportion, sampleVolumeMax)) { err = getErrorFromSpecifier(VolumeTypeSpecifier); this.CommandCheckStatus = VolumeCheck.VOLUMES_WARNINGS; this.CommandStatus = "vol > dst cap of " + acceptableVolDst + " uL"; result = true; } return(result); }
public void ShowAbsoluteVolumeError2(VolumeError errorVol) { ShowAbsoluteVolumeError(errorVol, errorAbsoluteVolume2, txtVolumeCommandAbsolute2); }
public void ShowRelativeVolumeProportion2Error(VolumeError errorVol) { ShowRelativeVolumeProportionError(errorVol, errorRelativeVolumeProportion2, txtVolumeCommandRelative2); }