javax.faces.el.ValueBinding Java Examples

The following examples show how to use javax.faces.el.ValueBinding. 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: MapValuePickerData.java    From XPagesExtensionLibrary with Apache License 2.0 6 votes vote down vote up
/**
 * Gets the options for the Value Picker, from the "options" property
 * 
 * @return Map<String, String> of values
 * @since org.openntf.domino.xsp 4.5.0
 */
@SuppressWarnings("unchecked") //$NON-NLS-1$
public Map<String, String> getOptions() {
	if (options != null) {
		return options;
	}
	ValueBinding vb = getValueBinding("options"); //$NON-NLS-1$
	if (vb != null) {
		Object vbVal = vb.getValue(getFacesContext());
		if( null != vbVal ){
			return (Map<String, String>) vbVal;
		}
	}

	return null;
}
 
Example #2
Source File: CollectionValuePickerData.java    From XPagesExtensionLibrary with Apache License 2.0 6 votes vote down vote up
/**
 * Gets the Collection from the "collection" property, throwing an error if
 * it is not a valid Collection
 * 
 * @return Collection<String> of values to use in the picker
 * @since org.openntf.domino.xsp 4.5.0
 */
@SuppressWarnings("unchecked")  //$NON-NLS-1$
public Collection<String> getCollection() {
	if (collection != null) {
		return collection;
	}
	ValueBinding vb = getValueBinding("collection"); //$NON-NLS-1$
	if (vb != null) {
		Object vbVal = vb.getValue(getFacesContext());
		if( null != vbVal ){
			return (Collection<String>) vbVal;
		}
	}

	return null;
}
 
Example #3
Source File: UIToolBarButton.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getIcon() {
    if (null != this.icon) {
        return this.icon;
    }
    ValueBinding _vb = getValueBinding("icon"); //$NON-NLS-1$
    if (_vb != null) {
        String val = (String) _vb.getValue(FacesContext.getCurrentInstance());
        if(val!=null) {
            return val;
        }
    } 
    return null;
}
 
Example #4
Source File: ViewEntryTreeNode.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public boolean isKeysExactMatch() {
    if (keysExactMatch != null) {
        return keysExactMatch;
    }
    ValueBinding vb = getValueBinding("keysExactMatch"); //$NON-NLS-1$
    if (vb != null) {
        Boolean v = (Boolean)vb.getValue(getFacesContext());
        if(v!=null) {
            return v;
        }
    }

    return false;
}
 
Example #5
Source File: DashNode.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getBadgeStyle() {
    if (null != _badgeStyle) {
        return _badgeStyle;
    }
    ValueBinding binding = getValueBinding("badgeStyle"); // $NON-NLS-1$
    if (binding != null) {
        return (java.lang.String) binding.getValue(getFacesContext());
    } 
    else {
        return null;
    }
}
 
Example #6
Source File: ResponsiveApplicationConfiguration.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getPageWidth() {
      if(pageWidth!=null) {
          return pageWidth;
      }
      ValueBinding vb = getValueBinding("pageWidth"); // $NON-NLS-1$
      if(vb!=null) {
      	String s = (String)vb.getValue(getFacesContext());
          if(s!=null) {
              return s;
          }
      }
return null;
  }
 
Example #7
Source File: UIDojoStoreComponent.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getStoreTitle() {
    if (storeTitle != null)
        return storeTitle;
    ValueBinding vb = getValueBinding("storeTitle"); // $NON-NLS-1$
    if (vb != null)
        return (String) vb.getValue(getFacesContext());
    else
        return null;
}
 
Example #8
Source File: SlideNode.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
/**
 * @return the backgroundColor
 */
public String getBackgroundSrc() {
    if (null != _backgroundSrc) {
        return _backgroundSrc;
    }
    ValueBinding binding = getValueBinding("backgroundSrc"); // $NON-NLS-1$
    if (binding != null) {
        return (java.lang.String) binding.getValue(getFacesContext());
    } 
    else {
        return null;
    }
}
 
Example #9
Source File: DominoService.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public boolean isCompact() {
       if (compact != null) {
           return compact;
       }        
       ValueBinding vb = getValueBinding("compact"); //$NON-NLS-1$
       if (vb != null) {
           Boolean val = (Boolean)vb.getValue(getFacesContext());
		if(val!=null) {
			return val;
		}
       }
       return false;
}
 
