[LIB-4] Add hespiff source files
[hespiff.git] / src / main / java / org / hedgecode / xml / xspf / Playlist.java
1 /*
2  * Copyright (c) 2015. Developed by Hedgecode.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *   http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 package org.hedgecode.xml.xspf;
18
19 import java.io.File;
20 import java.io.OutputStream;
21 import java.io.UnsupportedEncodingException;
22 import java.util.Date;
23 import java.util.List;
24
25 import javax.xml.bind.JAXBException;
26
27 import org.hedgecode.xml.xspf.validate.ValidateException;
28
29 /**
30  *
31  *
32  * @author Dmitry Samoshin aka gotty
33  */
34 public interface Playlist extends Element {
35
36     String getLocation();
37
38     void setLocation(String location);
39
40     String getIdentifier();
41
42     void setIdentifier(String identifier);
43
44     Date getDate();
45
46     void setDate(Date date);
47
48     String getLicense();
49
50     void setLicense(String license);
51
52     Attribution getAttribution();
53
54     void setAttribution(Attribution attribution);
55
56     List<Track> getTracks();
57
58     void addTrack(Track track);
59
60     void read(File inputFile) throws JAXBException;
61
62     void write(File outputFile) throws JAXBException;
63
64     public OutputStream getAsStream() throws JAXBException;
65
66     public String getAsString() throws JAXBException, UnsupportedEncodingException;
67
68     void validate() throws ValidateException;
69
70 }