pyrekordbox 0.2.0__py3-none-any.whl → 0.2.2__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- docs/Makefile +20 -0
- docs/make.bat +35 -0
- docs/source/_static/images/anlz_beat.svg +53 -0
- docs/source/_static/images/anlz_file.svg +204 -0
- docs/source/_static/images/anlz_pco2.svg +138 -0
- docs/source/_static/images/anlz_pcob.svg +148 -0
- docs/source/_static/images/anlz_pcp2.svg +398 -0
- docs/source/_static/images/anlz_pcpt.svg +263 -0
- docs/source/_static/images/anlz_ppth.svg +123 -0
- docs/source/_static/images/anlz_pqt2.svg +324 -0
- docs/source/_static/images/anlz_pqt2_2.svg +253 -0
- docs/source/_static/images/anlz_pqtz.svg +140 -0
- docs/source/_static/images/anlz_pssi.svg +192 -0
- docs/source/_static/images/anlz_pssi_entry.svg +191 -0
- docs/source/_static/images/anlz_pvbr.svg +125 -0
- docs/source/_static/images/anlz_pwav.svg +130 -0
- docs/source/_static/images/anlz_pwv3.svg +139 -0
- docs/source/_static/images/anlz_pwv4.svg +139 -0
- docs/source/_static/images/anlz_pwv5.svg +139 -0
- docs/source/_static/images/anlz_pwv5_entry.svg +100 -0
- docs/source/_static/images/anlz_pwv6.svg +130 -0
- docs/source/_static/images/anlz_pwv7.svg +139 -0
- docs/source/_static/images/anlz_pwvc.svg +125 -0
- docs/source/_static/images/anlz_tag.svg +110 -0
- docs/source/_static/logos/dark/logo_primary.svg +75 -0
- docs/source/_static/logos/light/logo_primary.svg +75 -0
- docs/source/_static/logos/mid/logo_primary.svg +75 -0
- docs/source/_templates/apidoc/module.rst_t +8 -0
- docs/source/_templates/apidoc/package.rst_t +57 -0
- docs/source/_templates/apidoc/toc.rst_t +7 -0
- docs/source/_templates/autosummary/class.rst +32 -0
- docs/source/_templates/autosummary/module.rst +55 -0
- docs/source/api.md +18 -0
- docs/source/conf.py +178 -0
- docs/source/development/changes.md +3 -0
- docs/source/development/contributing.md +3 -0
- docs/source/formats/anlz.md +634 -0
- docs/source/formats/db6.md +1233 -0
- docs/source/formats/mysetting.md +392 -0
- docs/source/formats/xml.md +376 -0
- docs/source/index.md +105 -0
- docs/source/installation.md +3 -0
- docs/source/quickstart.md +185 -0
- docs/source/requirements.txt +7 -0
- docs/source/tutorial/anlz.md +7 -0
- docs/source/tutorial/configuration.md +66 -0
- docs/source/tutorial/db6.md +179 -0
- docs/source/tutorial/index.md +20 -0
- docs/source/tutorial/mysetting.md +124 -0
- docs/source/tutorial/xml.md +140 -0
- pyrekordbox/__init__.py +1 -1
- pyrekordbox/__main__.py +16 -37
- pyrekordbox/_version.py +2 -2
- pyrekordbox/anlz/file.py +39 -0
- pyrekordbox/anlz/structs.py +3 -5
- pyrekordbox/config.py +71 -27
- pyrekordbox/db6/database.py +290 -61
- pyrekordbox/db6/registry.py +24 -0
- pyrekordbox/db6/tables.py +501 -340
- pyrekordbox/mysettings/file.py +0 -25
- pyrekordbox/utils.py +1 -1
- {pyrekordbox-0.2.0.dist-info → pyrekordbox-0.2.2.dist-info}/METADATA +42 -20
- pyrekordbox-0.2.2.dist-info/RECORD +80 -0
- {pyrekordbox-0.2.0.dist-info → pyrekordbox-0.2.2.dist-info}/top_level.txt +1 -0
- tests/test_config.py +175 -0
- tests/test_db6.py +95 -0
- pyrekordbox-0.2.0.dist-info/RECORD +0 -29
- {pyrekordbox-0.2.0.dist-info → pyrekordbox-0.2.2.dist-info}/LICENSE +0 -0
- {pyrekordbox-0.2.0.dist-info → pyrekordbox-0.2.2.dist-info}/WHEEL +0 -0
pyrekordbox/db6/tables.py
CHANGED
@@ -4,9 +4,13 @@
|
|
4
4
|
|
5
5
|
"""Rekordbox 6 `master.db` SQLAlchemy table declarations."""
|
6
6
|
|
7
|
-
|
8
|
-
|
9
|
-
|
7
|
+
import math
|
8
|
+
import struct
|
9
|
+
import numpy as np
|
10
|
+
from datetime import datetime
|
11
|
+
from sqlalchemy import Column, Integer, VARCHAR, BigInteger, SmallInteger, Text, Float
|
12
|
+
from sqlalchemy import ForeignKey, TypeDecorator
|
13
|
+
from sqlalchemy.orm import DeclarativeBase, relationship, backref, mapped_column, Mapped
|
10
14
|
from sqlalchemy.inspection import inspect
|
11
15
|
from .registry import RekordboxAgentRegistry
|
12
16
|
|
@@ -53,20 +57,50 @@ __all__ = [
|
|
53
57
|
]
|
54
58
|
|
55
59
|
|
60
|
+
class DateTime(TypeDecorator):
|
61
|
+
"""Custom datetime column with timezone support.
|
62
|
+
|
63
|
+
The datetime format in the database is `YYYY-MM-DD HH:MM:SS.SSS +00:00`.
|
64
|
+
The timezone seems to always be `+00:00` (UTC).
|
65
|
+
This format is not supported by the `DateTime` column of SQLAlchemy 2.
|
66
|
+
"""
|
67
|
+
|
68
|
+
impl = Text
|
69
|
+
cache_ok = True
|
70
|
+
|
71
|
+
def process_bind_param(self, value, dialect):
|
72
|
+
return value.isoformat().replace("T", " ")[:-3] + " +00:00"
|
73
|
+
|
74
|
+
def process_result_value(self, value, dialect):
|
75
|
+
if value:
|
76
|
+
try:
|
77
|
+
dt = datetime.fromisoformat(value)
|
78
|
+
except ValueError:
|
79
|
+
if len(value.strip()) > 23:
|
80
|
+
datestr, tzinfo = value[:23], value[23:]
|
81
|
+
datestr = datestr.strip()
|
82
|
+
tzinfo = tzinfo.strip()
|
83
|
+
assert tzinfo == "+00:00", tzinfo
|
84
|
+
else:
|
85
|
+
datestr, tzinfo = value, ""
|
86
|
+
dt = datetime.fromisoformat(datestr)
|
87
|
+
return dt
|
88
|
+
return None
|
89
|
+
|
90
|
+
|
56
91
|
# -- Base- and Mixin classes -----------------------------------------------------------
|
57
92
|
|
58
93
|
|
59
|
-
class
|
94
|
+
class Base(DeclarativeBase):
|
60
95
|
"""Base class used to initialize the declarative base for all tables."""
|
61
96
|
|
62
97
|
__tablename__: str
|
63
98
|
|
64
99
|
@classmethod
|
65
100
|
def create(cls, **kwargs):
|
66
|
-
RekordboxAgentRegistry.
|
67
|
-
|
68
|
-
|
69
|
-
RekordboxAgentRegistry.enable_tracking()
|
101
|
+
with RekordboxAgentRegistry.disabled():
|
102
|
+
# noinspection PyArgumentList
|
103
|
+
self = cls(**kwargs)
|
70
104
|
return self
|
71
105
|
|
72
106
|
@classmethod
|
@@ -77,14 +111,14 @@ class _Base(object):
|
|
77
111
|
@classmethod
|
78
112
|
def relationships(cls):
|
79
113
|
"""Returns a list of all relationship names."""
|
80
|
-
return [column.key for column in inspect(cls).relationships]
|
114
|
+
return [column.key for column in inspect(cls).relationships] # noqa
|
81
115
|
|
82
116
|
def __iter__(self):
|
83
117
|
"""Iterates over all columns and relationship names."""
|
84
118
|
insp = inspect(self.__class__)
|
85
119
|
for column in insp.c:
|
86
120
|
yield column.name
|
87
|
-
for column in insp.relationships:
|
121
|
+
for column in insp.relationships: # noqa
|
88
122
|
yield column.key
|
89
123
|
|
90
124
|
def __len__(self):
|
@@ -124,15 +158,16 @@ class _Base(object):
|
|
124
158
|
return "\n".join(lines)
|
125
159
|
|
126
160
|
|
127
|
-
Base = declarative_base(cls=_Base)
|
128
|
-
|
129
|
-
|
130
161
|
class StatsTime:
|
131
162
|
"""Mixin class for tables that only use time statistics columns."""
|
132
163
|
|
133
|
-
created_at =
|
164
|
+
created_at: Mapped[datetime] = mapped_column(
|
165
|
+
DateTime, nullable=False, default=datetime.now
|
166
|
+
)
|
134
167
|
"""The creation date of the table entry (from :class:`StatsTime`)."""
|
135
|
-
updated_at =
|
168
|
+
updated_at: Mapped[datetime] = mapped_column(
|
169
|
+
DateTime, nullable=False, default=datetime.now, onupdate=datetime.now
|
170
|
+
)
|
136
171
|
"""The last update date of the table entry (from :class:`StatsTime`)."""
|
137
172
|
|
138
173
|
|
@@ -142,24 +177,28 @@ class StatsFull:
|
|
142
177
|
ID: Column
|
143
178
|
"""The ID (primary key) of the table entry."""
|
144
179
|
|
145
|
-
UUID =
|
180
|
+
UUID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
146
181
|
"""The UUID of the table entry (from :class:`StatsFull`)"""
|
147
|
-
rb_data_status =
|
182
|
+
rb_data_status: Mapped[int] = mapped_column(Integer, default=0)
|
148
183
|
"""The data status of the table entry (from :class:`StatsFull`)."""
|
149
|
-
rb_local_data_status =
|
184
|
+
rb_local_data_status: Mapped[int] = mapped_column(Integer, default=0)
|
150
185
|
"""The local data status of the table entry (from :class:`StatsFull`)."""
|
151
|
-
rb_local_deleted =
|
186
|
+
rb_local_deleted: Mapped[int] = mapped_column(SmallInteger, default=0)
|
152
187
|
"""The local deleted status of the table entry (from :class:`StatsFull`)."""
|
153
|
-
rb_local_synced =
|
188
|
+
rb_local_synced: Mapped[int] = mapped_column(SmallInteger, default=0)
|
154
189
|
"""The local synced status of the table entry (from :class:`StatsFull`)."""
|
155
|
-
usn =
|
190
|
+
usn: Mapped[int] = mapped_column(BigInteger, default=None)
|
156
191
|
"""The USN (unique sequence number) of the table entry (from :class:`StatsFull`)."""
|
157
|
-
rb_local_usn =
|
192
|
+
rb_local_usn: Mapped[int] = mapped_column(BigInteger, default=None)
|
158
193
|
"""The local USN (unique sequence number) of the table entry
|
159
194
|
(from :class:`StatsFull`)."""
|
160
|
-
created_at =
|
195
|
+
created_at: Mapped[datetime] = mapped_column(
|
196
|
+
DateTime, nullable=False, default=datetime.now
|
197
|
+
)
|
161
198
|
"""The creation date of the table entry (from :class:`StatsFull`)."""
|
162
|
-
updated_at =
|
199
|
+
updated_at: Mapped[datetime] = mapped_column(
|
200
|
+
DateTime, nullable=False, default=datetime.now, onupdate=datetime.now
|
201
|
+
)
|
163
202
|
"""The last update date of the table entry (from :class:`StatsFull`)."""
|
164
203
|
|
165
204
|
def __repr__(self):
|
@@ -183,27 +222,27 @@ class AgentRegistry(Base, StatsTime):
|
|
183
222
|
|
184
223
|
__tablename__ = "agentRegistry"
|
185
224
|
|
186
|
-
registry_id =
|
225
|
+
registry_id: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
187
226
|
"""The ID (primary key) of the table entry."""
|
188
|
-
id_1 =
|
227
|
+
id_1: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
189
228
|
"""The first ID value of the table entry."""
|
190
|
-
id_2 =
|
229
|
+
id_2: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
191
230
|
"""The second ID value of the table entry."""
|
192
|
-
int_1 =
|
231
|
+
int_1: Mapped[int] = mapped_column(Integer, default=None)
|
193
232
|
"""The first integer value of the table entry."""
|
194
|
-
int_2 =
|
233
|
+
int_2: Mapped[int] = mapped_column(Integer, default=None)
|
195
234
|
"""The second integer value of the table entry."""
|
196
|
-
str_1 =
|
235
|
+
str_1: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
197
236
|
"""The first string value of the table entry."""
|
198
|
-
str_2 =
|
237
|
+
str_2: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
199
238
|
"""The second string value of the table entry."""
|
200
|
-
date_1 =
|
239
|
+
date_1: Mapped[datetime] = mapped_column(DateTime, default=None)
|
201
240
|
"""The first date value of the table entry."""
|
202
|
-
date_2 =
|
241
|
+
date_2: Mapped[datetime] = mapped_column(DateTime, default=None)
|
203
242
|
"""The second date value of the table entry."""
|
204
|
-
text_1 =
|
243
|
+
text_1: Mapped[str] = mapped_column(Text, default=None)
|
205
244
|
"""The first text value of the table entry."""
|
206
|
-
text_2 =
|
245
|
+
text_2: Mapped[str] = mapped_column(Text, default=None)
|
207
246
|
"""The second text value of the table entry."""
|
208
247
|
|
209
248
|
|
@@ -221,23 +260,23 @@ class CloudAgentRegistry(Base, StatsFull):
|
|
221
260
|
|
222
261
|
__tablename__ = "cloudAgentRegistry"
|
223
262
|
|
224
|
-
ID =
|
263
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
225
264
|
"""The ID (primary key) of the table entry."""
|
226
|
-
int_1 =
|
265
|
+
int_1: Mapped[int] = mapped_column(Integer, default=None)
|
227
266
|
"""The first integer value of the table entry."""
|
228
|
-
int_2 =
|
267
|
+
int_2: Mapped[int] = mapped_column(Integer, default=None)
|
229
268
|
"""The second integer value of the table entry."""
|
230
|
-
str_1 =
|
269
|
+
str_1: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
231
270
|
"""The first string value of the table entry."""
|
232
|
-
str_2 =
|
271
|
+
str_2: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
233
272
|
"""The second string value of the table entry."""
|
234
|
-
date_1 =
|
273
|
+
date_1: Mapped[datetime] = mapped_column(DateTime, default=None)
|
235
274
|
"""The first date value of the table entry."""
|
236
|
-
date_2 =
|
275
|
+
date_2: Mapped[datetime] = mapped_column(DateTime, default=None)
|
237
276
|
"""The second date value of the table entry."""
|
238
|
-
text_1 =
|
277
|
+
text_1: Mapped[str] = mapped_column(Text, default=None)
|
239
278
|
"""The first text value of the table entry."""
|
240
|
-
text_2 =
|
279
|
+
text_2: Mapped[str] = mapped_column(Text, default=None)
|
241
280
|
"""The second text value of the table entry."""
|
242
281
|
|
243
282
|
|
@@ -251,13 +290,15 @@ class ContentActiveCensor(Base, StatsFull):
|
|
251
290
|
|
252
291
|
__tablename__ = "contentActiveCensor"
|
253
292
|
|
254
|
-
ID =
|
293
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
255
294
|
"""The ID (primary key) of the table entry."""
|
256
|
-
ContentID =
|
295
|
+
ContentID: Mapped[str] = mapped_column(
|
296
|
+
VARCHAR(255), ForeignKey("djmdContent.ID"), default=None
|
297
|
+
)
|
257
298
|
"""The ID of the :class:`DjmdContent` entry this censor belongs to."""
|
258
|
-
ActiveCensors =
|
299
|
+
ActiveCensors: Mapped[str] = mapped_column(Text, default=None)
|
259
300
|
"""The active censors of the table entry."""
|
260
|
-
rb_activecensor_count =
|
301
|
+
rb_activecensor_count: Mapped[int] = mapped_column(Integer, default=None)
|
261
302
|
"""The active censor count of the table entry."""
|
262
303
|
|
263
304
|
Content = relationship("DjmdContent")
|
@@ -274,13 +315,15 @@ class ContentCue(Base, StatsFull):
|
|
274
315
|
|
275
316
|
__tablename__ = "contentCue"
|
276
317
|
|
277
|
-
ID =
|
318
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
278
319
|
"""The ID (primary key) of the table entry."""
|
279
|
-
ContentID =
|
320
|
+
ContentID: Mapped[str] = mapped_column(
|
321
|
+
VARCHAR(255), ForeignKey("djmdContent.ID"), default=None
|
322
|
+
)
|
280
323
|
"""The ID of the :class:`DjmdContent` entry this cue belongs to."""
|
281
|
-
Cues =
|
324
|
+
Cues: Mapped[str] = mapped_column(Text, default=None)
|
282
325
|
"""The cues of the table entry."""
|
283
|
-
rb_cue_count =
|
326
|
+
rb_cue_count: Mapped[int] = mapped_column(Integer, default=None)
|
284
327
|
"""The cue count of the table entry."""
|
285
328
|
|
286
329
|
Content = relationship("DjmdContent")
|
@@ -297,35 +340,37 @@ class ContentFile(Base, StatsFull):
|
|
297
340
|
|
298
341
|
__tablename__ = "contentFile"
|
299
342
|
|
300
|
-
ID =
|
343
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
301
344
|
"""The ID (primary key) of the table entry."""
|
302
|
-
ContentID =
|
345
|
+
ContentID: Mapped[str] = mapped_column(
|
346
|
+
VARCHAR(255), ForeignKey("djmdContent.ID"), default=None
|
347
|
+
)
|
303
348
|
"""The ID of the :class:`DjmdContent` entry this file belongs to."""
|
304
|
-
Path =
|
349
|
+
Path: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
305
350
|
"""The path of the file."""
|
306
|
-
Hash =
|
351
|
+
Hash: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
307
352
|
"""The hash of the file."""
|
308
|
-
Size =
|
353
|
+
Size: Mapped[int] = mapped_column(Integer, default=None)
|
309
354
|
"""The size of the file."""
|
310
|
-
rb_local_path =
|
355
|
+
rb_local_path: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
311
356
|
"""The local path of the file."""
|
312
|
-
rb_insync_hash =
|
357
|
+
rb_insync_hash: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
313
358
|
"""The in-sync hash of the file."""
|
314
|
-
rb_insync_local_usn =
|
359
|
+
rb_insync_local_usn: Mapped[int] = mapped_column(BigInteger, default=None)
|
315
360
|
"""The in-sync local USN (unique sequence number) of the file."""
|
316
|
-
rb_file_hash_dirty =
|
361
|
+
rb_file_hash_dirty: Mapped[int] = mapped_column(Integer, default=0)
|
317
362
|
"""The file hash dirty flag of the file."""
|
318
|
-
rb_local_file_status =
|
363
|
+
rb_local_file_status: Mapped[int] = mapped_column(Integer, default=0)
|
319
364
|
"""The local file status of the file."""
|
320
|
-
rb_in_progress =
|
365
|
+
rb_in_progress: Mapped[int] = mapped_column(SmallInteger, default=0)
|
321
366
|
"""The in progress flag of the file."""
|
322
|
-
rb_process_type =
|
367
|
+
rb_process_type: Mapped[int] = mapped_column(Integer, default=0)
|
323
368
|
"""The process type of the file."""
|
324
|
-
rb_temp_path =
|
369
|
+
rb_temp_path: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
325
370
|
"""The temporary path of the file."""
|
326
|
-
rb_priority =
|
371
|
+
rb_priority: Mapped[int] = mapped_column(Integer, default=50)
|
327
372
|
"""The priority of the file."""
|
328
|
-
rb_file_size_dirty =
|
373
|
+
rb_file_size_dirty: Mapped[int] = mapped_column(Integer, default=0)
|
329
374
|
"""The file size dirty flag of the file."""
|
330
375
|
|
331
376
|
Content = relationship("DjmdContent")
|
@@ -342,19 +387,21 @@ class DjmdActiveCensor(Base, StatsFull):
|
|
342
387
|
|
343
388
|
__tablename__ = "djmdActiveCensor"
|
344
389
|
|
345
|
-
ID =
|
390
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
346
391
|
"""The ID (primary key) of the table entry."""
|
347
|
-
ContentID =
|
392
|
+
ContentID: Mapped[str] = mapped_column(
|
393
|
+
VARCHAR(255), ForeignKey("djmdContent.ID"), default=None
|
394
|
+
)
|
348
395
|
"""The ID of the :class:`DjmdContent` entry this censor belongs to."""
|
349
|
-
InMsec =
|
396
|
+
InMsec: Mapped[int] = mapped_column(Integer, default=None)
|
350
397
|
"""The in time of the censor (in milliseconds)."""
|
351
|
-
OutMsec =
|
398
|
+
OutMsec: Mapped[int] = mapped_column(Integer, default=None)
|
352
399
|
"""The out time of the censor (in milliseconds)."""
|
353
|
-
Info =
|
400
|
+
Info: Mapped[int] = mapped_column(Integer, default=None)
|
354
401
|
"""Additional info of the censor."""
|
355
|
-
ParameterList =
|
402
|
+
ParameterList: Mapped[str] = mapped_column(Text, default=None)
|
356
403
|
"""The parameter list of the censor."""
|
357
|
-
ContentUUID =
|
404
|
+
ContentUUID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
358
405
|
"""The UUID of the :class:`DjmdContent` entry this censor belongs to."""
|
359
406
|
|
360
407
|
Content = relationship("DjmdContent")
|
@@ -371,17 +418,19 @@ class DjmdAlbum(Base, StatsFull):
|
|
371
418
|
|
372
419
|
__tablename__ = "djmdAlbum"
|
373
420
|
|
374
|
-
ID =
|
421
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
375
422
|
"""The ID (primary key) of the table entry."""
|
376
|
-
Name =
|
423
|
+
Name: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
377
424
|
"""The name of the album."""
|
378
|
-
AlbumArtistID =
|
425
|
+
AlbumArtistID: Mapped[str] = mapped_column(
|
426
|
+
VARCHAR(255), ForeignKey("djmdArtist.ID"), default=None
|
427
|
+
)
|
379
428
|
"""The ID of the :class:`DjmdArtist` entry of the artist of this album."""
|
380
|
-
ImagePath =
|
429
|
+
ImagePath: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
381
430
|
"""The path of the image of the album."""
|
382
|
-
Compilation =
|
431
|
+
Compilation: Mapped[int] = mapped_column(Integer, default=None)
|
383
432
|
"""The compilation flag of the album."""
|
384
|
-
SearchStr =
|
433
|
+
SearchStr: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
385
434
|
"""The search string of the album."""
|
386
435
|
|
387
436
|
AlbumArtist = relationship("DjmdArtist")
|
@@ -397,11 +446,11 @@ class DjmdArtist(Base, StatsFull):
|
|
397
446
|
|
398
447
|
__tablename__ = "djmdArtist"
|
399
448
|
|
400
|
-
ID =
|
449
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
401
450
|
"""The ID (primary key) of the table entry."""
|
402
|
-
Name =
|
451
|
+
Name: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
403
452
|
"""The name of the artist."""
|
404
|
-
SearchStr =
|
453
|
+
SearchStr: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
405
454
|
"""The search string of the artist."""
|
406
455
|
|
407
456
|
def __repr__(self):
|
@@ -419,18 +468,20 @@ class DjmdCategory(Base, StatsFull):
|
|
419
468
|
|
420
469
|
__tablename__ = "djmdCategory"
|
421
470
|
|
422
|
-
ID =
|
471
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
423
472
|
"""The ID (primary key) of the table entry."""
|
424
|
-
MenuItemID =
|
473
|
+
MenuItemID: Mapped[str] = mapped_column(
|
474
|
+
VARCHAR(255), ForeignKey("djmdMenuItems.ID"), default=None
|
475
|
+
)
|
425
476
|
"""The ID of the :class:`DjmdMenuItems` entry belonging to the category."""
|
426
|
-
Seq =
|
477
|
+
Seq: Mapped[int] = mapped_column(Integer, default=None)
|
427
478
|
"""The sequence of the category (for ordering)."""
|
428
|
-
Disable =
|
479
|
+
Disable: Mapped[int] = mapped_column(Integer, default=None)
|
429
480
|
"""The disable flag of the category."""
|
430
|
-
InfoOrder =
|
481
|
+
InfoOrder: Mapped[int] = mapped_column(Integer, default=None)
|
431
482
|
"""Information for ordering the categories."""
|
432
483
|
|
433
|
-
MenuItem = relationship("DjmdMenuItems", foreign_keys=
|
484
|
+
MenuItem = relationship("DjmdMenuItems", foreign_keys=MenuItemID)
|
434
485
|
"""The menu item entry of the category (links to :class:`DjmdMenuItems`)."""
|
435
486
|
|
436
487
|
|
@@ -439,13 +490,13 @@ class DjmdColor(Base, StatsFull):
|
|
439
490
|
|
440
491
|
__tablename__ = "djmdColor"
|
441
492
|
|
442
|
-
ID =
|
493
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
443
494
|
"""The ID (primary key) of the table entry."""
|
444
|
-
ColorCode =
|
495
|
+
ColorCode: Mapped[int] = mapped_column(Integer, default=None)
|
445
496
|
"""The color code of the color."""
|
446
|
-
SortKey =
|
497
|
+
SortKey: Mapped[int] = mapped_column(Integer, default=None)
|
447
498
|
"""The sort key of the color."""
|
448
|
-
Commnt =
|
499
|
+
Commnt: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
449
500
|
"""The comment (name) of the color."""
|
450
501
|
|
451
502
|
def __repr__(self):
|
@@ -472,162 +523,182 @@ class DjmdContent(Base, StatsFull):
|
|
472
523
|
|
473
524
|
__tablename__ = "djmdContent"
|
474
525
|
|
475
|
-
ID =
|
526
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
476
527
|
"""The ID (primary key) of the track."""
|
477
|
-
FolderPath =
|
528
|
+
FolderPath: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
478
529
|
"""The full path of the file corresponding to the content entry."""
|
479
|
-
FileNameL =
|
530
|
+
FileNameL: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
480
531
|
"""The long file name of the file corresponding to the content entry."""
|
481
|
-
FileNameS =
|
532
|
+
FileNameS: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
482
533
|
"""The short file name of the file corresponding to the content entry."""
|
483
|
-
Title =
|
534
|
+
Title: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
484
535
|
"""The title of the track."""
|
485
|
-
ArtistID =
|
536
|
+
ArtistID: Mapped[str] = mapped_column(
|
537
|
+
VARCHAR(255), ForeignKey("djmdArtist.ID"), default=None
|
538
|
+
)
|
486
539
|
"""The ID of the :class:`DjmdArtist` entry of the artist of this track."""
|
487
|
-
AlbumID =
|
540
|
+
AlbumID: Mapped[str] = mapped_column(
|
541
|
+
VARCHAR(255), ForeignKey("djmdAlbum.ID"), default=None
|
542
|
+
)
|
488
543
|
"""The ID of the :class:`DjmdAlbum` entry of the album of this track."""
|
489
|
-
GenreID =
|
544
|
+
GenreID: Mapped[str] = mapped_column(
|
545
|
+
VARCHAR(255), ForeignKey("djmdGenre.ID"), default=None
|
546
|
+
)
|
490
547
|
"""The ID of the :class:`DjmdGenre` entry of the genre of this track."""
|
491
|
-
BPM =
|
548
|
+
BPM: Mapped[int] = mapped_column(Integer, default=None)
|
492
549
|
"""The BPM (beats per minute) of the track."""
|
493
|
-
Length =
|
550
|
+
Length: Mapped[int] = mapped_column(Integer, default=None)
|
494
551
|
"""The length of the track."""
|
495
|
-
TrackNo =
|
552
|
+
TrackNo: Mapped[int] = mapped_column(Integer, default=None)
|
496
553
|
"""The track number of the track."""
|
497
|
-
BitRate =
|
554
|
+
BitRate: Mapped[int] = mapped_column(Integer, default=None)
|
498
555
|
"""The bit rate of the track."""
|
499
|
-
BitDepth =
|
556
|
+
BitDepth: Mapped[int] = mapped_column(Integer, default=None)
|
500
557
|
"""The bit depth of the track."""
|
501
|
-
Commnt =
|
558
|
+
Commnt: Mapped[str] = mapped_column(Text, default=None)
|
502
559
|
"""The comment of the track."""
|
503
|
-
FileType =
|
560
|
+
FileType: Mapped[int] = mapped_column(Integer, default=None)
|
504
561
|
"""The file type of the track."""
|
505
|
-
Rating =
|
562
|
+
Rating: Mapped[int] = mapped_column(Integer, default=None)
|
506
563
|
"""The rating of the track."""
|
507
|
-
ReleaseYear =
|
564
|
+
ReleaseYear: Mapped[int] = mapped_column(Integer, default=None)
|
508
565
|
"""The release year of the track."""
|
509
|
-
RemixerID =
|
566
|
+
RemixerID: Mapped[str] = mapped_column(
|
567
|
+
VARCHAR(255), ForeignKey("djmdArtist.ID"), default=None
|
568
|
+
)
|
510
569
|
"""The ID of the :class:`DjmdArtist` entry of the remixer of this track."""
|
511
|
-
LabelID =
|
570
|
+
LabelID: Mapped[str] = mapped_column(
|
571
|
+
VARCHAR(255), ForeignKey("djmdLabel.ID"), default=None
|
572
|
+
)
|
512
573
|
"""The ID of the :class:`DjmdLabel` entry of the label of this track."""
|
513
|
-
OrgArtistID =
|
574
|
+
OrgArtistID: Mapped[str] = mapped_column(
|
575
|
+
VARCHAR(255), ForeignKey("djmdArtist.ID"), default=None
|
576
|
+
)
|
514
577
|
"""The ID of the :class:`DjmdArtist` entry of the original artist of this track."""
|
515
|
-
KeyID =
|
578
|
+
KeyID: Mapped[str] = mapped_column(
|
579
|
+
VARCHAR(255), ForeignKey("djmdKey.ID"), default=None
|
580
|
+
)
|
516
581
|
"""The ID of the :class:`DjmdKey` entry of the key of this track."""
|
517
|
-
StockDate =
|
582
|
+
StockDate: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
518
583
|
"""The stock date of the track."""
|
519
|
-
ColorID =
|
584
|
+
ColorID: Mapped[str] = mapped_column(
|
585
|
+
VARCHAR(255), ForeignKey("djmdColor.ID"), default=None
|
586
|
+
)
|
520
587
|
"""The ID of the :class:`DjmdColor` entry of the color of this track."""
|
521
|
-
DJPlayCount =
|
588
|
+
DJPlayCount: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
522
589
|
"""The play count of the track."""
|
523
|
-
ImagePath =
|
590
|
+
ImagePath: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
524
591
|
"""The path of the image of the track."""
|
525
|
-
MasterDBID =
|
592
|
+
MasterDBID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
526
593
|
"""The master database ID of the track."""
|
527
|
-
MasterSongID =
|
594
|
+
MasterSongID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
528
595
|
"""The master song ID of the track."""
|
529
|
-
AnalysisDataPath =
|
596
|
+
AnalysisDataPath: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
530
597
|
"""The path of the analysis data (ANLZ) of the track."""
|
531
|
-
SearchStr =
|
598
|
+
SearchStr: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
532
599
|
"""The search string of the track."""
|
533
|
-
FileSize =
|
600
|
+
FileSize: Mapped[int] = mapped_column(Integer, default=None)
|
534
601
|
"""The file size of the track."""
|
535
|
-
DiscNo =
|
602
|
+
DiscNo: Mapped[int] = mapped_column(Integer, default=None)
|
536
603
|
"""The number of the disc of the album of the track."""
|
537
|
-
ComposerID =
|
604
|
+
ComposerID: Mapped[str] = mapped_column(
|
605
|
+
VARCHAR(255), ForeignKey("djmdArtist.ID"), default=None
|
606
|
+
)
|
538
607
|
"""The ID of the :class:`DjmdArtist` entry of the composer of this track."""
|
539
|
-
Subtitle =
|
608
|
+
Subtitle: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
540
609
|
"""The subtitle of the track."""
|
541
|
-
SampleRate =
|
610
|
+
SampleRate: Mapped[int] = mapped_column(Integer, default=None)
|
542
611
|
"""The sample rate of the track in Hz."""
|
543
|
-
DisableQuantize =
|
612
|
+
DisableQuantize: Mapped[int] = mapped_column(Integer, default=None)
|
544
613
|
"""Individual quantize status of the track."""
|
545
|
-
Analysed =
|
614
|
+
Analysed: Mapped[int] = mapped_column(Integer, default=None)
|
546
615
|
"""The analysis status of the track."""
|
547
|
-
ReleaseDate =
|
616
|
+
ReleaseDate: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
548
617
|
"""The release date of the track."""
|
549
|
-
DateCreated =
|
618
|
+
DateCreated: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
550
619
|
"""The date the track was created."""
|
551
|
-
ContentLink =
|
620
|
+
ContentLink: Mapped[int] = mapped_column(Integer, default=None)
|
552
621
|
"""The content link of the track."""
|
553
|
-
Tag =
|
622
|
+
Tag: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
554
623
|
"""The tag of the track."""
|
555
|
-
ModifiedByRBM =
|
624
|
+
ModifiedByRBM: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
556
625
|
"""The modified by RBM status of the track."""
|
557
|
-
HotCueAutoLoad =
|
626
|
+
HotCueAutoLoad: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
558
627
|
"""The hot cue auto load status of the track."""
|
559
|
-
DeliveryControl =
|
628
|
+
DeliveryControl: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
560
629
|
"""The delivery control status of the track."""
|
561
|
-
DeliveryComment =
|
630
|
+
DeliveryComment: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
562
631
|
"""The delivery comment of the track."""
|
563
|
-
CueUpdated =
|
632
|
+
CueUpdated: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
564
633
|
"""The cue updated status of the track."""
|
565
|
-
AnalysisUpdated =
|
634
|
+
AnalysisUpdated: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
566
635
|
"""The analysis updated status of the track."""
|
567
|
-
TrackInfoUpdated =
|
636
|
+
TrackInfoUpdated: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
568
637
|
"""The track info updated status of the track."""
|
569
|
-
Lyricist =
|
638
|
+
Lyricist: Mapped[str] = mapped_column(
|
639
|
+
VARCHAR(255), ForeignKey("djmdArtist.ID"), default=None
|
640
|
+
)
|
570
641
|
"""The ID of the :class:`DjmdArtist` entry of the lyricist of this track."""
|
571
|
-
ISRC =
|
642
|
+
ISRC: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
572
643
|
"""The ISRC of the track."""
|
573
|
-
SamplerTrackInfo =
|
644
|
+
SamplerTrackInfo: Mapped[int] = mapped_column(Integer, default=None)
|
574
645
|
"""The sampler track info of the track."""
|
575
|
-
SamplerPlayOffset =
|
646
|
+
SamplerPlayOffset: Mapped[int] = mapped_column(Integer, default=None)
|
576
647
|
"""The sampler play offset of the track."""
|
577
|
-
SamplerGain =
|
648
|
+
SamplerGain: Mapped[float] = mapped_column(Float, default=None)
|
578
649
|
"""The sampler gain of the track."""
|
579
|
-
VideoAssociate =
|
650
|
+
VideoAssociate: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
580
651
|
"""The video associate of the track."""
|
581
|
-
LyricStatus =
|
652
|
+
LyricStatus: Mapped[int] = mapped_column(Integer, default=None)
|
582
653
|
"""The lyric status of the track."""
|
583
|
-
ServiceID =
|
654
|
+
ServiceID: Mapped[int] = mapped_column(Integer, default=None)
|
584
655
|
"""The service ID of the track."""
|
585
|
-
OrgFolderPath =
|
656
|
+
OrgFolderPath: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
586
657
|
"""The original folder path of the track."""
|
587
|
-
Reserved1 =
|
658
|
+
Reserved1: Mapped[str] = mapped_column(Text, default=None)
|
588
659
|
"""Reserved field 1."""
|
589
|
-
Reserved2 =
|
660
|
+
Reserved2: Mapped[str] = mapped_column(Text, default=None)
|
590
661
|
"""Reserved field 2."""
|
591
|
-
Reserved3 =
|
662
|
+
Reserved3: Mapped[str] = mapped_column(Text, default=None)
|
592
663
|
"""Reserved field 3."""
|
593
|
-
Reserved4 =
|
664
|
+
Reserved4: Mapped[str] = mapped_column(Text, default=None)
|
594
665
|
"""Reserved field 4."""
|
595
|
-
ExtInfo =
|
666
|
+
ExtInfo: Mapped[str] = mapped_column(Text, default=None)
|
596
667
|
"""The extended information of the track."""
|
597
|
-
rb_file_id =
|
668
|
+
rb_file_id: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
598
669
|
"""The file ID used by Rekordbox of the track."""
|
599
|
-
DeviceID =
|
670
|
+
DeviceID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
600
671
|
"""The device ID of the track."""
|
601
|
-
rb_LocalFolderPath =
|
672
|
+
rb_LocalFolderPath: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
602
673
|
"""The local folder path used by Rekordbox of the track."""
|
603
|
-
SrcID =
|
674
|
+
SrcID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
604
675
|
"""The ID of the source of the track."""
|
605
|
-
SrcTitle =
|
676
|
+
SrcTitle: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
606
677
|
"""The title of the source of the track."""
|
607
|
-
SrcArtistName =
|
678
|
+
SrcArtistName: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
608
679
|
"""The artist name of the source of the track."""
|
609
|
-
SrcAlbumName =
|
680
|
+
SrcAlbumName: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
610
681
|
"""The album name of the source of the track."""
|
611
|
-
SrcLength =
|
682
|
+
SrcLength: Mapped[int] = mapped_column(Integer, default=None)
|
612
683
|
"""The length of the source of the track."""
|
613
684
|
|
614
|
-
Artist = relationship("DjmdArtist", foreign_keys=
|
685
|
+
Artist = relationship("DjmdArtist", foreign_keys=ArtistID)
|
615
686
|
"""The artist entry of the track (links to :class:`DjmdArtists`)."""
|
616
|
-
Album = relationship("DjmdAlbum", foreign_keys=
|
687
|
+
Album = relationship("DjmdAlbum", foreign_keys=AlbumID)
|
617
688
|
"""The album entry of the track (links to :class:`DjmdAlbum`)."""
|
618
|
-
Genre = relationship("DjmdGenre", foreign_keys=
|
689
|
+
Genre = relationship("DjmdGenre", foreign_keys=GenreID)
|
619
690
|
"""The genre entry of the track (links to :class:`DjmdGenre`)."""
|
620
|
-
Remixer = relationship("DjmdArtist", foreign_keys=
|
691
|
+
Remixer = relationship("DjmdArtist", foreign_keys=RemixerID)
|
621
692
|
"""The remixer entry of the track (links to :class:`DjmdArtist`)."""
|
622
|
-
Label = relationship("DjmdLabel", foreign_keys=
|
693
|
+
Label = relationship("DjmdLabel", foreign_keys=LabelID)
|
623
694
|
"""The label entry of the track (links to :class:`DjmdLabel`)."""
|
624
|
-
OrgArtist = relationship("DjmdArtist", foreign_keys=
|
695
|
+
OrgArtist = relationship("DjmdArtist", foreign_keys=OrgArtistID)
|
625
696
|
"""The original artist entry of the track (links to :class:`DjmdArtist`)."""
|
626
|
-
Key = relationship("DjmdKey", foreign_keys=
|
697
|
+
Key = relationship("DjmdKey", foreign_keys=KeyID)
|
627
698
|
"""The key entry of the track (links to :class:`DjmdKey`)."""
|
628
|
-
Color = relationship("DjmdColor", foreign_keys=
|
699
|
+
Color = relationship("DjmdColor", foreign_keys=ColorID)
|
629
700
|
"""The color entry of the track (links to :class:`DjmdColor`)."""
|
630
|
-
Composer = relationship("DjmdArtist", foreign_keys=
|
701
|
+
Composer = relationship("DjmdArtist", foreign_keys=ComposerID)
|
631
702
|
"""The composer entry of the track (links to :class:`DjmdArtist`)."""
|
632
703
|
|
633
704
|
def __repr__(self):
|
@@ -717,48 +788,52 @@ class DjmdCue(Base, StatsFull):
|
|
717
788
|
|
718
789
|
__tablename__ = "djmdCue"
|
719
790
|
|
720
|
-
ID =
|
791
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
721
792
|
"""The ID (primary key) of the table entry."""
|
722
|
-
ContentID =
|
793
|
+
ContentID: Mapped[str] = mapped_column(
|
794
|
+
VARCHAR(255), ForeignKey("djmdContent.ID"), default=None
|
795
|
+
)
|
723
796
|
"""The ID of the content (:class:`DjmdContent`) containing the cue point."""
|
724
|
-
InMsec =
|
797
|
+
InMsec: Mapped[int] = mapped_column(Integer, default=None)
|
725
798
|
"""The in point of the cue point in milliseconds."""
|
726
|
-
InFrame =
|
799
|
+
InFrame: Mapped[int] = mapped_column(Integer, default=None)
|
727
800
|
"""The in point of the cue point in frames."""
|
728
|
-
InMpegFrame =
|
801
|
+
InMpegFrame: Mapped[int] = mapped_column(Integer, default=None)
|
729
802
|
"""The in point of the cue point in MPEG frames."""
|
730
|
-
InMpegAbs =
|
803
|
+
InMpegAbs: Mapped[int] = mapped_column(Integer, default=None)
|
731
804
|
"""The in point of the cue point in MPEG absolute."""
|
732
|
-
OutMsec =
|
805
|
+
OutMsec: Mapped[int] = mapped_column(Integer, default=None)
|
733
806
|
"""The out point of the cue point in milliseconds (for loops)."""
|
734
|
-
OutFrame =
|
807
|
+
OutFrame: Mapped[int] = mapped_column(Integer, default=None)
|
735
808
|
"""The out point of the cue point in frames (for loops)."""
|
736
|
-
OutMpegFrame =
|
809
|
+
OutMpegFrame: Mapped[int] = mapped_column(Integer, default=None)
|
737
810
|
"""The out point of the cue point in MPEG frames (for loops)."""
|
738
|
-
OutMpegAbs =
|
811
|
+
OutMpegAbs: Mapped[int] = mapped_column(Integer, default=None)
|
739
812
|
"""The out point of the cue point in MPEG absolute (for loops)."""
|
740
|
-
Kind =
|
813
|
+
Kind: Mapped[int] = mapped_column(Integer, default=None)
|
741
814
|
"""The kind of the cue point (Cue=0, Fade-In=0, Fade-Out=0, Load=3, Loop=4)."""
|
742
|
-
Color =
|
815
|
+
Color: Mapped[int] = mapped_column(Integer, default=None)
|
743
816
|
"""The color of the cue point. (-1 if no color)"""
|
744
|
-
ColorTableIndex =
|
817
|
+
ColorTableIndex: Mapped[int] = mapped_column(Integer, default=None)
|
745
818
|
"""The color table index of the cue point."""
|
746
|
-
ActiveLoop =
|
819
|
+
ActiveLoop: Mapped[int] = mapped_column(Integer, default=None)
|
747
820
|
"""The active loop of the cue point."""
|
748
|
-
Comment =
|
821
|
+
Comment: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
749
822
|
"""The comment of the cue point."""
|
750
|
-
BeatLoopSize =
|
823
|
+
BeatLoopSize: Mapped[int] = mapped_column(Integer, default=None)
|
751
824
|
"""The beat loop size of the cue point."""
|
752
|
-
CueMicrosec =
|
825
|
+
CueMicrosec: Mapped[int] = mapped_column(Integer, default=None)
|
753
826
|
"""The cue microsecond of the cue point."""
|
754
|
-
InPointSeekInfo =
|
827
|
+
InPointSeekInfo: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
755
828
|
"""The in point seek info of the cue point."""
|
756
|
-
OutPointSeekInfo =
|
829
|
+
OutPointSeekInfo: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
757
830
|
"""The out point seek info of the cue point."""
|
758
|
-
ContentUUID =
|
831
|
+
ContentUUID: Mapped[str] = mapped_column(
|
832
|
+
VARCHAR(255), ForeignKey("djmdContent.UUID"), default=None
|
833
|
+
)
|
759
834
|
"""The UUID of the content (:class:`DjmdContent`) containing the cue point."""
|
760
835
|
|
761
|
-
Content = relationship("DjmdContent", foreign_keys=
|
836
|
+
Content = relationship("DjmdContent", foreign_keys=ContentID)
|
762
837
|
"""The content entry of the cue point (links to :class:`DjmdContent`)."""
|
763
838
|
|
764
839
|
|
@@ -767,11 +842,11 @@ class DjmdDevice(Base, StatsFull):
|
|
767
842
|
|
768
843
|
__tablename__ = "djmdDevice"
|
769
844
|
|
770
|
-
ID =
|
845
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
771
846
|
"""The ID (primary key) of the table entry."""
|
772
|
-
MasterDBID =
|
847
|
+
MasterDBID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
773
848
|
"""The ID of the master database."""
|
774
|
-
Name =
|
849
|
+
Name: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
775
850
|
"""The name of the device."""
|
776
851
|
|
777
852
|
def __repr__(self):
|
@@ -784,9 +859,9 @@ class DjmdGenre(Base, StatsFull):
|
|
784
859
|
|
785
860
|
__tablename__ = "djmdGenre"
|
786
861
|
|
787
|
-
ID =
|
862
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
788
863
|
"""The ID (primary key) of the table entry."""
|
789
|
-
Name =
|
864
|
+
Name: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
790
865
|
"""The name of the genre."""
|
791
866
|
|
792
867
|
def __repr__(self):
|
@@ -804,17 +879,19 @@ class DjmdHistory(Base, StatsFull):
|
|
804
879
|
|
805
880
|
__tablename__ = "djmdHistory"
|
806
881
|
|
807
|
-
ID =
|
882
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
808
883
|
"""The ID (primary key) of the table entry (:class:`DjmdHistory`)."""
|
809
|
-
Seq =
|
884
|
+
Seq: Mapped[int] = mapped_column(Integer, default=None)
|
810
885
|
"""The sequence of the history playlist (for ordering)."""
|
811
|
-
Name =
|
886
|
+
Name: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
812
887
|
"""The name of the history playlist."""
|
813
|
-
Attribute =
|
888
|
+
Attribute: Mapped[int] = mapped_column(Integer, default=None)
|
814
889
|
"""The attributes of the history playlist"""
|
815
|
-
ParentID =
|
890
|
+
ParentID: Mapped[str] = mapped_column(
|
891
|
+
VARCHAR(255), ForeignKey("djmdHistory.ID"), default=None
|
892
|
+
)
|
816
893
|
"""The ID of the parent history playlist (:class:`DjmdHistory`)."""
|
817
|
-
DateCreated =
|
894
|
+
DateCreated: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
818
895
|
"""The date the history playlist was created."""
|
819
896
|
|
820
897
|
Songs = relationship("DjmdSongHistory", back_populates="History")
|
@@ -843,13 +920,17 @@ class DjmdSongHistory(Base, StatsFull):
|
|
843
920
|
|
844
921
|
__tablename__ = "djmdSongHistory"
|
845
922
|
|
846
|
-
ID =
|
923
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
847
924
|
|
848
|
-
HistoryID =
|
925
|
+
HistoryID: Mapped[str] = mapped_column(
|
926
|
+
VARCHAR(255), ForeignKey("djmdHistory.ID"), default=None
|
927
|
+
)
|
849
928
|
"""The ID of the history playlist (:class:`DjmdHistory`)."""
|
850
|
-
ContentID =
|
929
|
+
ContentID: Mapped[str] = mapped_column(
|
930
|
+
VARCHAR(255), ForeignKey("djmdContent.ID"), default=None
|
931
|
+
)
|
851
932
|
"""The ID of the content (:class:`DjmdContent`)."""
|
852
|
-
TrackNo =
|
933
|
+
TrackNo: Mapped[int] = mapped_column(Integer, default=None)
|
853
934
|
"""The track number of the song in the history playlist."""
|
854
935
|
|
855
936
|
History = relationship("DjmdHistory", back_populates="Songs")
|
@@ -868,17 +949,19 @@ class DjmdHotCueBanklist(Base, StatsFull):
|
|
868
949
|
|
869
950
|
__tablename__ = "djmdHotCueBanklist"
|
870
951
|
|
871
|
-
ID =
|
952
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
872
953
|
"""The ID (primary key) of the table entry (:class:`DjmdHotCueBanklist`)"""
|
873
|
-
Seq =
|
954
|
+
Seq: Mapped[int] = mapped_column(Integer, default=None)
|
874
955
|
"""The sequence of the hot-cue banklist (for ordering)."""
|
875
|
-
Name =
|
956
|
+
Name: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
876
957
|
"""The name of the hot-cue banklist."""
|
877
|
-
ImagePath =
|
958
|
+
ImagePath: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
878
959
|
"""The path to the image of the hot-cue banklist."""
|
879
|
-
Attribute =
|
960
|
+
Attribute: Mapped[int] = mapped_column(Integer, default=None)
|
880
961
|
"""The attributes of the hot cue banklist."""
|
881
|
-
ParentID =
|
962
|
+
ParentID: Mapped[str] = mapped_column(
|
963
|
+
VARCHAR(255), ForeignKey("djmdHotCueBanklist.ID"), default=None
|
964
|
+
)
|
882
965
|
"""The ID of the parent hot-cue banklist (:class:`DjmdHotCueBanklist`)."""
|
883
966
|
|
884
967
|
Children = relationship(
|
@@ -905,51 +988,53 @@ class DjmdSongHotCueBanklist(Base, StatsFull):
|
|
905
988
|
|
906
989
|
__tablename__ = "djmdSongHotCueBanklist"
|
907
990
|
|
908
|
-
ID =
|
991
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
909
992
|
"""The ID (primary key) of the table entry."""
|
910
|
-
HotCueBanklistID =
|
993
|
+
HotCueBanklistID: Mapped[str] = mapped_column(
|
911
994
|
VARCHAR(255), ForeignKey("djmdHotCueBanklist.ID"), default=None
|
912
995
|
)
|
913
996
|
"""The ID of the hot cue banklist (:class:`DjmdHotCueBanklist`)."""
|
914
|
-
ContentID =
|
997
|
+
ContentID: Mapped[str] = mapped_column(
|
998
|
+
VARCHAR(255), ForeignKey("djmdContent.ID"), default=None
|
999
|
+
)
|
915
1000
|
"""The ID of the content (:class:`DjmdContent`)."""
|
916
|
-
TrackNo =
|
1001
|
+
TrackNo: Mapped[int] = mapped_column(Integer, default=None)
|
917
1002
|
"""The track number of the hot-cue in the hot cue banklist."""
|
918
|
-
CueID =
|
1003
|
+
CueID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
919
1004
|
"""The ID of the hot-cue."""
|
920
|
-
InMsec =
|
1005
|
+
InMsec: Mapped[int] = mapped_column(Integer, default=None)
|
921
1006
|
"""The in point of the hot-cue in milliseconds."""
|
922
|
-
InFrame =
|
1007
|
+
InFrame: Mapped[int] = mapped_column(Integer, default=None)
|
923
1008
|
"""The in point of the hot-cue in frames."""
|
924
|
-
InMpegFrame =
|
1009
|
+
InMpegFrame: Mapped[int] = mapped_column(Integer, default=None)
|
925
1010
|
"""The in point of the hot-cue in MPEG frames."""
|
926
|
-
InMpegAbs =
|
1011
|
+
InMpegAbs: Mapped[int] = mapped_column(Integer, default=None)
|
927
1012
|
"""The in point of the hot-cue in MPEG absolute."""
|
928
|
-
OutMsec =
|
1013
|
+
OutMsec: Mapped[int] = mapped_column(Integer, default=None)
|
929
1014
|
"""The out point of the hot-cue in milliseconds (for loops)."""
|
930
|
-
OutFrame =
|
1015
|
+
OutFrame: Mapped[int] = mapped_column(Integer, default=None)
|
931
1016
|
"""The out point of the hot-cue in frames (for loops)."""
|
932
|
-
OutMpegFrame =
|
1017
|
+
OutMpegFrame: Mapped[int] = mapped_column(Integer, default=None)
|
933
1018
|
"""The out point of the hot-cue in MPEG frames (for loops)."""
|
934
|
-
OutMpegAbs =
|
1019
|
+
OutMpegAbs: Mapped[int] = mapped_column(Integer, default=None)
|
935
1020
|
"""The out point of the hot-cue in MPEG absolute (for loops)."""
|
936
|
-
Color =
|
1021
|
+
Color: Mapped[int] = mapped_column(Integer, default=None)
|
937
1022
|
"""The color of the hot-cue."""
|
938
|
-
ColorTableIndex =
|
1023
|
+
ColorTableIndex: Mapped[int] = mapped_column(Integer, default=None)
|
939
1024
|
"""The color table index of the hot-cue."""
|
940
|
-
ActiveLoop =
|
1025
|
+
ActiveLoop: Mapped[int] = mapped_column(Integer, default=None)
|
941
1026
|
"""The active loop flag of the hot-cue."""
|
942
|
-
Comment =
|
1027
|
+
Comment: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
943
1028
|
"""The comment of the hot-cue."""
|
944
|
-
BeatLoopSize =
|
1029
|
+
BeatLoopSize: Mapped[int] = mapped_column(Integer, default=None)
|
945
1030
|
"""The beat loop size of the hot-cue."""
|
946
|
-
CueMicrosec =
|
1031
|
+
CueMicrosec: Mapped[int] = mapped_column(Integer, default=None)
|
947
1032
|
"""The cue microsecond of the hot-cue."""
|
948
|
-
InPointSeekInfo =
|
1033
|
+
InPointSeekInfo: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
949
1034
|
"""The in point seek info of the hot-cue."""
|
950
|
-
OutPointSeekInfo =
|
1035
|
+
OutPointSeekInfo: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
951
1036
|
"""The out point seek info of the hot-cue."""
|
952
|
-
HotCueBanklistUUID =
|
1037
|
+
HotCueBanklistUUID: Mapped[str] = mapped_column(
|
953
1038
|
VARCHAR(255), ForeignKey("djmdHotCueBanklist.UUID"), default=None
|
954
1039
|
)
|
955
1040
|
"""The UUID of the hot-cue banklist (links to :class:`DjmdHotCueBanklist`)."""
|
@@ -963,11 +1048,11 @@ class DjmdKey(Base, StatsFull):
|
|
963
1048
|
|
964
1049
|
__tablename__ = "djmdKey"
|
965
1050
|
|
966
|
-
ID =
|
1051
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
967
1052
|
"""The ID (primary key) of the table entry."""
|
968
|
-
ScaleName =
|
1053
|
+
ScaleName: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
969
1054
|
"""The scale (name) of the key."""
|
970
|
-
Seq =
|
1055
|
+
Seq: Mapped[int] = mapped_column(Integer, default=None)
|
971
1056
|
"""The sequence of the key (for ordering)."""
|
972
1057
|
|
973
1058
|
def __repr__(self):
|
@@ -980,9 +1065,9 @@ class DjmdLabel(Base, StatsFull):
|
|
980
1065
|
|
981
1066
|
__tablename__ = "djmdLabel"
|
982
1067
|
|
983
|
-
ID =
|
1068
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
984
1069
|
"""The ID (primary key) of the table entry."""
|
985
|
-
Name =
|
1070
|
+
Name: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
986
1071
|
"""The name of the label."""
|
987
1072
|
|
988
1073
|
def __repr__(self):
|
@@ -995,11 +1080,11 @@ class DjmdMenuItems(Base, StatsFull):
|
|
995
1080
|
|
996
1081
|
__tablename__ = "djmdMenuItems"
|
997
1082
|
|
998
|
-
ID =
|
1083
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
999
1084
|
"""The ID (primary key) of the table entry."""
|
1000
|
-
Class =
|
1085
|
+
Class: Mapped[int] = mapped_column(Integer, default=None)
|
1001
1086
|
"""The class of the menu item."""
|
1002
|
-
Name =
|
1087
|
+
Name: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1003
1088
|
"""The name of the menu item."""
|
1004
1089
|
|
1005
1090
|
def __repr__(self):
|
@@ -1017,22 +1102,70 @@ class DjmdMixerParam(Base, StatsFull):
|
|
1017
1102
|
|
1018
1103
|
__tablename__ = "djmdMixerParam"
|
1019
1104
|
|
1020
|
-
ID =
|
1105
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1021
1106
|
"""The ID (primary key) of the table entry."""
|
1022
|
-
ContentID =
|
1107
|
+
ContentID: Mapped[str] = mapped_column(
|
1108
|
+
VARCHAR(255), ForeignKey("djmdContent.ID"), default=None
|
1109
|
+
)
|
1023
1110
|
"""The ID of the content (:class:`DjmdContent`)."""
|
1024
|
-
GainHigh =
|
1111
|
+
GainHigh: Mapped[int] = mapped_column(Integer, default=None)
|
1025
1112
|
"""The high gain of the mixer parameter."""
|
1026
|
-
GainLow =
|
1113
|
+
GainLow: Mapped[int] = mapped_column(Integer, default=None)
|
1027
1114
|
"""The low gain of the mixer parameter."""
|
1028
|
-
PeakHigh =
|
1115
|
+
PeakHigh: Mapped[int] = mapped_column(Integer, default=None)
|
1029
1116
|
"""The high peak of the mixer parameter."""
|
1030
|
-
PeakLow =
|
1117
|
+
PeakLow: Mapped[int] = mapped_column(Integer, default=None)
|
1031
1118
|
"""The low peak of the mixer parameter."""
|
1032
1119
|
|
1033
1120
|
Content = relationship("DjmdContent")
|
1034
1121
|
"""The content this mixer parameters belong to (links to :class:`DjmdContent`)."""
|
1035
1122
|
|
1123
|
+
@staticmethod
|
1124
|
+
def _get_db(low, high):
|
1125
|
+
integer = (high << 16) | low
|
1126
|
+
byte_data = integer.to_bytes(4, byteorder="big")
|
1127
|
+
factor = struct.unpack("!f", byte_data)[0]
|
1128
|
+
if factor <= 0:
|
1129
|
+
return -np.inf
|
1130
|
+
return 20 * math.log10(factor)
|
1131
|
+
|
1132
|
+
@staticmethod
|
1133
|
+
def _set_db(value):
|
1134
|
+
if value == -np.inf:
|
1135
|
+
return 0, 0
|
1136
|
+
factor = 10 ** (value / 20)
|
1137
|
+
byte_data = struct.pack("!f", factor)
|
1138
|
+
integer = int.from_bytes(byte_data, byteorder="big")
|
1139
|
+
low, high = integer & 0xFFFF, integer >> 16
|
1140
|
+
return low, high
|
1141
|
+
|
1142
|
+
@property
|
1143
|
+
def Gain(self) -> float:
|
1144
|
+
"""The auto-gain value of a track in dB.
|
1145
|
+
|
1146
|
+
This value is computed from the low and high gain values.
|
1147
|
+
It is the value of the auto-gain knob in the Grid Edit panel or Rekordbox,
|
1148
|
+
which is also set by the analysis process.
|
1149
|
+
"""
|
1150
|
+
return self._get_db(self.GainLow, self.GainHigh)
|
1151
|
+
|
1152
|
+
@Gain.setter
|
1153
|
+
def Gain(self, value: float) -> None:
|
1154
|
+
self.GainLow, self.GainHigh = self._set_db(value)
|
1155
|
+
|
1156
|
+
@property
|
1157
|
+
def Peak(self):
|
1158
|
+
"""The peak amplitude of a track in dB.
|
1159
|
+
|
1160
|
+
This value is computed from the low and high peak values.
|
1161
|
+
It is not exposed in Rekordbox.
|
1162
|
+
"""
|
1163
|
+
return self._get_db(self.PeakLow, self.PeakHigh)
|
1164
|
+
|
1165
|
+
@Peak.setter
|
1166
|
+
def Peak(self, value):
|
1167
|
+
self.PeakLow, self.PeakHigh = self._set_db(value)
|
1168
|
+
|
1036
1169
|
|
1037
1170
|
class DjmdMyTag(Base, StatsFull):
|
1038
1171
|
"""Table for storing My-Tags lists in the Rekordbox library.
|
@@ -1044,15 +1177,19 @@ class DjmdMyTag(Base, StatsFull):
|
|
1044
1177
|
|
1045
1178
|
__tablename__ = "djmdMyTag"
|
1046
1179
|
|
1047
|
-
ID =
|
1180
|
+
ID: Mapped[str] = mapped_column(
|
1181
|
+
VARCHAR(255), ForeignKey("djmdMyTag.ParentID"), primary_key=True
|
1182
|
+
)
|
1048
1183
|
"""The ID (primary key) of the table entry."""
|
1049
|
-
Seq =
|
1184
|
+
Seq: Mapped[int] = mapped_column(Integer, default=None)
|
1050
1185
|
"""The sequence of the My-Tag list (for ordering)."""
|
1051
|
-
Name =
|
1186
|
+
Name: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1052
1187
|
"""The name of the My-Tag list."""
|
1053
|
-
Attribute =
|
1188
|
+
Attribute: Mapped[int] = mapped_column(Integer, default=None)
|
1054
1189
|
"""The attribute of the My-Tag list."""
|
1055
|
-
ParentID =
|
1190
|
+
ParentID: Mapped[str] = mapped_column(
|
1191
|
+
VARCHAR(255), ForeignKey("djmdMyTag.ID"), default=None
|
1192
|
+
)
|
1056
1193
|
"""The ID of the parent My-Tag list (:class:`DjmdMyTag`)."""
|
1057
1194
|
|
1058
1195
|
MyTags = relationship("DjmdSongMyTag", back_populates="MyTag")
|
@@ -1079,13 +1216,17 @@ class DjmdSongMyTag(Base, StatsFull):
|
|
1079
1216
|
|
1080
1217
|
__tablename__ = "djmdSongMyTag"
|
1081
1218
|
|
1082
|
-
ID =
|
1219
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1083
1220
|
"""The ID (primary key) of the table entry."""
|
1084
|
-
MyTagID =
|
1221
|
+
MyTagID: Mapped[str] = mapped_column(
|
1222
|
+
VARCHAR(255), ForeignKey("djmdMyTag.ID"), default=None
|
1223
|
+
)
|
1085
1224
|
"""The ID of the My-Tag list (links to :class:`DjmdMyTag`)."""
|
1086
|
-
ContentID =
|
1225
|
+
ContentID: Mapped[str] = mapped_column(
|
1226
|
+
VARCHAR(255), ForeignKey("djmdContent.ID"), default=None
|
1227
|
+
)
|
1087
1228
|
"""The ID of the content this item belongs to (:class:`DjmdContent`)."""
|
1088
|
-
TrackNo =
|
1229
|
+
TrackNo: Mapped[int] = mapped_column(Integer, default=None)
|
1089
1230
|
"""The track number of the My-Tag item (for ordering)."""
|
1090
1231
|
|
1091
1232
|
MyTag = relationship("DjmdMyTag", back_populates="MyTags")
|
@@ -1104,19 +1245,21 @@ class DjmdPlaylist(Base, StatsFull):
|
|
1104
1245
|
|
1105
1246
|
__tablename__ = "djmdPlaylist"
|
1106
1247
|
|
1107
|
-
ID =
|
1248
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1108
1249
|
"""The ID (primary key) of the table entry."""
|
1109
|
-
Seq =
|
1250
|
+
Seq: Mapped[int] = mapped_column(Integer, default=None)
|
1110
1251
|
"""The sequence of the playlist (for ordering)."""
|
1111
|
-
Name =
|
1252
|
+
Name: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1112
1253
|
"""The name of the playlist."""
|
1113
|
-
ImagePath =
|
1254
|
+
ImagePath: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1114
1255
|
"""The path to the image of the playlist."""
|
1115
|
-
Attribute =
|
1256
|
+
Attribute: Mapped[int] = mapped_column(Integer, default=None)
|
1116
1257
|
"""The attribute of the playlist."""
|
1117
|
-
ParentID =
|
1258
|
+
ParentID: Mapped[str] = mapped_column(
|
1259
|
+
VARCHAR(255), ForeignKey("djmdPlaylist.ID"), default=None
|
1260
|
+
)
|
1118
1261
|
"""The ID of the parent playlist (:class:`DjmdPlaylist`)."""
|
1119
|
-
SmartList =
|
1262
|
+
SmartList: Mapped[str] = mapped_column(Text, default=None)
|
1120
1263
|
"""The smart list settings of the playlist."""
|
1121
1264
|
|
1122
1265
|
Songs = relationship(
|
@@ -1148,13 +1291,17 @@ class DjmdSongPlaylist(Base, StatsFull):
|
|
1148
1291
|
|
1149
1292
|
__tablename__ = "djmdSongPlaylist"
|
1150
1293
|
|
1151
|
-
ID =
|
1294
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1152
1295
|
"""The ID (primary key) of the table entry."""
|
1153
|
-
PlaylistID =
|
1296
|
+
PlaylistID: Mapped[str] = mapped_column(
|
1297
|
+
VARCHAR(255), ForeignKey("djmdPlaylist.ID"), default=None
|
1298
|
+
)
|
1154
1299
|
"""The ID of the playlist this item is in (:class:`DjmdPlaylist`)."""
|
1155
|
-
ContentID =
|
1300
|
+
ContentID: Mapped[str] = mapped_column(
|
1301
|
+
VARCHAR(255), ForeignKey("djmdContent.ID"), default=None
|
1302
|
+
)
|
1156
1303
|
"""The ID of the content this item belongs to (:class:`DjmdContent`)."""
|
1157
|
-
TrackNo =
|
1304
|
+
TrackNo: Mapped[int] = mapped_column(Integer, default=None)
|
1158
1305
|
"""The track number of the playlist item (for ordering)."""
|
1159
1306
|
|
1160
1307
|
Playlist = relationship("DjmdPlaylist", back_populates="Songs")
|
@@ -1173,17 +1320,19 @@ class DjmdRelatedTracks(Base, StatsFull):
|
|
1173
1320
|
|
1174
1321
|
__tablename__ = "djmdRelatedTracks"
|
1175
1322
|
|
1176
|
-
ID =
|
1323
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1177
1324
|
"""The ID (primary key) of the table entry."""
|
1178
|
-
Seq =
|
1325
|
+
Seq: Mapped[int] = mapped_column(Integer, default=None)
|
1179
1326
|
"""The sequence of the related tracks list (for ordering)."""
|
1180
|
-
Name =
|
1327
|
+
Name: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1181
1328
|
"""The name of the related tracks list."""
|
1182
|
-
Attribute =
|
1329
|
+
Attribute: Mapped[int] = mapped_column(Integer, default=None)
|
1183
1330
|
"""The attribute of the related tracks list."""
|
1184
|
-
ParentID =
|
1331
|
+
ParentID: Mapped[str] = mapped_column(
|
1332
|
+
VARCHAR(255), ForeignKey("djmdRelatedTracks.ID"), default=None
|
1333
|
+
)
|
1185
1334
|
"""The ID of the parent related tracks list (:class:`DjmdRelatedTracks`)."""
|
1186
|
-
Criteria =
|
1335
|
+
Criteria: Mapped[str] = mapped_column(Text, default=None)
|
1187
1336
|
"""The criteria used to determine the items in the related tracks list."""
|
1188
1337
|
|
1189
1338
|
Songs = relationship("DjmdSongRelatedTracks", back_populates="RelatedTracks")
|
@@ -1214,16 +1363,18 @@ class DjmdSongRelatedTracks(Base, StatsFull):
|
|
1214
1363
|
|
1215
1364
|
__tablename__ = "djmdSongRelatedTracks"
|
1216
1365
|
|
1217
|
-
ID =
|
1366
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1218
1367
|
"""The ID (primary key) of the table entry."""
|
1219
|
-
RelatedTracksID =
|
1368
|
+
RelatedTracksID: Mapped[str] = mapped_column(
|
1220
1369
|
VARCHAR(255), ForeignKey("djmdRelatedTracks.ID"), default=None
|
1221
1370
|
)
|
1222
1371
|
"""The ID of the related tracks list this item is in
|
1223
1372
|
(:class:`DjmdRelatedTracks`)."""
|
1224
|
-
ContentID =
|
1373
|
+
ContentID: Mapped[str] = mapped_column(
|
1374
|
+
VARCHAR(255), ForeignKey("djmdContent.ID"), default=None
|
1375
|
+
)
|
1225
1376
|
"""The ID of the content this item belongs to (:class:`DjmdContent`)."""
|
1226
|
-
TrackNo =
|
1377
|
+
TrackNo: Mapped[int] = mapped_column(Integer, default=None)
|
1227
1378
|
"""The track number of the related tracks list item (for ordering)."""
|
1228
1379
|
|
1229
1380
|
RelatedTracks = relationship("DjmdRelatedTracks", back_populates="Songs")
|
@@ -1242,15 +1393,17 @@ class DjmdSampler(Base, StatsFull):
|
|
1242
1393
|
|
1243
1394
|
__tablename__ = "djmdSampler"
|
1244
1395
|
|
1245
|
-
ID =
|
1396
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1246
1397
|
"""The ID (primary key) of the table entry."""
|
1247
|
-
Seq =
|
1398
|
+
Seq: Mapped[int] = mapped_column(Integer, default=None)
|
1248
1399
|
"""The sequence of the sampler list (for ordering)."""
|
1249
|
-
Name =
|
1400
|
+
Name: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1250
1401
|
"""The name of the sampler list."""
|
1251
|
-
Attribute =
|
1402
|
+
Attribute: Mapped[int] = mapped_column(Integer, default=None)
|
1252
1403
|
"""The attribute of the sampler list."""
|
1253
|
-
ParentID =
|
1404
|
+
ParentID: Mapped[str] = mapped_column(
|
1405
|
+
VARCHAR(255), ForeignKey("djmdSampler.ID"), default=None
|
1406
|
+
)
|
1254
1407
|
"""The ID of the parent sampler list (:class:`DjmdSampler`)."""
|
1255
1408
|
|
1256
1409
|
Songs = relationship("DjmdSongSampler", back_populates="Sampler")
|
@@ -1279,13 +1432,17 @@ class DjmdSongSampler(Base, StatsFull):
|
|
1279
1432
|
|
1280
1433
|
__tablename__ = "djmdSongSampler"
|
1281
1434
|
|
1282
|
-
ID =
|
1435
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1283
1436
|
"""The ID (primary key) of the table entry."""
|
1284
|
-
SamplerID =
|
1437
|
+
SamplerID: Mapped[str] = mapped_column(
|
1438
|
+
VARCHAR(255), ForeignKey("djmdSampler.ID"), default=None
|
1439
|
+
)
|
1285
1440
|
"""The ID of the sampler list this item is in (:class:`DjmdSampler`)."""
|
1286
|
-
ContentID =
|
1441
|
+
ContentID: Mapped[str] = mapped_column(
|
1442
|
+
VARCHAR(255), ForeignKey("djmdContent.ID"), default=None
|
1443
|
+
)
|
1287
1444
|
"""The ID of the content this item belongs to (:class:`DjmdContent`)."""
|
1288
|
-
TrackNo =
|
1445
|
+
TrackNo: Mapped[int] = mapped_column(Integer, default=None)
|
1289
1446
|
"""The track number of the sampler list item (for ordering)."""
|
1290
1447
|
|
1291
1448
|
Sampler = relationship("DjmdSampler", back_populates="Songs")
|
@@ -1299,11 +1456,13 @@ class DjmdSongTagList(Base, StatsFull):
|
|
1299
1456
|
|
1300
1457
|
__tablename__ = "djmdSongTagList"
|
1301
1458
|
|
1302
|
-
ID =
|
1459
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1303
1460
|
"""The ID (primary key) of the table entry."""
|
1304
|
-
ContentID =
|
1461
|
+
ContentID: Mapped[str] = mapped_column(
|
1462
|
+
VARCHAR(255), ForeignKey("djmdContent.ID"), default=None
|
1463
|
+
)
|
1305
1464
|
"""The ID of the content this item belongs to (:class:`DjmdContent`)."""
|
1306
|
-
TrackNo =
|
1465
|
+
TrackNo: Mapped[int] = mapped_column(Integer, default=None)
|
1307
1466
|
"""The track number of the tag list item (for ordering)."""
|
1308
1467
|
|
1309
1468
|
Content = relationship("DjmdContent")
|
@@ -1320,16 +1479,18 @@ class DjmdSort(Base, StatsFull):
|
|
1320
1479
|
|
1321
1480
|
__tablename__ = "djmdSort"
|
1322
1481
|
|
1323
|
-
ID =
|
1482
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1324
1483
|
"""The ID (primary key) of the table entry."""
|
1325
|
-
MenuItemID =
|
1484
|
+
MenuItemID: Mapped[str] = mapped_column(
|
1485
|
+
VARCHAR(255), ForeignKey("djmdMenuItems.ID"), default=None
|
1486
|
+
)
|
1326
1487
|
"""The ID of the menu item this sort list is in (:class:`DjmdMenuItems`)."""
|
1327
|
-
Seq =
|
1488
|
+
Seq: Mapped[int] = mapped_column(Integer, default=None)
|
1328
1489
|
"""The sequence of the sort list (for ordering)."""
|
1329
|
-
Disable =
|
1490
|
+
Disable: Mapped[int] = mapped_column(Integer, default=None)
|
1330
1491
|
"""Whether the sort list is disabled."""
|
1331
1492
|
|
1332
|
-
MenuItem = relationship("DjmdMenuItems", foreign_keys=
|
1493
|
+
MenuItem = relationship("DjmdMenuItems", foreign_keys=MenuItemID)
|
1333
1494
|
"""The menu item this sort list is in (links to :class:`DjmdMenuItems`)."""
|
1334
1495
|
|
1335
1496
|
|
@@ -1338,13 +1499,13 @@ class HotCueBanklistCue(Base, StatsFull):
|
|
1338
1499
|
|
1339
1500
|
__tablename__ = "hotCueBanklistCue"
|
1340
1501
|
|
1341
|
-
ID =
|
1502
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1342
1503
|
"""The ID (primary key) of the table entry."""
|
1343
|
-
HotCueBanklistID =
|
1504
|
+
HotCueBanklistID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1344
1505
|
"""The ID of the hot cue bank list."""
|
1345
|
-
Cues =
|
1506
|
+
Cues: Mapped[str] = mapped_column(Text, default=None)
|
1346
1507
|
"""The hot cue bank list contents."""
|
1347
|
-
rb_cue_count =
|
1508
|
+
rb_cue_count: Mapped[int] = mapped_column(Integer, default=None)
|
1348
1509
|
"""The number of hot cues in the bank list."""
|
1349
1510
|
|
1350
1511
|
|
@@ -1353,25 +1514,25 @@ class DjmdProperty(Base, StatsTime):
|
|
1353
1514
|
|
1354
1515
|
__tablename__ = "djmdProperty"
|
1355
1516
|
|
1356
|
-
DBID =
|
1517
|
+
DBID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1357
1518
|
"""The ID (primary key) of the table entry."""
|
1358
|
-
DBVersion =
|
1519
|
+
DBVersion: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1359
1520
|
"""The version of the database."""
|
1360
|
-
BaseDBDrive =
|
1521
|
+
BaseDBDrive: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1361
1522
|
"""The drive the database is stored on."""
|
1362
|
-
CurrentDBDrive =
|
1523
|
+
CurrentDBDrive: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1363
1524
|
"""The drive the database is currently stored on."""
|
1364
|
-
DeviceID =
|
1525
|
+
DeviceID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1365
1526
|
"""The ID of the device the database is stored on."""
|
1366
|
-
Reserved1 =
|
1527
|
+
Reserved1: Mapped[str] = mapped_column(Text, default=None)
|
1367
1528
|
"""Reserved column."""
|
1368
|
-
Reserved2 =
|
1529
|
+
Reserved2: Mapped[str] = mapped_column(Text, default=None)
|
1369
1530
|
"""Reserved column."""
|
1370
|
-
Reserved3 =
|
1531
|
+
Reserved3: Mapped[str] = mapped_column(Text, default=None)
|
1371
1532
|
"""Reserved column."""
|
1372
|
-
Reserved4 =
|
1533
|
+
Reserved4: Mapped[str] = mapped_column(Text, default=None)
|
1373
1534
|
"""Reserved column."""
|
1374
|
-
Reserved5 =
|
1535
|
+
Reserved5: Mapped[str] = mapped_column(Text, default=None)
|
1375
1536
|
"""Reserved column."""
|
1376
1537
|
|
1377
1538
|
|
@@ -1380,39 +1541,39 @@ class ImageFile(Base, StatsFull):
|
|
1380
1541
|
|
1381
1542
|
__tablename__ = "imageFile"
|
1382
1543
|
|
1383
|
-
ID =
|
1544
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1384
1545
|
"""The ID (primary key) of the table entry."""
|
1385
|
-
TableName =
|
1546
|
+
TableName: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1386
1547
|
"""The name of the table the image file is in."""
|
1387
|
-
TargetUUID =
|
1548
|
+
TargetUUID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1388
1549
|
"""The UUID of the target the image file is for."""
|
1389
|
-
TargetID =
|
1550
|
+
TargetID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1390
1551
|
"""The ID of the target the image file is for."""
|
1391
|
-
Path =
|
1552
|
+
Path: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1392
1553
|
"""The path to the image file."""
|
1393
|
-
Hash =
|
1554
|
+
Hash: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1394
1555
|
"""The hash of the image file."""
|
1395
|
-
Size =
|
1556
|
+
Size: Mapped[int] = mapped_column(Integer, default=None)
|
1396
1557
|
"""The size of the image file."""
|
1397
|
-
rb_local_path =
|
1558
|
+
rb_local_path: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1398
1559
|
"""The local path to the image file."""
|
1399
|
-
rb_insync_hash =
|
1560
|
+
rb_insync_hash: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1400
1561
|
"""The hash of the image file."""
|
1401
|
-
rb_insync_local_usn =
|
1562
|
+
rb_insync_local_usn: Mapped[int] = mapped_column(BigInteger, default=None)
|
1402
1563
|
"""The local USN of the in-sync image file."""
|
1403
|
-
rb_file_hash_dirty =
|
1564
|
+
rb_file_hash_dirty: Mapped[int] = mapped_column(Integer, default=0)
|
1404
1565
|
"""Whether the hash of the image file is dirty."""
|
1405
|
-
rb_local_file_status =
|
1566
|
+
rb_local_file_status: Mapped[int] = mapped_column(Integer, default=0)
|
1406
1567
|
"""The status of the image file."""
|
1407
|
-
rb_in_progress =
|
1568
|
+
rb_in_progress: Mapped[int] = mapped_column(SmallInteger, default=0)
|
1408
1569
|
"""Whether the image file is in progress."""
|
1409
|
-
rb_process_type =
|
1570
|
+
rb_process_type: Mapped[int] = mapped_column(Integer, default=0)
|
1410
1571
|
"""The type of process the image file is in."""
|
1411
|
-
rb_temp_path =
|
1572
|
+
rb_temp_path: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1412
1573
|
"""The temporary path of the image file."""
|
1413
|
-
rb_priority =
|
1574
|
+
rb_priority: Mapped[int] = mapped_column(Integer, default=50)
|
1414
1575
|
"""The priority of the image file."""
|
1415
|
-
rb_file_size_dirty =
|
1576
|
+
rb_file_size_dirty: Mapped[int] = mapped_column(Integer, default=0)
|
1416
1577
|
"""Whether the size of the image file is dirty."""
|
1417
1578
|
|
1418
1579
|
|
@@ -1421,23 +1582,23 @@ class SettingFile(Base, StatsFull):
|
|
1421
1582
|
|
1422
1583
|
__tablename__ = "settingFile"
|
1423
1584
|
|
1424
|
-
ID =
|
1585
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1425
1586
|
"""The ID (primary key) of the table entry."""
|
1426
|
-
Path =
|
1587
|
+
Path: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1427
1588
|
"""The path to the setting file."""
|
1428
|
-
Hash =
|
1589
|
+
Hash: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1429
1590
|
"""The hash of the setting file."""
|
1430
|
-
Size =
|
1591
|
+
Size: Mapped[int] = mapped_column(Integer, default=None)
|
1431
1592
|
"""The size of the setting file."""
|
1432
|
-
rb_local_path =
|
1593
|
+
rb_local_path: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1433
1594
|
"""The local path to the setting file."""
|
1434
|
-
rb_insync_hash =
|
1595
|
+
rb_insync_hash: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1435
1596
|
"""The hash of the in-sync setting file."""
|
1436
|
-
rb_insync_local_usn =
|
1597
|
+
rb_insync_local_usn: Mapped[int] = mapped_column(BigInteger, default=None)
|
1437
1598
|
"""The local USN of the setting file."""
|
1438
|
-
rb_file_hash_dirty =
|
1599
|
+
rb_file_hash_dirty: Mapped[int] = mapped_column(Integer, default=0)
|
1439
1600
|
"""Whether the hash of the setting file is dirty."""
|
1440
|
-
rb_file_size_dirty =
|
1601
|
+
rb_file_size_dirty: Mapped[int] = mapped_column(Integer, default=0)
|
1441
1602
|
"""Whether the size of the setting file is dirty."""
|
1442
1603
|
|
1443
1604
|
|
@@ -1446,11 +1607,11 @@ class UuidIDMap(Base, StatsFull):
|
|
1446
1607
|
|
1447
1608
|
__tablename__ = "uuidIDMap"
|
1448
1609
|
|
1449
|
-
ID =
|
1610
|
+
ID: Mapped[str] = mapped_column(VARCHAR(255), primary_key=True)
|
1450
1611
|
"""The ID (primary key) of the table entry."""
|
1451
|
-
TableName =
|
1612
|
+
TableName: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1452
1613
|
"""The name of the table the mapping is used for."""
|
1453
|
-
TargetUUID =
|
1614
|
+
TargetUUID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1454
1615
|
"""The UUID of the mapping."""
|
1455
|
-
CurrentID =
|
1616
|
+
CurrentID: Mapped[str] = mapped_column(VARCHAR(255), default=None)
|
1456
1617
|
"""The ID of the mapping."""
|