...
A category profile have the following attributes :
- id,
- name,
- urlCategory : url to get back a xml category file on a remote server
- trustCategory ( yes | no ) : If it is "yes", visibility rights used are those of remote category and sources. If it is "no", visibility rights on category and sources used are those of this category profile, defined in visibility element.
- access ( public | cas ) : access of the category is public or cas because it needs CAS proxy ticket for authentication (for more information about CAS configuration see Configuration en déploiement portlet of the ESUP-Commons documentation and CAS en mode portletof the part Utilisation de CAS (French) of the of ESUP-Lecture documentation)
- ttl (seconds) : time to live of the remote category and its sources
- timeout (milliseconds) : time trying to get the category
- visibility : define group visibility for category referenced by this category profile. It is used only if trustCategory is set to "no"
- userCanMarkRead (yes | no) : If "yes", users can mark items of the category as read ot not read. Yes by default*
...
Element visibility :
| Bloc de code |
|---|
<visibility>
<allowed/>
<autoSubscribed/>
<obliged>
<group name="local.0"/>
<group .../>
...
<regular attribute="sn" value="user" />
<regular .../>
...
</obliged>
</visibility>
|
In this element, you define 3 groups of visibility;
- allowed : user inside are "allowed" to subscribe to a category
autoSubscribed : user inside are auto subscribed to this category and is allowed to unsubscribe
obliged : user inside are automatically subscribe to this category and can't unsubscribe - for the moment, it is the only way for users to see category -
A user is in a visibility group by two ways :*
- group : user is in the portal group referenced by attribute name, in the example : user in in group "local.0" - see "portlet.xml" section.
- regular : user check regular, in the example : user value of portal attribute "sn" is "user" - see "portlet.xml" section.
<category>.xml
- * element categoryin i n xml category file (describe by dtd category.dtd), provided by remote server, requested by urlCategory of esup-lecture.xml :
A category has a name and a description (displayed on interface), andBloc de code <?xml version="1.0" encoding="ISO-8859-1"?> <!DOCTYPE category SYSTEM "category.dtd"> <category name="Différents RSS"> <description>Très belle description !</description> <sourceProfiles> <sourceProfile> ... </sourceProfiles> <sourceProfile> ... </sourceProfiles> ... </sourceProfiles> <visibility> ... </visibility> </category>- a list of source profiles
- visibility : define group visibility for this category. It is used only if trustCategory attribute of referencing categoryProfile is set to "yes" else visibility of category profile is used - optional -
<category>.xml
- element sourceProfile in xml category file :
A source profile has an id, a name (displayed on interface) andBloc de code <sourceProfile id="un" access="public" name="Incidents techniques Rennes 1" specificUserContent="no" url="http://info.cri.univ-rennes1.fr/rss/rss.php"> <visibility> ... </visibility> </sourceProfile>
- access ( public | cas ) : access of the source is public or cas because it needs CAS proxy ticket for authentication (for more information about CAS configuration see Configuration en déploiement portlet of the ESUP-Commons documentation and CAS en mode portletof the part Utilisation de CAS (French) of the of ESUP-Lecture documentation)
- specificUserContent ( yes | no) : if it is "yes", source content is specific to user. If it is "no", source content is the same for every users (If your configure with "yes" then application assumes that content can be deferent for each user (may be because of specific content due to profiling according to authentication). In this case application doesn't use any cache for the source. So be careful before use "yes" for this property.)
- url : url to get xml stream of the source
- timeout (milliseconds) : Time trying to get the source. Parent category timeout is used is it is not defined here
- visibility : define group visibility for source refered by this source profile. It is used only if trustCategory attribute of referencing categoryProfile is set to "yes" else visibility category profile is used - optional -
Remarque Be carefull to manage unique id for every sources profiles defined in categories : application does not yet manage it.
...