[opencms-dev] HowTo create a resource in opencms 6

Siegfried Puchbauer siegfried.puchbauer at gmail.com
Tue Dec 20 12:05:00 CET 2005


You can use for example:

org.opencms.file.types.CmsResourceTypeXmlPage.*getStaticTypeId<http://synyx.de/api/opencms6.0.0/org/opencms/file/types/CmsResourceTypeXmlPage.html#getStaticTypeId%28%29>
*()

for a page. Have a look at
http://synyx.de/api/opencms6.0.0/org/opencms/file/types/A_CmsResourceType.html
http://synyx.de/api/opencms6.0.0/org/opencms/file/types/CmsResourceTypeXmlPage.html
http://synyx.de/api/opencms6.0.0/org/opencms/file/CmsObject.html#createResource(java.lang.String,%20int,%20byte[],%20java.util.List)


2005/12/20, Thierry Collogne <tcollogne at hotmail.com>:
>
> Hi,
>
> I'm new to opencms and to learn it, I 'm following the book from Matt
> Butcher.
> This book was written for opencms 5, so some features are different.
>
> I'm no experinmenting with the api and it seems that it has changed a lot.
> At some time in the book, a resource is created using the following
> method:
>
> createResource(java.lang.String newResourceName, java.lang.String type,
> java.util.Map properties, byte[] contents, java.lang.Object parameter)
>
>
> This method is not present in opencms 6. Instead, there is the following:
>
> createResource(java.lang.String resourcename, int type, byte[] content,
> java.util.List properties)
>
> I have no idea how to use the new one. What value should I use for type
> (int???). What objects is the properties List composed of?
>
> Thanks,
>
> Thierry Collogne
>
>
>
>
> _______________________________________________
> This mail is send to you from the opencms-dev mailing list
> To change your list options, or to unsubscribe from the list, please visit
> http://mail.opencms.org/mailman/listinfo/opencms-dev
>



--
Mit freundlichen Grüßen

Siegfried Puchbauer
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opencms.org/pipermail/opencms-dev/attachments/20051220/48ced471/attachment.html>


More information about the opencms-dev mailing list