package hanson.xyz.vpnhotspotmod.room;

@kotlin.Metadata(mv = {1, 9, 0}, k = 1, xi = 48, d1 = {"\u00006\n\u0002\u0018\u0002\n\u0002\u0010\u0000\n\u0000\n\u0002\u0010\t\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0010\u000e\n\u0002\b/\n\u0002\u0010\u000b\n\u0002\b\u0002\n\u0002\u0010\b\n\u0002\b\u0003\b\u0087\b\u0018\u00002\u00020\u0001:\u0001?Bs\u0012\n\b\u0002\u0010\u0002\u001a\u0004\u0018\u00010\u0003\u0012\b\b\u0002\u0010\u0004\u001a\u00020\u0003\u0012\u0006\u0010\u0005\u001a\u00020\u0006\u0012\u0006\u0010\u0007\u001a\u00020\b\u0012\n\b\u0002\u0010\t\u001a\u0004\u0018\u00010\n\u0012\u0006\u0010\u000b\u001a\u00020\n\u0012\b\b\u0002\u0010\f\u001a\u00020\u0003\u0012\b\b\u0002\u0010\r\u001a\u00020\u0003\u0012\b\b\u0002\u0010\u000e\u001a\u00020\u0003\u0012\b\b\u0002\u0010\u000f\u001a\u00020\u0003\u0012\n\b\u0002\u0010\u0010\u001a\u0004\u0018\u00010\u0003\u00a2\u0006\u0002\u0010\u0011J\u0010\u0010,\u001a\u0004\u0018\u00010\u0003H\u00c6\u0003\u00a2\u0006\u0002\u0010\u0015J\t\u0010-\u001a\u00020\u0003H\u00c6\u0003J\u0010\u0010.\u001a\u0004\u0018\u00010\u0003H\u00c6\u0003\u00a2\u0006\u0002\u0010\u0015J\t\u0010/\u001a\u00020\u0003H\u00c6\u0003J\t\u00100\u001a\u00020\u0006H\u00c6\u0003J\t\u00101\u001a\u00020\bH\u00c6\u0003J\u000b\u00102\u001a\u0004\u0018\u00010\nH\u00c6\u0003J\t\u00103\u001a\u00020\nH\u00c6\u0003J\t\u00104\u001a\u00020\u0003H\u00c6\u0003J\t\u00105\u001a\u00020\u0003H\u00c6\u0003J\t\u00106\u001a\u00020\u0003H\u00c6\u0003J\u0082\u0001\u00107\u001a\u00020\u00002\n\b\u0002\u0010\u0002\u001a\u0004\u0018\u00010\u00032\b\b\u0002\u0010\u0004\u001a\u00020\u00032\b\b\u0002\u0010\u0005\u001a\u00020\u00062\b\b\u0002\u0010\u0007\u001a\u00020\b2\n\b\u0002\u0010\t\u001a\u0004\u0018\u00010\n2\b\b\u0002\u0010\u000b\u001a\u00020\n2\b\b\u0002\u0010\f\u001a\u00020\u00032\b\b\u0002\u0010\r\u001a\u00020\u00032\b\b\u0002\u0010\u000e\u001a\u00020\u00032\b\b\u0002\u0010\u000f\u001a\u00020\u00032\n\b\u0002\u0010\u0010\u001a\u0004\u0018\u00010\u0003H\u00c6\u0001\u00a2\u0006\u0002\u00108J\u0013\u00109\u001a\u00020:2\b\u0010;\u001a\u0004\u0018\u00010\u0001H\u00d6\u0003J\t\u0010<\u001a\u00020=H\u00d6\u0001J\t\u0010>\u001a\u00020\nH\u00d6\u0001R\u0011\u0010\u000b\u001a\u00020\n\u00a2\u0006\b\n\u0000\u001a\u0004\b\u0012\u0010\u0013R\"\u0010\u0002\u001a\u0004\u0018\u00010\u00038\u0006@\u0006X\u0087\u000e\u00a2\u0006\u0010\n\u0002\u0010\u0018\u001a\u0004\b\u0014\u0010\u0015\"\u0004\b\u0016\u0010\u0017R\u0011\u0010\u0007\u001a\u00020\b\u00a2\u0006\b\n\u0000\u001a\u0004\b\u0019\u0010\u001aR\u0011\u0010\u0005\u001a\u00020\u0006\u00a2\u0006\b\n\u0000\u001a\u0004\b\u001b\u0010\u001cR\u0015\u0010\u0010\u001a\u0004\u0018\u00010\u0003\u00a2\u0006\n\n\u0002\u0010\u0018\u001a\u0004\b\u001d\u0010\u0015R\u001a\u0010\u000f\u001a\u00020\u0003X\u0086\u000e\u00a2\u0006\u000e\n\u0000\u001a\u0004\b\u001e\u0010\u001f\"\u0004\b \u0010!R\u001a\u0010\u000e\u001a\u00020\u0003X\u0086\u000e\u00a2\u0006\u000e\n\u0000\u001a\u0004\b\"\u0010\u001f\"\u0004\b#\u0010!R\u001a\u0010\r\u001a\u00020\u0003X\u0086\u000e\u00a2\u0006\u000e\n\u0000\u001a\u0004\b$\u0010\u001f\"\u0004\b%\u0010!R\u001a\u0010\f\u001a\u00020\u0003X\u0086\u000e\u00a2\u0006\u000e\n\u0000\u001a\u0004\b&\u0010\u001f\"\u0004\b\'\u0010!R\u0011\u0010\u0004\u001a\u00020\u0003\u00a2\u0006\b\n\u0000\u001a\u0004\b(\u0010\u001fR\u001e\u0010\t\u001a\u0004\u0018\u00010\n8\u0006X\u0087\u0004\u00a2\u0006\u000e\n\u0000\u0012\u0004\b)\u0010*\u001a\u0004\b+\u0010\u0013\u00a8\u0006@"}, d2 = {"Lhanson/xyz/vpnhotspotmod/room/TrafficRecord;", "", "id", "", "timestamp", "mac", "Landroid/net/MacAddress;", "ip", "Ljava/net/InetAddress;", "upstream", "", "downstream", "sentPackets", "sentBytes", "receivedPackets", "receivedBytes", "previousId", "(Ljava/lang/Long;JLandroid/net/MacAddress;Ljava/net/InetAddress;Ljava/lang/String;Ljava/lang/String;JJJJLjava/lang/Long;)V", "getDownstream", "()Ljava/lang/String;", "getId", "()Ljava/lang/Long;", "setId", "(Ljava/lang/Long;)V", "Ljava/lang/Long;", "getIp", "()Ljava/net/InetAddress;", "getMac", "()Landroid/net/MacAddress;", "getPreviousId", "getReceivedBytes", "()J", "setReceivedBytes", "(J)V", "getReceivedPackets", "setReceivedPackets", "getSentBytes", "setSentBytes", "getSentPackets", "setSentPackets", "getTimestamp", "getUpstream$annotations", "()V", "getUpstream", "component1", "component10", "component11", "component2", "component3", "component4", "component5", "component6", "component7", "component8", "component9", "copy", "(Ljava/lang/Long;JLandroid/net/MacAddress;Ljava/net/InetAddress;Ljava/lang/String;Ljava/lang/String;JJJJLjava/lang/Long;)Lhanson/xyz/vpnhotspotmod/room/TrafficRecord;", "equals", "", "other", "hashCode", "", "toString", "Dao", "mobile_freedomDebug"})
@androidx.room.Entity(foreignKeys = {@androidx.room.ForeignKey(entity = hanson.xyz.vpnhotspotmod.room.TrafficRecord.class, parentColumns = {"id"}, childColumns = {"previousId"}, onDelete = 5, onUpdate = 2)}, indices = {@androidx.room.Index(value = {"previousId"}, unique = true)})
public final class TrafficRecord {
    
