[opencms-dev] readCategories

Lorenz Lammersdorf lorenz.lammersdorf at kernbrand.ch
Fri Nov 27 10:17:14 CET 2015


thanks, that did the trick.

Am 27.11.2015 um 10:13 schrieb Stephan Schrader:
> Try this:
>
> while (ic.hasNext()) { ic.next(); }
>
> Stephan
>
> 2015-11-26 22:34 GMT+01:00 Lorenz Lammersdorf
> <lorenz.lammersdorf at kernbrand.ch <mailto:lorenz.lammersdorf at kernbrand.ch>>:
>
>     hi list,
>
>     i have 3 categories in a folder called "blog" in
>     /sites/blubb/.categories/. i try to read them
>
>     CmsJspActionElement cms = new CmsJspActionElement(pageContext,
>     request, response);
>     CmsObject cmsObject = cms.getCmsObject();
>     CmsCategoryService cs = CmsCategoryService.getInstance();
>     List cats = cs.readCategories(cmsObject, "blog/", false,
>     cs.getRepositoryBaseFolderName(cmsObject));
>     Iterator ic = cats.iterator();
>
>     while (ic.hasNext()) { //do nothing! }
>
>
>     this ends up with  java.lang.OutOfMemoryError: Requested array size
>     exceeds VM limit.
>
>     what am i doing wrong?
>
>     thanks
>     lorenz
>     _______________________________________________
>     This mail is sent to you from the opencms-dev mailing list
>     To change your list options, or to unsubscribe from the list, please
>     visit
>     http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev
>
>
>
>
>
>
> _______________________________________________
> This mail is sent to you from the opencms-dev mailing list
> To change your list options, or to unsubscribe from the list, please visit
> http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev
>
>
>



More information about the opencms-dev mailing list