View Javadoc

1   package org.apache.commons.digester3.edsl.atom;
2   
3   /*
4    * Licensed to the Apache Software Foundation (ASF) under one
5    * or more contributor license agreements.  See the NOTICE file
6    * distributed with this work for additional information
7    * regarding copyright ownership.  The ASF licenses this file
8    * to you under the Apache License, Version 2.0 (the
9    * "License"); you may not use this file except in compliance
10   * with the License.  You may obtain a copy of the License at
11   *
12   *   http://www.apache.org/licenses/LICENSE-2.0
13   *
14   * Unless required by applicable law or agreed to in writing,
15   * software distributed under the License is distributed on an
16   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
17   * KIND, either express or implied.  See the License for the
18   * specific language governing permissions and limitations
19   * under the License.
20   */
21  
22  import java.net.URL;
23  import java.util.ArrayList;
24  import java.util.Date;
25  import java.util.List;
26  
27  public final class Feed
28  {
29  
30      private String title;
31  
32      private URL link;
33  
34      private Date updated;
35  
36      private final List<String> authors = new ArrayList<String>();
37  
38      private String id;
39  
40      private final List<Entry> entries = new ArrayList<Entry>();
41  
42      public String getTitle()
43      {
44          return title;
45      }
46  
47      public void setTitle( String title )
48      {
49          this.title = title;
50      }
51  
52      public URL getLink()
53      {
54          return link;
55      }
56  
57      public void setLink( URL link )
58      {
59          this.link = link;
60      }
61  
62      public Date getUpdated()
63      {
64          return updated;
65      }
66  
67      public void setUpdated( Date updated )
68      {
69          this.updated = updated;
70      }
71  
72      public String getId()
73      {
74          return id;
75      }
76  
77      public void setId( String id )
78      {
79          this.id = id;
80      }
81  
82      public List<String> getAuthors()
83      {
84          return authors;
85      }
86  
87      public void addAuthor( String author )
88      {
89          authors.add( author );
90      }
91  
92      public List<Entry> getEntries()
93      {
94          return entries;
95      }
96  
97      public void addEntry( Entry entry )
98      {
99          entries.add( entry );
100     }
101 
102     @Override
103     public String toString()
104     {
105         return "Feed [title=" + title + ", link=" + link + ", updated=" + updated + ", authors=" + authors + ", id="
106             + id + ", entries=" + entries + "]";
107     }
108 
109 }