siva636
siva636

Reputation: 16441

How to access Composite Component attribute values in the backing UIComponent?

We can access the Composite Component attribute values (defiled in the interface section), in the implimentation like #{cc.attrs.attributeName}

How can we access this value in the backing component?

Upvotes: 5

Views: 3844

Answers (1)

BalusC
BalusC

Reputation: 1108782

It's just available inside any of the methods by the inherited getAttributes() method which returns a Map<String, Object> with the attribute name as map key and attribute value as map value.

Bar bar = (Bar) getAttributes().get("bar");
// ...

Upvotes: 7

Related Questions