Example #10
Source File: TagUtil.java    From sakai with Educational Community License v2.0 5 votes vote down vote up
/**
 * Set a ValueBinding on a component - used by tags setProperties() method.
 */
public static void setValueBinding(UIComponent component, String name, String value)
{
    FacesContext context = FacesContext.getCurrentInstance();
    Application app = context.getApplication();
    ValueBinding vb = app.createValueBinding(value);
    component.setValueBinding(name, vb);
}
 
Example #11
Source File: AbstractDataView.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public boolean isDisableHideRow() {
    if (disableHideRow != null) {
        return disableHideRow;
    }
    ValueBinding vb = getValueBinding("disableHideRow"); // $NON-NLS-1$
    if (vb != null) {
        Boolean b = (Boolean) vb.getValue(getFacesContext());
        if (b != null) {
            return b;
        }
    }
    return false;
}
 
Example #12
Source File: ViewTagCloudData.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getLinkRequestParam() {
    if (null != this.linkRequestParam) {
        return this.linkRequestParam;
    }
    ValueBinding vb = getValueBinding("linkRequestParam"); //$NON-NLS-1$
    if (vb != null) {
        return (String)vb.getValue(getFacesContext());
    } 
    return null;
}
 
Example #13
Source File: CustomSelectOneRadio.java    From sakai with Educational Community License v2.0 5 votes vote down vote up
public String returnValueBindingAsString(String attr) {
	ValueBinding valueBinding = getValueBinding(attr);	
	if (valueBinding != null)
		return (String)valueBinding.getValue(this.getFacesContext());
	else
		return null;			
}
 
Example #14
Source File: UIWidgetContainer.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getOnScrollDown() {
	if (null != this.onScrollDown) {
		return this.onScrollDown;
	}
	ValueBinding vb = getValueBinding("onScrollDown"); //$NON-NLS-1$
	if (vb != null) {
		return (String) vb.getValue(getFacesContext());
	} else {
		return null;
	}
}
 
Example #15
Source File: BasicComplexTreeNode.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
@Override
public String getStyle() {
	if (null != this.style) {
		return this.style;
	}
	ValueBinding _vb = getValueBinding("style"); //$NON-NLS-1$
	if (_vb != null) {
		return (java.lang.String) _vb.getValue(getFacesContext());
	}
	return super.getStyle();
}
 
Example #16
Source File: BasicComplexTreeNode.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
@Override
public String getImageWidth() {
    if (null != this.imageWidth) {
        return this.imageWidth;
    }
    ValueBinding _vb = getValueBinding("imageWidth"); //$NON-NLS-1$
    if (_vb != null) {
        return (java.lang.String) _vb.getValue(getFacesContext());
    }
    return super.getImageWidth();
}
 
Example #17
Source File: UIDojoWidgetBase.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getTooltip() {
    if (null != this.tooltip) {
        return this.tooltip;
    }
    ValueBinding _vb = getValueBinding("tooltip"); //$NON-NLS-1$
    if (_vb != null) {
        return (java.lang.String) _vb.getValue(FacesContext.getCurrentInstance());
    } else {
        return null;
    }
}
 
Example #18
Source File: RedirectHeaderRule.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getHeaderPattern() {
	if (null != this.headerPattern) {
		return this.headerPattern;
	}
	ValueBinding vb = getValueBinding("headerPattern"); //$NON-NLS-1$
	if (vb != null) {
		return (String) vb.getValue(getFacesContext());
	} else {
		return null;
	}
}
 
Example #19
Source File: BasicApplicationConfigurationImpl.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public boolean isLegal() {
    if(legal!=null) {
        return legal;
    }
    ValueBinding vb = getValueBinding("legal"); // $NON-NLS-1$
    if(vb!=null) {
        Boolean b = (Boolean)vb.getValue(getFacesContext());
        if(b!=null) {
            return b;
        }
    }
    return true;
}
 
Example #20
Source File: IconEntry.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getUrl() {
    if(url!=null) {
        return url;
    }
    ValueBinding vb = getValueBinding("url"); // $NON-NLS-1$
    if(vb!=null) {
        return (String)vb.getValue(getFacesContext());
    }
    return null;
}
 
