KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > sun > syndication > feed > synd > SyndEntry


1 /*
2  * Copyright 2004 Sun Microsystems, Inc.
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 com.sun.syndication.feed.synd;
18
19 import com.sun.syndication.feed.CopyFrom;
20 import com.sun.syndication.feed.module.Module;
21
22 import java.util.Date JavaDoc;
23 import java.util.List JavaDoc;
24
25 /**
26  * Bean interface for entries of SyndFeedImpl feeds.
27  * <p>
28  * @author Alejandro Abdelnur
29  *
30  */

31 public interface SyndEntry extends Cloneable JavaDoc,CopyFrom {
32
33     /**
34      * Returns the entry URI.
35      * <p>
36      * How the entry URI maps to a concrete feed type (RSS or Atom) depends on
37      * the concrete feed type. This is explained in detail in Rome documentation,
38      * <a HREF="http://wiki.java.net/bin/edit/Javawsxml/Rome04URIMapping">Feed and entry URI mapping</a>.
39      * <p>
40      * The returned URI is a normalized URI as specified in RFC 2396bis.
41      * <p>
42      * @return the entry URI, <b>null</b> if none.
43      *
44      */

45     String JavaDoc getUri();
46
47     /**
48      * Sets the entry URI.
49      * <p>
50      * How the entry URI maps to a concrete feed type (RSS or Atom) depends on
51      * the concrete feed type. This is explained in detail in Rome documentation,
52      * <a HREF="http://wiki.java.net/bin/edit/Javawsxml/Rome04URIMapping">Feed and entry URI mapping</a>.
53      * <p>
54      * @param uri the entry URI to set, <b>null</b> if none.
55      *
56      */

57     void setUri(String JavaDoc uri);
58
59     /**
60      * Returns the entry title.
61      * <p>
62      * @return the entry title, <b>null</b> if none.
63      *
64      */

65     String JavaDoc getTitle();
66
67     /**
68      * Sets the entry title.
69      * <p>
70      * @param title the entry title to set, <b>null</b> if none.
71      *
72      */

73     void setTitle(String JavaDoc title);
74
75     /**
76      * Returns the entry link.
77      * <p>
78      * @return the entry link, <b>null</b> if none.
79      *
80      */

81     String JavaDoc getLink();
82
83     /**
84      * Sets the entry link.
85      * <p>
86      * @param link the entry link to set, <b>null</b> if none.
87      *
88      */

89     void setLink(String JavaDoc link);
90
91     /**
92      * Returns the entry description.
93      * <p>
94      * @return the entry description, <b>null</b> if none.
95      *
96      */

97     SyndContent getDescription();
98
99     /**
100      * Sets the entry description.
101      * <p>
102      * @param description the entry description to set, <b>null</b> if none.
103      *
104      */

105     void setDescription(SyndContent description);
106
107     /**
108      * Returns the entry contents.
109      * <p>
110      * @return a list of SyndContentImpl elements with the entry contents,
111      * an empty list if none.
112      *
113      */

114     List JavaDoc getContents();
115
116     /**
117      * Sets the entry contents.
118      * <p>
119      * @param contents the list of SyndContentImpl elements with the entry contents to set,
120      * an empty list or <b>null</b> if none.
121      *
122      */

123     void setContents(List JavaDoc contents);
124
125     /**
126      * Returns the entry published date.
127      * <p>
128      * This method is a convenience method, it maps to the Dublin Core module date.
129      * <p>
130      * @return the entry published date, <b>null</b> if none.
131      *
132      */

133     Date JavaDoc getPublishedDate();
134
135     /**
136      * Sets the entry published date.
137      * <p>
138      * This method is a convenience method, it maps to the Dublin Core module date.
139      * <p>
140      * @param publishedDate the entry published date to set, <b>null</b> if none.
141      *
142      */

143     void setPublishedDate(Date JavaDoc publishedDate);
144
145     /**
146      * Returns the entry author.
147      * <p>
148      * This method is a convenience method, it maps to the Dublin Core module creator.
149      * <p>
150      * @return the entry author, <b>null</b> if none.
151      *
152      */

153     String JavaDoc getAuthor();
154
155     /**
156      * Sets the entry author.
157      * <p>
158      * This method is a convenience method, it maps to the Dublin Core module creator.
159      * <p>
160      * @param author the entry author to set, <b>null</b> if none.
161      *
162      */

163     void setAuthor(String JavaDoc author);
164
165     /**
166      * Returns the entry categories.
167      * <p>
168      * This method is a convenience method, it maps to the Dublin Core module subjects.
169      * <p>
170      * @return a list of SyndCategoryImpl elements with the entry categories,
171      * an empty list if none.
172      *
173      */

174     List JavaDoc getCategories();
175
176     /**
177      * Sets the entry categories.
178      * <p>
179      * This method is a convenience method, it maps to the Dublin Core module subjects.
180      * <p>
181      * @param categories the list of SyndCategoryImpl elements with the entry categories to set,
182      * an empty list or <b>null</b> if none.
183      *
184      */

185     void setCategories(List JavaDoc categories);
186
187     /**
188      * Returns the module identified by a given URI.
189      * <p>
190      * @param uri the URI of the ModuleImpl.
191      * @return The module with the given URI, <b>null</b> if none.
192      */

193     public Module getModule(String JavaDoc uri);
194
195     /**
196      * Returns the entry modules.
197      * <p>
198      * @return a list of ModuleImpl elements with the entry modules,
199      * an empty list if none.
200      *
201      */

202     List JavaDoc getModules();
203
204     /**
205      * Sets the entry modules.
206      * <p>
207      * @param modules the list of ModuleImpl elements with the entry modules to set,
208      * an empty list or <b>null</b> if none.
209      *
210      */

211     void setModules(List JavaDoc modules);
212
213     /**
214      * Creates a deep clone of the object.
215      * <p>
216      * @return a clone of the object.
217      * @throws CloneNotSupportedException thrown if an element of the object cannot be cloned.
218      *
219      */

220     public Object JavaDoc clone() throws CloneNotSupportedException JavaDoc;
221
222 }
223
Popular Tags