Prechádzať zdrojové kódy

interface for secondary id

v2ray 10 rokov pred
rodič
commit
1f584f1502
1 zmenil súbory, kde vykonal 9 pridanie a 0 odobranie
  1. 9 0
      proxy/vmess/user.go

+ 9 - 0
proxy/vmess/user.go

@@ -1,5 +1,9 @@
 package vmess
 
+import (
+	"time"
+)
+
 type UserLevel int
 
 const (
@@ -12,6 +16,11 @@ type User interface {
 	Level() UserLevel
 }
 
+type SecondaryID interface {
+	ID() *ID
+	ValidUntil() time.Time
+}
+
 type UserSettings struct {
 	PayloadReadTimeout int
 }