开发者

Getting tabindex value for UIComponent

开发者 https://www.devze.com 2023-01-27 23:46 出处:网络
I\'d like to get tabindex of cur开发者_运维知识库rent UIComponent in generic way. getTabIndex() is available only for few components. Is there any way of getting it without casting component to proper

I'd like to get tabindex of cur开发者_运维知识库rent UIComponent in generic way. getTabIndex() is available only for few components. Is there any way of getting it without casting component to proper type?

I was thinking about getting tabindex attribute for current component but how to to this?


Use UIComponent#getAttributes().

Object tabindex = component.getAttributes().get("tabindex");
if (tabindex != null) {
    // ...
}
0

精彩评论

暂无评论...
验证码 换一张
取 消