Package org.jabusuite.webclient.controls.language.helper

Examples of org.jabusuite.webclient.controls.language.helper.JbsLangEntryHelper


            Iterator<JbsLanguage> it = languages.iterator();
            while (it.hasNext()) {
                JbsLanguage language = it.next();
                //LangTxtField txtField = new LangTxtField(language);
                JbsLangEntryHelper txtField = this.createTextField(language);
                textFields.add(txtField);
            }
        } catch (Exception e) {
            logger.error("Error creating language-text-fields.", e);
            e.printStackTrace();
View Full Code Here


        JbsLangStrings langStrings = new JbsLangStrings();

        if (this.getTextFields() != null) {
            Iterator<JbsLangEntryHelper> it = this.getTextFields().iterator();
            while (it.hasNext()) {
                JbsLangEntryHelper txtField = it.next();
                JbsLangString langString = new JbsLangString(txtField.getLanguage());
                langString.setText(txtField.getText());
                langStrings.add(langString);
            }
        }
        return langStrings;
    }
View Full Code Here

     */
    public void setLangStrings(JbsLangStrings langStrings) {
        Iterator<JbsLangString> it = langStrings.iterator();
        while (it.hasNext()) {
            JbsLangString langString = it.next();
            JbsLangEntryHelper textField = this.getLangTextField(langString.getLanguage());
            if (textField != null) {
                textField.setText(langString.getText());
            }
        }
    }
View Full Code Here

     * Returns the text-field for the specified language
     * @param language
     * @return The textField for the specified language or nul if no matching field exists.
     */
    public JbsLangEntryHelper getLangTextField(JbsLanguage language) {
        JbsLangEntryHelper result = null;
        if (this.getTextFields() != null) {
            Iterator<JbsLangEntryHelper> it = this.getTextFields().iterator();
            while ((it.hasNext()) && (result == null)) {
                JbsLangEntryHelper textField = it.next();
                if (textField.getLanguage().getLangCode().equals(language.getLangCode())) {
                    result = textField;
                }
            }
        }
        return result;
View Full Code Here

TOP

Related Classes of org.jabusuite.webclient.controls.language.helper.JbsLangEntryHelper

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.