/** * {@inheritDoc} */ @Override public Object getDisplayValue(final String object) { final IModel<String> resourceModel = ResourceModelFactory.newResourceModel(ResourceBundleKey .builder().key(propertiesKeyPrefix + "." + object).defaultValue("").build(), component); final String value = resourceModel.getObject(); return value; }
/** * {@inheritDoc} */ @Override public Object getDisplayValue(final String object) { final IModel<String> resourceModel = ResourceModelFactory.newResourceModel( ResourceBundleKey.builder().key(object).defaultValue("").build(), component); final String value = resourceModel.getObject(); return value; }
/** * Factory method to create a new {@link IModel} for the MailtoAddressModel. This method is * invoked in the constructor from this class and can be overridden so users can provide their * own version of a new {@link IModel} for the MailtoAddressModel. * * @param params * the params * @return the new {@link IModel} for the MailtoAddressModel. */ protected IModel<String> newMailToAddressModel(final Object[] params) { return ResourceModelFactory.newResourceModel( ResourceBundleKey.builder().key("global.mailto.address").parameters(params).build(), this); }
/** * Factory method to create a new {@link IModel} for the 'slogan'. This method is invoked in the * constructor from this class and can be overridden so users can provide their own version of a * new {@link IModel} for the 'slogan'. * * @param domainNameParams * the domain name params * @return the new {@link IModel} for the 'slogan'. */ protected IModel<String> newSloganModel(final Object[] domainNameParams) { return ResourceModelFactory.newResourceModel( ResourceBundleKey.builder().key("main.global.company.url.and.slogan.label") .parameters(domainNameParams).defaultValue("").build(), this); }
/** * Factory method for create a new {@link ResourceBundleKey} for the content of the * {@link MultiLineLabel}. This method is invoked in the constructor from the derived classes * and can be overridden so users can provide their own version of a new * {@link ResourceBundleKey} for the content of the {@link MultiLineLabel}. Note: this method is * only invoked if model is null of this panel. * * @return the new {@link IModel}. */ protected ResourceBundleKey newContentResourceKey() { return ResourceBundleKey.builder().key("content.label").build(); }
/** * Factory method to create a new StringResourceModel from the given key. * * @param key * the key * @return the new {@link IModel} */ protected IModel<String> newIModel(final String key) { return ResourceModelFactory.newResourceModel(ResourceBundleKey.builder().key(key) .defaultValue("").build(), this); }
/** * Factory method that can be overwritten for new meta tag content for description. * * @return the new <code>{@link IModel}</code> for the meta tag content for description. */ protected IModel<String> newDescription() { return ResourceModelFactory.newResourceModel( ResourceBundleKey.builder().key("page.meta.description").defaultValue("").build(), this); }
/** * Factory method to create a new StringResourceModel from the given key. * * @param key * the key * @return the new {@link IModel} */ protected IModel<String> newIModel(final String key) { return ResourceModelFactory .newResourceModel(ResourceBundleKey.builder().key(key).defaultValue("").build(), this); }
/** * Factory method that can be overwritten for new meta tag content for the title. * * @return the new <code>IModel</code> */ protected IModel<String> newTitle() { return ResourceModelFactory.newResourceModel( ResourceBundleKey.builder().key("page.title").defaultValue("Home page").build(), this); }
/** * Factory method that can be overwritten for new meta tag content for keywords. * * @return the new <code>{@link IModel}</code> for the meta tag content for keywords. */ protected IModel<String> newKeywords() { return ResourceModelFactory.newResourceModel( ResourceBundleKey.builder().key("page.meta.keywords").defaultValue("").build(), this); }
/** * Creates a new {@link IModel} from the given key. * * @param key * the key * @return the new {@link IModel} from the given key. */ protected IModel<String> newIModel(final String key) { return ResourceModelFactory .newResourceModel(ResourceBundleKey.builder().key(key).defaultValue("").build(), this); }
/** * Factory method to create a new {@link StringResourceModel} from the given ResourceBundleKey. * * @param resourceBundleKey * the resource bundle key as String * @return a new {@link StringResourceModel} as an {@link IModel} */ public static IModel<String> newResourceModel(final String resourceBundleKey) { return newResourceModel(ResourceBundleKey.builder().key(resourceBundleKey).build()); }
/** * Factory method that can be overwritten for new meta tag content for keywords. * * @return the new <code>IModel</code> */ protected IModel<String> newKeywords() { return ResourceModelFactory.newResourceModel( ResourceBundleKey.builder().key("page.meta.keywords").defaultValue("").build(), this); }
/** * Factory method that can be overwritten for new meta tag content for description. * * @return the new <code>IModel</code> */ protected IModel<String> newDescription() { return ResourceModelFactory.newResourceModel( ResourceBundleKey.builder().key("page.meta.description").defaultValue("").build(), this); }
/** * Factory method for create a new {@link ResourceBundleKey} for the header of the {@link Label} * . This method is invoked in the constructor from the derived classes and can be overridden so * users can provide their own version of a new {@link ResourceBundleKey} for the header of the * {@link Label}. Note: this method is only invoked if model is null of this panel. * * @return the new {@link IModel}. */ protected ResourceBundleKey newHeaderResourceKey() { return ResourceBundleKey.builder().key("header.label").build(); }
/** * Factory method for create a new {@link ResourceBundleKey} for the header of the {@link Label} * . This method is invoked in the constructor from the derived classes and can be overridden so * users can provide their own version of a new {@link ResourceBundleKey} for the header of the * {@link Label}. Note: this method is only invoked if model is null of this panel. * * @return the new {@link IModel}. */ protected ResourceBundleKey newHeaderResourceKey() { return ResourceBundleKey.builder().key("header.label").build(); }
/** * Factory method that can be overwritten for new meta tag content for the title. * * @return the new <code>{@link IModel}</code> for the meta tag content for title. */ protected IModel<String> newTitle() { return ResourceModelFactory.newResourceModel( ResourceBundleKey.builder().key("page.title").defaultValue("Home page").build(), this); }
/** * Factory method to create a new {@link IModel} for the MailtoViewModel. This method is invoked * in the constructor from this class and can be overridden so users can provide their own * version of a new {@link IModel} for the MailtoViewModel. * * @param params * the params * @return the new {@link IModel} for the MailtoViewModel. */ protected IModel<String> newMailToViewModel(final Object[] params) { return ResourceModelFactory.newResourceModel(ResourceBundleKey.builder() .key("global.compamy.mailto.view").parameters(params).build(), this); }
/** * Creates a new {@link IModel} from the given key. * * @param key * the key * @return the new {@link IModel} from the given key. */ protected IModel<String> newIModel(final String key) { return ResourceModelFactory.newResourceModel(ResourceBundleKey.builder().key(key) .defaultValue("").build(), this); }
/** * Factory method for create a new {@link ResourceBundleKey} for the content of the * {@link MultiLineLabel}. This method is invoked in the constructor from the derived classes * and can be overridden so users can provide their own version of a new * {@link ResourceBundleKey} for the content of the {@link MultiLineLabel}. Note: this method is * only invoked if model is null of this panel. * * @return the new {@link IModel}. */ protected ResourceBundleKey newContentResourceKey() { return ResourceBundleKey.builder().key("content.label").build(); }