File : data/TravelNotesDataRouting.js

1
/*
2
Copyright - 2017 2023 - wwwouaiebe - Contact: https://www.ouaie.be/
3
4
This  program is free software;
5
you can redistribute it and/or modify it under the terms of the
6
GNU General Public License as published by the Free Software Foundation;
7
either version 3 of the License, or any later version.
8
This program is distributed in the hope that it will be useful,
9
but WITHOUT ANY WARRANTY; without even the implied warranty of
10
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11
GNU General Public License for more details.
12
You should have received a copy of the GNU General Public License
13
along with this program; if not, write to the Free Software
14
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
15
*/
16
/*
17
Changes:
18
    - v4.0.0:
19
        - created from v3.6.0
20
Doc reviewed 202208
21
 */
22
23
/* ------------------------------------------------------------------------------------------------------------------------- */
24
/**
25
helper class to encapsulate the routing
26
*/
27
/* ------------------------------------------------------------------------------------------------------------------------- */
28
29
class TravelNotesDataRouting {
30
31
    /**
32
    The routing provider
33
    @type {String}
34
    */
35
36
    #provider = '';
37
38
    /**
39
    The routing transit mode
40
    @type {String}
41
    */
42
43
    #transitMode = '';
44
45
    /**
46
    The constructor
47
    */
48
49
    constructor ( ) {
50
        Object.freeze ( this );
51
    }
52
53
    /**
54
    The routing provider
55
    @type {String}
56
    */
57
58
    get provider ( ) { return this.#provider; }
59
60
    set provider ( provider ) {
61
        this.#provider = 'string' === typeof ( provider ) ? provider : '';
62
    }
63
64
    /**
65
    The routing transit mode
66
    @type {String}
67
    */
68
69
    get transitMode ( ) { return this.#transitMode; }
70
71
    set transitMode ( transitMode ) {
72
        this.#transitMode = 'string' === typeof ( transitMode ) ? transitMode : '';
73
    }
74
}
75
76
export default TravelNotesDataRouting;
77
78
/* --- End of file --------------------------------------------------------------------------------------------------------- */
79