001// Copyright (c) FIRST and other WPILib contributors.
002// Open Source Software; you can modify and/or share it under the terms of
003// the WPILib BSD license file in the root directory of this project.
004
005package edu.wpi.first.hal.simulation;
006
007import edu.wpi.first.hal.JNIWrapper;
008
009/** JNI for relay data. */
010public class RelayDataJNI extends JNIWrapper {
011  public static native int registerInitializedForwardCallback(
012      int index, NotifyCallback callback, boolean initialNotify);
013
014  public static native void cancelInitializedForwardCallback(int index, int uid);
015
016  public static native boolean getInitializedForward(int index);
017
018  public static native void setInitializedForward(int index, boolean initializedForward);
019
020  public static native int registerInitializedReverseCallback(
021      int index, NotifyCallback callback, boolean initialNotify);
022
023  public static native void cancelInitializedReverseCallback(int index, int uid);
024
025  public static native boolean getInitializedReverse(int index);
026
027  public static native void setInitializedReverse(int index, boolean initializedReverse);
028
029  public static native int registerForwardCallback(
030      int index, NotifyCallback callback, boolean initialNotify);
031
032  public static native void cancelForwardCallback(int index, int uid);
033
034  public static native boolean getForward(int index);
035
036  public static native void setForward(int index, boolean forward);
037
038  public static native int registerReverseCallback(
039      int index, NotifyCallback callback, boolean initialNotify);
040
041  public static native void cancelReverseCallback(int index, int uid);
042
043  public static native boolean getReverse(int index);
044
045  public static native void setReverse(int index, boolean reverse);
046
047  public static native void resetData(int index);
048
049  /** Utility class. */
050  private RelayDataJNI() {}
051}