portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bui Quoc Thai <st027...@ait.ac.th>
Subject Re: R: Add Media-type for portlet entry by coding
Date Thu, 24 Oct 2002 09:10:42 GMT
Hi,

 It works, thank you very much!
Thai

Quoting Amedeo Zottola <amedeo.zottola@noema.it>:

> Hi,
> 
> you can use this simple code...
> 
> --------------------------------
> BasePortletEntry entry = ...
> 
> //Add media-type
> Vector mediaType = new Vector();
> BaseMediaType mType = new BaseMediaType();
> mType.setRef(MimeType.HTML.getCode());
> mediaType.add(mType);
> entry.setMediaTypes(mediaType);
> --------------------------------------
> 
> Bye bye...
> Amedeo.
> 
> > -----Messaggio originale-----
> > Da: Bui Quoc Thai [mailto:st027235@ait.ac.th]
> > Inviato: mercoledì 23 ottobre 2002 20.52
> > A: Jetspeed Developers List
> > Oggetto: Add Media-type for portlet entry by coding
> > 
> > 
> > Hi,
> > 
> >  I create portlet entry by progamming, I use BasePortletEntry 
> > to create a new 
> > entry, after that I use their methods to add other 
> > information for the 
> > portlet, such as: setName(), setTitle(),...
> >  However, I cann't set MediaType properly. In particularly, I 
> > use setMediaTypes
> > () then it create the element:
> >        <media-type>html</media-type>
> >  instead of:
> >        <media-type ref="html"/>
> > 
> >  This leads to an error in the portlet list for adding 
> > portlet (the portlet 
> > table has no portlet).
> > 
> > Has someone done this problem? Please, give me some commnend!
> > Thank you so much
> > Thai
> > --------------------------
> > Email: st027235@ait.ac.th
> >        bqthai@ctu.edu.vn
> > Room: C34
> > Tel: 524-7099
> > 
> > ----------------------------------------------------------
> > This mail sent through AIT WebMail : http://www.ait.ac.th/
> > 
> > --
> > To unsubscribe, e-mail:   
> > <mailto:jetspeed-dev-unsubscribe@jakarta.apache.org>
> > For additional commands, e-mail: 
> > <mailto:jetspeed-dev-help@jakarta.apache.org>
> > 
> > 
> 
> --
> To unsubscribe, e-mail:  
> <mailto:jetspeed-dev-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
> <mailto:jetspeed-dev-help@jakarta.apache.org>
> 


--------------------------
Email: st027235@ait.ac.th
       bqthai@ctu.edu.vn
Room: C34
Tel: 524-7099

----------------------------------------------------------
This mail sent through AIT WebMail : http://www.ait.ac.th/

--
To unsubscribe, e-mail:   <mailto:jetspeed-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:jetspeed-dev-help@jakarta.apache.org>


Mime
View raw message