Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var HistoryPath = "/History"
HistoryPath is the path inside the _Serato_ folder that contains History data
var SeratoAdatMap = map[int]string{
1: "RROW",
2: "RDIR",
28: "TTMS",
29: "TTME",
31: "TDCK",
41: "RDTE",
43: "RSRT",
44: "REND",
45: "TPTM",
48: "RSES",
50: "RPLY",
52: "RADD",
53: "RUPD",
54: "RUNK",
57: "RSWR",
58: "RSWB",
63: "RDEV",
}
SeratoAdatMap Defines all the known keys with their integer key found in Serato Databases TODO: Identify all fields of an ADAT object
var SessionPath = HistoryPath + "/Sessions"
SessionPath is the path inside the _Serato_/History folder that contains all the played Sessions.
Functions ¶
This section is empty.
Types ¶
type HistoryEntity ¶
type HistoryEntity struct { RROW int // rrow RDIR string // rfullpath TTMS int // rstarttime TTME int // rendtime TDCK int // rdeck RDTE string // rdate* RSRT int // rstart* REND int // rend* TPTM int // rplaytime RSES int // rsessionId RPLY int // rplayed = 1 RADD int // radded RUPD int // rupdatedAt RSWR string // rsoftware* RSWB int // rsoftwareBuild* RDEV string // rdevice }
HistoryEntity defines Tracks/Songs entities in a History Session
type MediaEntity ¶
type MediaEntity struct { // META DVOL string // volume // UTFSTR PTRK string // filetrack PFIL string // filebase TTYP string // track type TSNG string // song title TART string // artist Title TGEN string // genre TLEN string // length TBIT string // bit rate TSMP string // sampling rate TALB string // album title TCOM string // comment TCMP string // composer TADD string // local time added to database TKEY string // key TLBL string // ?? TBPM string // bpm TGRP string // group? TTYR string // year TSIZ string // size of track UDSC string // desc? TRMX string // remix tag TCOR string // group? PVID string // group? // INT1 BMIS bool // missing BCRT bool // corrupt BHRT bool // ? BPLY bool // ? BLOP bool // ? BITU bool // ? BOVC bool // ? BIRO bool // ? BWLB bool // ? BWLL bool // ? BUNS bool // ? BBGL bool // ? BKRK bool // ? // INT4 UADD int // timeadded UTKN int // ?? UTME int // ?? UTPC int // playcount UFSB int // ?? // BYTE SLICE ULBL []byte // color - track colour SBAV []byte //? }
MediaEntity defines Tracks/Songs entities in a Database or Crate aka Otrk
type Parser ¶
type Parser struct {
FilePath string
}
Parser holds the filepath of all databases
var SeratoParser Parser
SeratoParser is the Parser for this Serato Database module. Exported for future option of override
func (Parser) GetAllTracks ¶
func (p Parser) GetAllTracks() []MediaEntity
GetAllTracks returns all the tracks/entities inside the Database
func (Parser) GetCrateTracks ¶
func (p Parser) GetCrateTracks(fileName string) []MediaEntity
GetCrateTracks takes a filename and returns all the tracks/entities inside the crate
func (Parser) GetCrates ¶
GetCrates returns files of all crates found in Serato Path TODO: Should we parse meta data of theses files, or only provide OS level elements. Weird to be a parser library and no parsing. TODO: Is there Serato Crate meta data?
func (Parser) GetHistorySessions ¶
GetHistorySessions returns a list of all Serato History session files in the users Serato directory.
func (Parser) ReadHistorySession ¶
func (p Parser) ReadHistorySession(fileName string) []HistoryEntity
ReadHistorySession returns all track entities within the provided filepath.