21 lines
		
	
	
		
			466 B
		
	
	
	
		
			Go
		
	
	
		
			Executable File
		
	
	
	
	
			
		
		
	
	
			21 lines
		
	
	
		
			466 B
		
	
	
	
		
			Go
		
	
	
		
			Executable File
		
	
	
	
	
| package server
 | |
| 
 | |
| type RequestType string
 | |
| 
 | |
| const (
 | |
| 	TypeStreamNextVideo RequestType = "StreamNextVideo"
 | |
| 	TypeStreamPrevVideo RequestType = "StreamPrevVideo"
 | |
| 	TypeQuit            RequestType = "Quit"
 | |
| )
 | |
| 
 | |
| type Request struct {
 | |
| 	Type RequestType `json:"type"`
 | |
| }
 | |
| 
 | |
| type Data struct {
 | |
| 	Timestamp        int64    `json:"timestamp"`
 | |
| 	CurrentVideoPath string   `json:"currentVideoPath"`
 | |
| 	VideoList        []string `json:"videoList"`
 | |
| 	Output           string   `json:"output"`
 | |
| }
 |