//
// This file was generated by //third_party/jni_zero/jni_zero.py
//
package org.jni_zero;

import android.content.Context;
import android.view.View;
import java.util.function.Consumer;
import javax.annotation.processing.Generated;
import org.jni_zero.CheckDiscard;
import org.jni_zero.GEN_JNI;
import org.jni_zero.JniTestInstanceHolder;
import org.jni_zero.SampleForAnnotationProcessor;
import org.jni_zero.internal.NullUnmarked;
import org.jni_zero.internal.Nullable;
import org.stubs.MyClass;

@CheckDiscard("crbug.com/993421")
@Generated("JNI Zero")
@SuppressWarnings({"rawtypes", "unchecked"})
@NullUnmarked
class SampleForAnnotationProcessorJni implements SampleForAnnotationProcessor.Natives {
  private static @Nullable JniTestInstanceHolder sOverride;

  public static SampleForAnnotationProcessor.Natives get() {
    JniTestInstanceHolder holder = sOverride;
    if (holder != null && holder.value != null) {
      return (SampleForAnnotationProcessor.Natives) holder.value;
    }
    return new SampleForAnnotationProcessorJni();
  }

  public static void setInstanceForTesting(SampleForAnnotationProcessor.Natives impl) {
    if (sOverride == null) {
      sOverride = JniTestInstanceHolder.create();
    }
    sOverride.value = impl;
  }


  @Override
  public SampleForAnnotationProcessor bar(SampleForAnnotationProcessor sample) {
    return (SampleForAnnotationProcessor) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_bar(
        sample);
  }

  @Override
  public void foo() {
    GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_foo();
  }

  @Override
  public boolean hasPhalange() {
    return (boolean) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_hasPhalange();
  }

  @Override
  public Class returnClass() {
    return (Class) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnClass();
  }

  @Override
  public Class[] returnClasses() {
    return (Class[]) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnClasses();
  }

  @Override
  public SampleForAnnotationProcessor[] returnConvertedAppObjects() {
    return (SampleForAnnotationProcessor[]) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnConvertedAppObjects(
        SampleForAnnotationProcessor.class);
  }

  @Override
  public int[] returnConvertedInts() {
    return (int[]) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnConvertedInts();
  }

  @Override
  public String returnConvertedString() {
    return (String) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnConvertedString();
  }

  @Override
  public String[] returnConvertedStrings() {
    return (String[]) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnConvertedStrings();
  }

  @Override
  public Object returnObject() {
    return (Object) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnObject();
  }

  @Override
  public Object[] returnObjects() {
    return (Object[]) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnObjects();
  }

  @Override
  public String returnString() {
    return (String) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnString();
  }

  @Override
  public String[] returnStrings() {
    return (String[]) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnStrings();
  }

  @Override
  public SampleForAnnotationProcessor.TestStruct returnStruct() {
    return (SampleForAnnotationProcessor.TestStruct) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnStruct();
  }

  @Override
  public SampleForAnnotationProcessor.TestStruct[] returnStructs() {
    return (SampleForAnnotationProcessor.TestStruct[]) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnStructs();
  }

  @Override
  public Throwable returnThrowable() {
    return (Throwable) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnThrowable();
  }

  @Override
  public Throwable[] returnThrowables() {
    return (Throwable[]) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_returnThrowables();
  }

  @Override
  public String revString(String stringToReverse) {
    return (String) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_revString(stringToReverse);
  }

  @Override
  public SampleForAnnotationProcessor[] sendSamplesToNative(SampleForAnnotationProcessor[] strs) {
    return (SampleForAnnotationProcessor[]) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_sendSamplesToNative(
        strs);
  }

  @Override
  public String[] sendToNative(String[] strs) {
    return (String[]) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_sendToNative(strs);
  }

  @Override
  public int[] testAllPrimitives(int zint, int[] ints, long zlong, long[] longs, short zshort, short[] shorts, char zchar, char[] chars, byte zbyte, byte[] bytes, double zdouble, double[] doubles, float zfloat, float[] floats, boolean zbool, boolean[] bools) {
    return (int[]) GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_testAllPrimitives(
        zint,
        ints,
        zlong,
        longs,
        zshort,
        shorts,
        zchar,
        chars,
        zbyte,
        bytes,
        zdouble,
        doubles,
        zfloat,
        floats,
        zbool,
        bools);
  }

  @Override
  public void testSpecialTypes(Class clazz, Class[] classes, Throwable throwable, Throwable[] throwables, String string, String[] strings, String convertedString, String[] convertedStrings, String optionalString, Consumer funcType, SampleForAnnotationProcessor.TestStruct tStruct, SampleForAnnotationProcessor.TestStruct[] structs, Object obj, Object convertedObj, Object[] objects, MyClass.SecondNestedInterface nestedInterface, View view, Context context, Object[] convertedObjects) {
    GEN_JNI.org_jni_1zero_SampleForAnnotationProcessor_testSpecialTypes(
        clazz,
        classes,
        throwable,
        throwables,
        string,
        strings,
        convertedString,
        convertedStrings,
        optionalString,
        funcType,
        tStruct,
        structs,
        obj,
        convertedObj,
        objects,
        nestedInterface,
        view,
        context,
        convertedObjects);
  }
}
