掲示板

Accessing custom attributes from java

10年前 に Daniel Nordhoff-Vergien によって更新されました。

Accessing custom attributes from java

New Member 投稿: 7 参加年月日: 13/03/17 最新の投稿
Hi,

I have added some custom attributes to my organizations, which I want to read inside the portlet. I get the ExpandoBridge from my organization object and I can access text custom fields. But what to cast the group of X , e.g. group of integer, custom fields to? They are not collections, so what then?

Regards

Daniel
thumbnail
10年前 に Sandeep Nair によって更新されました。

RE: Accessing custom attributes from java

Liferay Legend 投稿: 1744 参加年月日: 08/11/06 最新の投稿
Hi,

It should be array of int (int [])

I would refer ExpandoValueLocalServiceUtil to see what are the return types available.

Regards,
Sandeep
10年前 に Daniel Nordhoff-Vergien によって更新されました。

RE: Accessing custom attributes from java

New Member 投稿: 7 参加年月日: 13/03/17 最新の投稿
Thanks for the hint. But can you give me an example how the custom field values of e.g. an organization object are connected to the ExpandoValueLocalServiceUtil methods?

Regards

Daniel
thumbnail
10年前 に Sandeep Nair によって更新されました。

RE: Accessing custom attributes from java

Liferay Legend 投稿: 1744 参加年月日: 08/11/06 最新の投稿
Hi,

If you see ExpandoBridgeImpl class(actual implementation class), you should see in all the implemented methods(take for example getAttribute), the actual call is made to to the methods of ExpandoValueLocalServiceUtil(or ExpandoValueServiceUtil in case permission has to be checked) class.

Regards,
Sandeep Nair