/// <summary> /// Determines whether the container is appropriate for the sopplied configuration. /// </summary> /// <param name="config">The configuration.</param> /// <returns>true if valid, otherwise false</returns> public bool IsMatchContainer(TruckConfiguration config) { return(EquipmentConfiguration.Container != null && EquipmentConfiguration.ContainerOwner != null && config.EquipmentConfiguration.Container != null && config.EquipmentConfiguration.ContainerOwner != null && EquipmentConfiguration.Container == config.EquipmentConfiguration.Container && EquipmentConfiguration.ContainerOwner == config.EquipmentConfiguration.ContainerOwner); }
/// <summary> /// Determines whether the chassis is appropriate for the supplied configuration. /// </summary> /// <param name="config">The configuration.</param> /// <returns>true if valid, otherwise false</returns> public bool IsMatchChassis(TruckConfiguration config) { if (EquipmentConfiguration.Chassis == null || config.EquipmentConfiguration.Chassis == null) { return(false); } return(EquipmentConfiguration.Chassis == config.EquipmentConfiguration.Chassis && EquipmentConfiguration.ChassisOwner == config.EquipmentConfiguration.ChassisOwner); }