Example #21
Source File: ComplexLeafTreeNode.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
@Override
public String getSubmitValue() {
	if (null != this.submitValue) {
		return this.submitValue;
	}
	ValueBinding _vb = getValueBinding("submitValue"); //$NON-NLS-1$
	if (_vb != null) {
		return (java.lang.String) _vb.getValue(FacesContext.getCurrentInstance());
	}
	return super.getSubmitValue();
}
 
Example #22
Source File: UIDojoTextarea.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public int getCols() {
	if (null != this.cols) {
		return this.cols;
	}
	ValueBinding _vb = getValueBinding("cols"); //$NON-NLS-1$
	if (_vb != null) {
		Number val = (Number) _vb.getValue(FacesContext.getCurrentInstance());
		if(val!=null) {
			return val.intValue();
		}
	} 
	return -1;
}
 
Example #23
Source File: UIDojoTabContainer.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public boolean isUseSlider() {
    if (null != this.useSlider) {
        return this.useSlider;
    }
    ValueBinding _vb = getValueBinding("useSlider"); //$NON-NLS-1$
    if (_vb != null) {
        Boolean val = (java.lang.Boolean) _vb.getValue(FacesContext.getCurrentInstance());
        if(val!=null) {
            return val;
        }
    }
    return true;
}
 
Example #24
Source File: UIForumPost.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getStyleClass() {
    if (null != this.styleClass) {
        return this.styleClass;
    }
    ValueBinding _vb = getValueBinding("styleClass"); //$NON-NLS-1$
    if (_vb != null) {
        return (java.lang.String) _vb.getValue(getFacesContext());
    } else {
        return null;
    }
}
 
Example #25
Source File: UIDynamicContent.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getDefaultFacet() {
    if (null != this.defaultFacet) {
        return this.defaultFacet;
    }
    ValueBinding _vb = getValueBinding("defaultFacet"); //$NON-NLS-1$
    if (_vb != null) {
        return (java.lang.String) _vb.getValue(getFacesContext());
    } else {
        return null;
    }
}
 
Example #26
Source File: UIDojoFormWidgetBase.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getOnKeyPress() {
	if (null != this.onKeyPress) {
		return this.onKeyPress;
	}
	ValueBinding _vb = getValueBinding("onKeyPress"); //$NON-NLS-1$
	if (_vb != null) {
		return (java.lang.String) _vb.getValue(FacesContext.getCurrentInstance());
	} else {
		return null;
	}
}
 
Example #27
Source File: AbstractPicker.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getPickerIcon() {
    if (null != this.pickerIcon) {
        return this.pickerIcon;
    }
    ValueBinding _vb = getValueBinding("pickerIcon"); //$NON-NLS-1$
    if (_vb != null) {
        return (java.lang.String) _vb.getValue(FacesContext.getCurrentInstance());
    } else {
        return null;
    }
}
 
Example #28
Source File: UIDojoDataGrid.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getOnStyleRow() {
	if (null != this.onStyleRow) {
		return this.onStyleRow;
	}
	ValueBinding _vb = getValueBinding("onStyleRow"); //$NON-NLS-1$
	if (_vb != null) {
		return (java.lang.String) _vb.getValue(getFacesContext());
	} else {
		return null;
	}
}
 
Example #29
Source File: UIPagerDetail.java    From XPagesExtensionLibrary with Apache License 2.0 5 votes vote down vote up
public String getShowText() {
	if(showText!=null) {
		return showText;
	}
	ValueBinding vb = getValueBinding("showText"); //$NON-NLS-1$
	if(vb!=null) {
		return (String)vb.getValue(getFacesContext());
	}
	return null;
}
 
Example #30
Source File: ShowAreaTag.java    From sakai with Educational Community License v2.0 5 votes vote down vote up
public static void setValueBinding(UIComponent component,
    String attributeName, String attributeValue)
{
  FacesContext context = FacesContext.getCurrentInstance();
  Application app = context.getApplication();
  ValueBinding vb = app.createValueBinding(attributeValue);
  component.setValueBinding(attributeName, vb);
}