// Copyright (c) FIRST and other WPILib contributors.
// Open Source Software; you can modify and/or share it under the terms of
// the WPILib BSD license file in the root directory of this project.

// THIS FILE WAS AUTO-GENERATED BY ./wpiunits/generate_units.py. DO NOT MODIFY

package edu.wpi.first.units.measure;

import static edu.wpi.first.units.Units.*;
import edu.wpi.first.units.*;

@SuppressWarnings({"unchecked", "cast", "checkstyle", "PMD"})
public interface Resistance extends Measure<ResistanceUnit> {
  static  Resistance ofRelativeUnits(double magnitude, ResistanceUnit unit) {
    return new ImmutableResistance(magnitude, unit.toBaseUnits(magnitude), unit);
  }

  static  Resistance ofBaseUnits(double baseUnitMagnitude, ResistanceUnit unit) {
    return new ImmutableResistance(unit.fromBaseUnits(baseUnitMagnitude), baseUnitMagnitude, unit);
  }

  @Override
  Resistance copy();

  @Override
  default MutResistance mutableCopy() {
    return new MutResistance(magnitude(), baseUnitMagnitude(), unit());
  }

  @Override
  ResistanceUnit unit();

  @Override
  default ResistanceUnit baseUnit() { return (ResistanceUnit) unit().getBaseUnit(); }

  @Override
  default double in(ResistanceUnit unit) {
    return unit.fromBaseUnits(baseUnitMagnitude());
  }