    /**
     * Setting id = null should only be used when a new row is created and not yet inserted into the database.
     *
     * https://www.sqlite.org/lang_createtable.html#primkeyconst:
     * > Unless the column is an INTEGER PRIMARY KEY or the table is a WITHOUT ROWID table or the column is declared
     * > NOT NULL, SQLite allows NULL values in a PRIMARY KEY column.
     */
    @androidx.room.PrimaryKey(autoGenerate = true)
    @org.jetbrains.annotations.Nullable
    private java.lang.Long id;
    private final long timestamp = 0L;
    
    /**
     * Foreign key/ID for (possibly non-existent, i.e. default) entry in ClientRecord.
     */
    @org.jetbrains.annotations.NotNull
    private final android.net.MacAddress mac = null;
    
    /**
     * For now only stats for IPv4 will be recorded. But I'm going to put the more general class here just in case.
     */
    @org.jetbrains.annotations.NotNull
    private final java.net.InetAddress ip = null;
    @org.jetbrains.annotations.Nullable
    @java.lang.Deprecated
    private final java.lang.String upstream = null;
    @org.jetbrains.annotations.NotNull
    private final java.lang.String downstream = null;
    private long sentPackets;
    private long sentBytes;
    private long receivedPackets;
    private long receivedBytes;
    
