All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.aya.util.error.PosedConsumer Maven / Gradle / Ivy

There is a newer version: 0.34.0
Show newest version
// Copyright (c) 2020-2024 Tesla (Yinsen) Zhang.
// Use of this source code is governed by the MIT license that can be found in the LICENSE.md file.
package org.aya.util.error;

import org.jetbrains.annotations.NotNull;

import java.util.function.BiConsumer;

@FunctionalInterface
public interface PosedConsumer extends BiConsumer {
  default void accept(@NotNull WithPos a) {
    accept(a.sourcePos(), a.data());
  }

  default void forceAccept(T a) {
    accept(SourcePos.NONE, a);
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy