mirror of
https://github.com/VibedByKaKi/alexandroid.git
synced 2026-11-15 10:27:17 +01:00
29 lines
1 KiB
Java
29 lines
1 KiB
Java
package org.java_websocket.framing;
|
|
|
|
import org.java_websocket.enums.Opcode;
|
|
import org.java_websocket.exceptions.InvalidDataException;
|
|
import org.java_websocket.exceptions.InvalidFrameException;
|
|
|
|
/* compiled from: r8-map-id-b9432e0f623b4a4bff4ba50a8a24c4aafad2c1e11092747b9fb5e6a22af5a940 */
|
|
/* loaded from: classes11.dex */
|
|
public abstract class ControlFrame extends FramedataImpl1 {
|
|
public ControlFrame(Opcode opcode) {
|
|
super(opcode);
|
|
}
|
|
|
|
@Override // org.java_websocket.framing.FramedataImpl1
|
|
public void isValid() throws InvalidDataException {
|
|
if (!isFin()) {
|
|
throw new InvalidFrameException("Control frame can't have fin==false set");
|
|
}
|
|
if (isRSV1()) {
|
|
throw new InvalidFrameException("Control frame can't have rsv1==true set");
|
|
}
|
|
if (isRSV2()) {
|
|
throw new InvalidFrameException("Control frame can't have rsv2==true set");
|
|
}
|
|
if (isRSV3()) {
|
|
throw new InvalidFrameException("Control frame can't have rsv3==true set");
|
|
}
|
|
}
|
|
}
|