Java Code Examples for com.vaadin.ui.Link#setId()
The following examples show how to use
com.vaadin.ui.Link#setId() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: PageLinkFactoryImpl.java From cia with Apache License 2.0 | 5 votes |
@Override public Link addCommitteePageLink(final ViewRiksdagenCommittee data) { final Link pageLink = new Link(COMMITTEE + data.getEmbeddedId().getDetail(), new ExternalResource(PAGE_PREFIX + UserViews.COMMITTEE_VIEW_NAME + PAGE_SEPARATOR + data.getEmbeddedId().getOrgCode())); pageLink.setId(ViewAction.VISIT_COMMITTEE_VIEW.name() + PAGE_SEPARATOR + data.getEmbeddedId().getOrgCode()); pageLink.setIcon(VaadinIcons.GROUP); return pageLink; }
Example 2
Source File: PageLinkFactoryImpl.java From cia with Apache License 2.0 | 5 votes |
@Override public Link addMinistryPageLink(final ViewRiksdagenMinistry data) { final Link pageLink = new Link(MINISTRY + data.getNameId(), new ExternalResource(PAGE_PREFIX + UserViews.MINISTRY_VIEW_NAME + PAGE_SEPARATOR + data.getNameId())); pageLink.setId(ViewAction.VISIT_MINISTRY_VIEW.name() + PAGE_SEPARATOR + data.getNameId()); pageLink.setIcon(VaadinIcons.GROUP); return pageLink; }
Example 3
Source File: PageLinkFactoryImpl.java From cia with Apache License 2.0 | 5 votes |
@Override public Link addPartyPageLink(final ViewRiksdagenParty data) { final Link pageLink = new Link(PARTY + data.getPartyName(), new ExternalResource(PAGE_PREFIX + UserViews.PARTY_VIEW_NAME + PAGE_SEPARATOR + data.getPartyId())); pageLink.setId(ViewAction.VISIT_PARTY_VIEW.name() + PAGE_SEPARATOR + data.getPartyId()); pageLink.setIcon(VaadinIcons.GROUP); return pageLink; }
Example 4
Source File: PageLinkFactoryImpl.java From cia with Apache License 2.0 | 5 votes |
@Override public Link createAdminPagingLink(final String label,final String page, final String pageId, final String pageNr) { final Link pageLink = new Link(label, new ExternalResource(PAGE_PREFIX + page + PAGE_SEPARATOR + "[" + pageNr + "]")); pageLink.setId(page +"ShowPage" + PAGE_SEPARATOR + pageNr); pageLink.setIcon(VaadinIcons.SERVER); return pageLink; }
Example 5
Source File: PageLinkFactoryImpl.java From cia with Apache License 2.0 | 5 votes |
@Override public Link createLoginPageLink() { final Link pageLink = new Link("Login", new ExternalResource( LINK_SEPARATOR + CommonsViews.MAIN_VIEW_NAME + PAGE_SEPARATOR + ApplicationPageMode.LOGIN)); pageLink.setId(ViewAction.VISIT_LOGIN.name()); pageLink.setIcon(VaadinIcons.SIGN_IN); return pageLink; }
Example 6
Source File: PageLinkFactoryImpl.java From cia with Apache License 2.0 | 5 votes |
@Override public Link createMainViewPageLink() { final Link pageLink = new Link(MAIN_VIEW_LINK_TEXT, new ExternalResource( LINK_SEPARATOR + CommonsViews.MAIN_VIEW_NAME)); pageLink.setId(ViewAction.VISIT_MAIN_VIEW.name()); pageLink.setIcon(VaadinIcons.STAR); return pageLink; }
Example 7
Source File: PageLinkFactoryImpl.java From cia with Apache License 2.0 | 5 votes |
@Override public Link createPoliticianPageLink(final PersonData personData) { final Link pageLink = new Link(POLITICIAN + personData.getFirstName() + ' ' + personData.getLastName(), new ExternalResource(PAGE_PREFIX + UserViews.POLITICIAN_VIEW_NAME + PAGE_SEPARATOR + personData.getId())); pageLink.setId(ViewAction.VISIT_POLITICIAN_VIEW.name() + PAGE_SEPARATOR + personData.getId()); pageLink.setIcon(VaadinIcons.BUG); return pageLink; }
Example 8
Source File: PageLinkFactoryImpl.java From cia with Apache License 2.0 | 5 votes |
@Override public Link createRegisterPageLink() { final Link pageLink = new Link("Register", new ExternalResource( LINK_SEPARATOR + CommonsViews.MAIN_VIEW_NAME + PAGE_SEPARATOR + ApplicationPageMode.REGISTER)); pageLink.setId(ViewAction.VISIT_REGISTER.name()); pageLink.setIcon(VaadinIcons.RANDOM); return pageLink; }
Example 9
Source File: PageLinkFactoryImpl.java From cia with Apache License 2.0 | 5 votes |
@Override public Link createUserHomeViewPageLink() { final Link pageLink = new Link("User account:", new ExternalResource(PAGE_PREFIX + UserViews.USERHOME_VIEW_NAME)); pageLink.setId(ViewAction.VISIT_USER_HOME_VIEW.name()); pageLink.setIcon(VaadinIcons.USER); return pageLink; }
Example 10
Source File: SPUIComponentProvider.java From hawkbit with Eclipse Public License 1.0 | 4 votes |
/** * Method to create a link. * * @param id * of the link * @param name * of the link * @param resource * path of the link * @param icon * of the link * @param targetOpen * specify how the link should be open (f. e. new windows = _blank) * @param style * chosen style of the link. Might be {@code null} if no style should * be used * @return a link UI component */ public static Link getLink(final String id, final String name, final String resource, final FontAwesome icon, final String targetOpen, final String style) { final Link link = new Link(name, new ExternalResource(resource)); link.setId(id); link.setIcon(icon); link.setDescription(name); link.setTargetName(targetOpen); if (style != null) { link.setStyleName(style); } return link; }