Skip to content
Open
2 changes: 2 additions & 0 deletions lib/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ plugins {
version = '2.0.0-alpha.1'

dependencies {
compileOnlyApi("org.apiguardian:apiguardian-api:1.1.2")

implementation wpi.java.deps.wpilib()
implementation wpi.java.vendor.java()

Expand Down
29 changes: 29 additions & 0 deletions lib/src/main/java/com/team2813/lib2813/control/motors/Clamper.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
/*
Copyright 2026 Prospect Robotics SWENext Club

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
package com.team2813.lib2813.control.motors;

/** Functional interface for clamping a value between low and high boundaries. */
@FunctionalInterface
public interface Clamper {

/**
* Returns value clamped between low and high boundaries.
*
* @param value the value to clamp.
* @return the clamped value.
*/
double clampValue(double value);
}
Loading
Loading