    /**
     * ID for the previous traffic record.
     */
    @org.jetbrains.annotations.Nullable
    private final java.lang.Long previousId = null;
    
    public TrafficRecord(@org.jetbrains.annotations.Nullable
    java.lang.Long id, long timestamp, @org.jetbrains.annotations.NotNull
    android.net.MacAddress mac, @org.jetbrains.annotations.NotNull
    java.net.InetAddress ip, @org.jetbrains.annotations.Nullable
    java.lang.String upstream, @org.jetbrains.annotations.NotNull
    java.lang.String downstream, long sentPackets, long sentBytes, long receivedPackets, long receivedBytes, @org.jetbrains.annotations.Nullable
    java.lang.Long previousId) {
        super();
    }
    
    /**
     * Setting id = null should only be used when a new row is created and not yet inserted into the database.
     *
     * https://www.sqlite.org/lang_createtable.html#primkeyconst:
     * > Unless the column is an INTEGER PRIMARY KEY or the table is a WITHOUT ROWID table or the column is declared
     * > NOT NULL, SQLite allows NULL values in a PRIMARY KEY column.
     */
    @org.jetbrains.annotations.Nullable
    public final java.lang.Long getId() {
        return null;
    }
    
    /**
     * Setting id = null should only be used when a new row is created and not yet inserted into the database.
     *
     * https://www.sqlite.org/lang_createtable.html#primkeyconst:
     * > Unless the column is an INTEGER PRIMARY KEY or the table is a WITHOUT ROWID table or the column is declared
     * > NOT NULL, SQLite allows NULL values in a PRIMARY KEY column.
     */
    public final void setId(@org.jetbrains.annotations.Nullable
    java.lang.Long p0) {
    }
    
    public final long getTimestamp() {
        return 0L;
    }
    
    /**
     * Foreign key/ID for (possibly non-existent, i.e. default) entry in ClientRecord.
     */
    @org.jetbrains.annotations.NotNull
    public final android.net.MacAddress getMac() {
        return null;
    }
    
    /**
     * For now only stats for IPv4 will be recorded. But I'm going to put the more general class here just in case.
     */
    @org.jetbrains.annotations.NotNull
    public final java.net.InetAddress getIp() {
        return null;
    }
    
    @org.jetbrains.annotations.Nullable
    @java.lang.Deprecated
    public final java.lang.String getUpstream() {
        return null;
    }
    
    @java.lang.Deprecated
    public static void getUpstream$annotations() {
    }
    
    @org.jetbrains.annotations.NotNull
    public final java.lang.String getDownstream() {
        return null;
    }
    
    public final long getSentPackets() {
        return 0L;
    }
    
    public final void setSentPackets(long p0) {
    }
    
    public final long getSentBytes() {
        return 0L;
    }
    
    public final void setSentBytes(long p0) {
    }
    
    public final long getReceivedPackets() {
        return 0L;
    }
    
    public final void setReceivedPackets(long p0) {
    }
    
    public final long getReceivedBytes() {
        return 0L;
    }
    
    public final void setReceivedBytes(long p0) {
    }
    
    /**
     * ID for the previous traffic record.
     */
    @org.jetbrains.annotations.Nullable
    public final java.lang.Long getPreviousId() {
        return null;
    }
    
    @org.jetbrains.annotations.Nullable
    public final java.lang.Long component1() {
        return null;
    }
    
    public final long component10() {
        return 0L;
    }
    
    @org.jetbrains.annotations.Nullable
    public final java.lang.Long component11() {
        return null;
    }
    
    public final long component2() {
        return 0L;
    }
    
    @org.jetbrains.annotations.NotNull
    public final android.net.MacAddress component3() {
        return null;
    }
    
    @org.jetbrains.annotations.NotNull
    public final java.net.InetAddress component4() {
        return null;
    }
    
