New Input System equivalent of GetButton boolean

Hi, I have a script that needs to get a boolean value when a button is pressed in the update method. In the old input system I would do something like this:

bool jump = false;

void Update()
{
    jump = Input.GetButton("Jump");
}

However, on the new input system, I have to use the event that fires instead:

public void OnJump(InputValue value)
{
    jump = true;
}

I understand that the logic relating to the button press can be handled in the event, but if I need to use the boolean in the update method, how can I reset the boolean for the frames where the button is not pressed?

Hope that makes sense. thanks!

Ok, so this post was really helpful:

I needed to get a reference to the action:

var map = CurrentInputControl.currentActionMap; //CurrentInputControl is exposed in editor to drag in the Player Input
inputJump= map.FindAction("Jump", true);

Then in my Update, I can use the IsPressed() method which is similar to GetButton:

jump =  inputJump.IsPressed();