  @Override
  default Resistance unaryMinus() {
    return (Resistance) unit().ofBaseUnits(0 - baseUnitMagnitude());
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use unaryMinus() instead. This was renamed for consistency with other WPILib classes like Rotation2d
  */
  @Override
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  default Resistance negate() {
    return (Resistance) unaryMinus();
  }

  @Override
  default Resistance plus(Measure<? extends ResistanceUnit> other) {
    return (Resistance) unit().ofBaseUnits(baseUnitMagnitude() + other.baseUnitMagnitude());
  }

  @Override
  default Resistance minus(Measure<? extends ResistanceUnit> other) {
    return (Resistance) unit().ofBaseUnits(baseUnitMagnitude() - other.baseUnitMagnitude());
  }

  @Override
  default Resistance times(double multiplier) {
    return (Resistance) unit().ofBaseUnits(baseUnitMagnitude() * multiplier);
  }

  @Override
  default Resistance div(double divisor) {
    return (Resistance) unit().ofBaseUnits(baseUnitMagnitude() / divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Override
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  default Resistance divide(double divisor) {
    return (Resistance) div(divisor);
  }

  @Override
  default Velocity<ResistanceUnit> per(TimeUnit period) {
    return div(period.of(1));
  }


  @Override
  default Mult<ResistanceUnit, AccelerationUnit<?>> times(Acceleration<?> multiplier) {
    return (Mult<ResistanceUnit, AccelerationUnit<?>>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, AccelerationUnit<?>> div(Acceleration<?> divisor) {
    return (Per<ResistanceUnit, AccelerationUnit<?>>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, AccelerationUnit<?>> divide(Acceleration<?> divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, AngleUnit> times(Angle multiplier) {
    return (Mult<ResistanceUnit, AngleUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, AngleUnit> div(Angle divisor) {
    return (Per<ResistanceUnit, AngleUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, AngleUnit> divide(Angle divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, AngularAccelerationUnit> times(AngularAcceleration multiplier) {
    return (Mult<ResistanceUnit, AngularAccelerationUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, AngularAccelerationUnit> div(AngularAcceleration divisor) {
    return (Per<ResistanceUnit, AngularAccelerationUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, AngularAccelerationUnit> divide(AngularAcceleration divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, AngularMomentumUnit> times(AngularMomentum multiplier) {
    return (Mult<ResistanceUnit, AngularMomentumUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, AngularMomentumUnit> div(AngularMomentum divisor) {
    return (Per<ResistanceUnit, AngularMomentumUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, AngularMomentumUnit> divide(AngularMomentum divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, AngularVelocityUnit> times(AngularVelocity multiplier) {
    return (Mult<ResistanceUnit, AngularVelocityUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, AngularVelocityUnit> div(AngularVelocity divisor) {
    return (Per<ResistanceUnit, AngularVelocityUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, AngularVelocityUnit> divide(AngularVelocity divisor) {
    return div(divisor);
  }


  @Override
  default Voltage times(Current multiplier) {
    return Volts.of(baseUnitMagnitude() * multiplier.baseUnitMagnitude());
  }

  @Override
  default Per<ResistanceUnit, CurrentUnit> div(Current divisor) {
    return (Per<ResistanceUnit, CurrentUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, CurrentUnit> divide(Current divisor) {
    return div(divisor);
  }

  @Override
  default Resistance div(Dimensionless divisor) {
    return (Resistance) Ohms.of(baseUnitMagnitude() / divisor.baseUnitMagnitude());
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Override
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  default Resistance divide(Dimensionless divisor) {
    return (Resistance) div(divisor);
  }

  @Override
  default Resistance times(Dimensionless multiplier) {
    return (Resistance) Ohms.of(baseUnitMagnitude() * multiplier.baseUnitMagnitude());
  }


  @Override
  default Mult<ResistanceUnit, DistanceUnit> times(Distance multiplier) {
    return (Mult<ResistanceUnit, DistanceUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, DistanceUnit> div(Distance divisor) {
    return (Per<ResistanceUnit, DistanceUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, DistanceUnit> divide(Distance divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, EnergyUnit> times(Energy multiplier) {
    return (Mult<ResistanceUnit, EnergyUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, EnergyUnit> div(Energy divisor) {
    return (Per<ResistanceUnit, EnergyUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, EnergyUnit> divide(Energy divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, ForceUnit> times(Force multiplier) {
    return (Mult<ResistanceUnit, ForceUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, ForceUnit> div(Force divisor) {
    return (Per<ResistanceUnit, ForceUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, ForceUnit> divide(Force divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, FrequencyUnit> times(Frequency multiplier) {
    return (Mult<ResistanceUnit, FrequencyUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, FrequencyUnit> div(Frequency divisor) {
    return (Per<ResistanceUnit, FrequencyUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, FrequencyUnit> divide(Frequency divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, LinearAccelerationUnit> times(LinearAcceleration multiplier) {
    return (Mult<ResistanceUnit, LinearAccelerationUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, LinearAccelerationUnit> div(LinearAcceleration divisor) {
    return (Per<ResistanceUnit, LinearAccelerationUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, LinearAccelerationUnit> divide(LinearAcceleration divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, LinearMomentumUnit> times(LinearMomentum multiplier) {
    return (Mult<ResistanceUnit, LinearMomentumUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, LinearMomentumUnit> div(LinearMomentum divisor) {
    return (Per<ResistanceUnit, LinearMomentumUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, LinearMomentumUnit> divide(LinearMomentum divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, LinearVelocityUnit> times(LinearVelocity multiplier) {
    return (Mult<ResistanceUnit, LinearVelocityUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, LinearVelocityUnit> div(LinearVelocity divisor) {
    return (Per<ResistanceUnit, LinearVelocityUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, LinearVelocityUnit> divide(LinearVelocity divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, MassUnit> times(Mass multiplier) {
    return (Mult<ResistanceUnit, MassUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, MassUnit> div(Mass divisor) {
    return (Per<ResistanceUnit, MassUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, MassUnit> divide(Mass divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, MomentOfInertiaUnit> times(MomentOfInertia multiplier) {
    return (Mult<ResistanceUnit, MomentOfInertiaUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, MomentOfInertiaUnit> div(MomentOfInertia divisor) {
    return (Per<ResistanceUnit, MomentOfInertiaUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, MomentOfInertiaUnit> divide(MomentOfInertia divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, MultUnit<?, ?>> times(Mult<?, ?> multiplier) {
    return (Mult<ResistanceUnit, MultUnit<?, ?>>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, MultUnit<?, ?>> div(Mult<?, ?> divisor) {
    return (Per<ResistanceUnit, MultUnit<?, ?>>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, MultUnit<?, ?>> divide(Mult<?, ?> divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, PerUnit<?, ?>> times(Per<?, ?> multiplier) {
    return (Mult<ResistanceUnit, PerUnit<?, ?>>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, PerUnit<?, ?>> div(Per<?, ?> divisor) {
    return (Per<ResistanceUnit, PerUnit<?, ?>>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, PerUnit<?, ?>> divide(Per<?, ?> divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, PowerUnit> times(Power multiplier) {
    return (Mult<ResistanceUnit, PowerUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, PowerUnit> div(Power divisor) {
    return (Per<ResistanceUnit, PowerUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, PowerUnit> divide(Power divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, ResistanceUnit> times(Resistance multiplier) {
    return (Mult<ResistanceUnit, ResistanceUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Dimensionless div(Resistance divisor) {
    return Value.of(baseUnitMagnitude() / divisor.baseUnitMagnitude());
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Dimensionless divide(Resistance divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, TemperatureUnit> times(Temperature multiplier) {
    return (Mult<ResistanceUnit, TemperatureUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, TemperatureUnit> div(Temperature divisor) {
    return (Per<ResistanceUnit, TemperatureUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, TemperatureUnit> divide(Temperature divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, TimeUnit> times(Time multiplier) {
    return (Mult<ResistanceUnit, TimeUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Velocity<ResistanceUnit> div(Time divisor) {
    return VelocityUnit.combine(unit(), divisor.unit()).ofBaseUnits(baseUnitMagnitude() / divisor.baseUnitMagnitude());
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Velocity<ResistanceUnit> divide(Time divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, TorqueUnit> times(Torque multiplier) {
    return (Mult<ResistanceUnit, TorqueUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, TorqueUnit> div(Torque divisor) {
    return (Per<ResistanceUnit, TorqueUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, TorqueUnit> divide(Torque divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, VelocityUnit<?>> times(Velocity<?> multiplier) {
    return (Mult<ResistanceUnit, VelocityUnit<?>>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, VelocityUnit<?>> div(Velocity<?> divisor) {
    return (Per<ResistanceUnit, VelocityUnit<?>>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, VelocityUnit<?>> divide(Velocity<?> divisor) {
    return div(divisor);
  }


  @Override
  default Mult<ResistanceUnit, VoltageUnit> times(Voltage multiplier) {
    return (Mult<ResistanceUnit, VoltageUnit>) Measure.super.times(multiplier);
  }

  @Override
  default Per<ResistanceUnit, VoltageUnit> div(Voltage divisor) {
    return (Per<ResistanceUnit, VoltageUnit>) Measure.super.div(divisor);
  }

  /**
  * {@inheritDoc}
  *
  * @deprecated use div instead. This was renamed for consistency with other languages like Kotlin
  */
  @Deprecated(since = "2025", forRemoval = true)
  @SuppressWarnings({"deprecation", "removal"})
  @Override
  default Per<ResistanceUnit, VoltageUnit> divide(Voltage divisor) {
    return div(divisor);
  }

}