    @org.jetbrains.annotations.Nullable
    public final java.lang.String component5() {
        return null;
    }
    
    @org.jetbrains.annotations.NotNull
    public final java.lang.String component6() {
        return null;
    }
    
    public final long component7() {
        return 0L;
    }
    
    public final long component8() {
        return 0L;
    }
    
    public final long component9() {
        return 0L;
    }
    
    @org.jetbrains.annotations.NotNull
    public final hanson.xyz.vpnhotspotmod.room.TrafficRecord copy(@org.jetbrains.annotations.Nullable
    java.lang.Long id, long timestamp, @org.jetbrains.annotations.NotNull
    android.net.MacAddress mac, @org.jetbrains.annotations.NotNull
    java.net.InetAddress ip, @org.jetbrains.annotations.Nullable
    java.lang.String upstream, @org.jetbrains.annotations.NotNull
    java.lang.String downstream, long sentPackets, long sentBytes, long receivedPackets, long receivedBytes, @org.jetbrains.annotations.Nullable
    java.lang.Long previousId) {
        return null;
    }
    
    @java.lang.Override
    public boolean equals(@org.jetbrains.annotations.Nullable
    java.lang.Object other) {
        return false;
    }
    
    @java.lang.Override
    public int hashCode() {
        return 0;
    }
    
    @java.lang.Override
    @org.jetbrains.annotations.NotNull
    public java.lang.String toString() {
        return null;
    }
    
    @kotlin.Metadata(mv = {1, 9, 0}, k = 1, xi = 48, d1 = {"\u0000,\n\u0002\u0018\u0002\n\u0002\u0010\u0000\n\u0002\b\u0002\n\u0002\u0010\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0010\t\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\b\u0002\b\'\u0018\u00002\u00020\u0001B\u0005\u00a2\u0006\u0002\u0010\u0002J\u000e\u0010\u0003\u001a\u00020\u00042\u0006\u0010\u0005\u001a\u00020\u0006J\u0010\u0010\u0007\u001a\u00020\b2\u0006\u0010\u0005\u001a\u00020\u0006H%J\u0019\u0010\t\u001a\u00020\n2\u0006\u0010\u000b\u001a\u00020\fH\u00a7@\u00f8\u0001\u0000\u00a2\u0006\u0002\u0010\r\u0082\u0002\u0004\n\u0002\b\u0019\u00a8\u0006\u000e"}, d2 = {"Lhanson/xyz/vpnhotspotmod/room/TrafficRecord$Dao;", "", "()V", "insert", "", "value", "Lhanson/xyz/vpnhotspotmod/room/TrafficRecord;", "insertInternal", "", "queryStats", "Lhanson/xyz/vpnhotspotmod/room/ClientStats;", "mac", "Landroid/net/MacAddress;", "(Landroid/net/MacAddress;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;", "mobile_freedomDebug"})
    @androidx.room.Dao
    public static abstract class Dao {
        
        public Dao() {
            super();
        }
        
        @androidx.room.Insert
        protected abstract long insertInternal(@org.jetbrains.annotations.NotNull
        hanson.xyz.vpnhotspotmod.room.TrafficRecord value);
        
        public final void insert(@org.jetbrains.annotations.NotNull
        hanson.xyz.vpnhotspotmod.room.TrafficRecord value) {
        }
        
        @androidx.room.Query(value = "\n            SELECT  MIN(TrafficRecord.timestamp) AS timestamp,\n                    COUNT(TrafficRecord.id) AS count,\n                    SUM(TrafficRecord.sentPackets) AS sentPackets,\n                    SUM(TrafficRecord.sentBytes) AS sentBytes,\n                    SUM(TrafficRecord.receivedPackets) AS receivedPackets,\n                    SUM(TrafficRecord.receivedBytes) AS receivedBytes\n                FROM TrafficRecord LEFT JOIN TrafficRecord AS Next ON TrafficRecord.id = Next.previousId\n                /* We only want to find the last record for each chain so that we don\'t double count */\n                WHERE TrafficRecord.mac = :mac AND Next.id IS NULL\n                ")
        @org.jetbrains.annotations.Nullable
        public abstract java.lang.Object queryStats(@org.jetbrains.annotations.NotNull
        android.net.MacAddress mac, @org.jetbrains.annotations.NotNull
        kotlin.coroutines.Continuation<? super hanson.xyz.vpnhotspotmod.room.ClientStats> $completion);
    }
}