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

io.smallrye.jwt.auth.jaxrs.JAXRSMessages_$bundle Maven / Gradle / Ivy

There is a newer version: 4.6.1
Show newest version
package io.smallrye.jwt.auth.jaxrs;

import java.util.Locale;
import java.lang.IllegalStateException;
import java.io.Serializable;
import java.util.Collection;
import java.lang.String;
import java.util.Arrays;

/**
 * Warning this class consists of generated code.
 */
public class JAXRSMessages_$bundle implements JAXRSMessages, Serializable {
    private static final long serialVersionUID = 1L;
    protected JAXRSMessages_$bundle() {}
    public static final JAXRSMessages_$bundle INSTANCE = new JAXRSMessages_$bundle();
    protected Object readResolve() {
        return INSTANCE;
    }
    private static final Locale LOCALE = Locale.ROOT;
    protected Locale getLoggingLocale() {
        return LOCALE;
    }
    protected String duplicateJWTAnnotationsFound$str() {
        return "SRJWT09000: Duplicate MicroProfile JWT annotations found on %s. Expected at most 1 annotation, found: %d";
    }
    @Override
    public final IllegalStateException duplicateJWTAnnotationsFound(final String annotationPlacementDescriptor, final Collection annotations) {
        final int annotationsSize;
        if (annotations == null) annotationsSize = 0; else annotationsSize = annotations.size();
        final IllegalStateException result = new IllegalStateException(String.format(getLoggingLocale(), duplicateJWTAnnotationsFound$str(), annotationPlacementDescriptor, annotationsSize));
        _copyStackTraceMinusOne(result);
        return result;
    }
    private static void _copyStackTraceMinusOne(final Throwable e) {
        final StackTraceElement[] st = e.getStackTrace();
        e.setStackTrace(Arrays.copyOfRange(st, 1, st.length));
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy