-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathAudioTrack.h
63 lines (50 loc) · 1.98 KB
/
AudioTrack.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
/*
* AudioTrack class
*
* AudioTrack obects contain data related to an individual audio track
* along with get methods to retrive track metadata
*/
#include <string>
#include <JuceHeader.h>
#pragma once
class AudioTrack {
public:
/** constructor creates a new AudioTrack with given values
* @param _trackTitle - string representing track title
* @param _trackLength - string representing track length
* @param _trackSampleRate - string representing track sample length
* @param _trackType - string representing track type
* @param _filepath - string track filepath */
AudioTrack(std::string _trackTitle,
std::string _trackLength,
std::string _sampleRate,
std::string _fileType,
std::string _filepath);
/** Destructor for AudioTrack class */
~AudioTrack();
/** returns the track title as a string
* @return string track title */
std::string getTrackTitle();
/** returns the track length as a string
* @return string track length */
std::string getTrackLength();
/** returns the tracks sample rate as a string
* @return string track sample rate */
std::string getTrackSampleRate();
/** returns the track type as a string
* @return string track type */
std::string getTrackType();
/** returns the track filepath as a string
* @return String track filepath */
std::string getTrackFilepath();
/** converts a given AudioTrack object to a comma seperated string
* @param track AudioTrack object
* @return string of comma seperated AudioTrack details */
std::string toString();
private:
std::string trackTitle;
std::string trackLength;
std::string sampleRate;
std::string fileType;
std::string filepath;
};