// 
// Decompiled by Procyon v0.6.0
// 

package it.unimi.dsi.fastutil.objects;

import java.util.Comparator;
import it.unimi.dsi.fastutil.Pair;

public interface ObjectBytePair<K> extends Pair<K, Byte>
{
    byte rightByte();
    
    @Deprecated
    default Byte right() {
        return this.rightByte();
    }
    
    default ObjectBytePair<K> right(final byte r) {
        throw new UnsupportedOperationException();
    }
    
    @Deprecated
    default ObjectBytePair<K> right(final Byte l) {
        return this.right((byte)l);
    }
    
    default byte secondByte() {
        return this.rightByte();
    }
    
    @Deprecated
    default Byte second() {
        return this.secondByte();
    }
    
    default ObjectBytePair<K> second(final byte r) {
        return this.right(r);
    }
    
    @Deprecated
    default ObjectBytePair<K> second(final Byte l) {
        return this.second((byte)l);
    }
    
    default byte valueByte() {
        return this.rightByte();
    }
    
    @Deprecated
    default Byte value() {
        return this.valueByte();
    }
    
    default ObjectBytePair<K> value(final byte r) {
        return this.right(r);
    }
    
    @Deprecated
    default ObjectBytePair<K> value(final Byte l) {
        return this.value((byte)l);
    }
    
    default <K> ObjectBytePair<K> of(final K left, final byte right) {
        return new ObjectByteImmutablePair<K>(left, right);
    }
    
    default <K> Comparator<ObjectBytePair<K>> lexComparator() {
        return (x, y) -> {
            final int t = ((Comparable)x.left()).compareTo(y.left());
            if (t != 0) {
                return t;
            }
            else {
                return Byte.compare(x.rightByte(), y.rightByte());
            }
        };
    }
}
