/** * Returns the String value as a boolean. If the value is <code>null</code>, * the {@link #DEFAULT_BOOLEAN} is returned. If the value does not match a * {@link #BOOLEANS} value, <code>false</code> is returned. * * @param value the value to convert * @return the value as a boolean */ public static boolean getBoolean(String value) { return getBoolean(value, DEFAULT_BOOLEAN); }
/** * Returns the Object value as a boolean. If the value is <code>null</code>, * the {@link #DEFAULT_BOOLEAN} is returned. If the value does not match a * {@link #BOOLEANS} value, <code>false</code> is returned. * * @param value the value to convert * @return the value as a boolean */ public static boolean getBoolean(Object value) { return getBoolean(value, DEFAULT_BOOLEAN); }
public boolean isQuerySuggestionEnabled() { return GetterUtil.getBoolean( _attributes.get(PropsKeys.INDEX_SEARCH_QUERY_SUGGESTION_ENABLED), _INDEX_SEARCH_QUERY_SUGGESTION_ENABLED); }
public boolean isCollatedSpellCheckResultEnabled() { return GetterUtil.getBoolean( _attributes.get( PropsKeys.INDEX_SEARCH_COLLATED_SPELL_CHECK_RESULT_ENABLED), _INDEX_SEARCH_COLLATED_SPELL_CHECK_RESULT_ENABLED); }
public boolean isQueryIndexingEnabled() { return GetterUtil.getBoolean( _attributes.get(PropsKeys.INDEX_SEARCH_QUERY_INDEXING_ENABLED), _INDEX_SEARCH_QUERY_INDEXING_ENABLED); }
public boolean isScoreEnabled() { return GetterUtil.getBoolean( _attributes.get(PropsKeys.INDEX_SEARCH_SCORING_ENABLED), _INDEX_SEARCH_SCORING_ENABLED); }
/** * Returns the request parameter value as a boolean. If the parameter is * missing or not convertible to a boolean, <code>false</code> is returned. * * @param request the servlet request from which to read the parameter * @param param the name of the parameter * @return the request parameter value as a boolean */ public static boolean getBoolean(HttpServletRequest request, String param) { return GetterUtil.getBoolean(request.getParameter(param)); }
public boolean isHighlightRequireFieldMatch() { return GetterUtil.getBoolean( _attributes.get( PropsKeys.INDEX_SEARCH_HIGHLIGHT_REQUIRE_FIELD_MATCH), _INDEX_SEARCH_HIGHLIGHT_REQUIRE_FIELD_MATCH); }
public BaseOpenSearchImpl() { Class<?> clazz = getClass(); _enabled = GetterUtil.getBoolean(PropsUtil.get(clazz.getName()), true); _openSearchURL = StringPool.BLANK; _openSearchDescriptionURL = StringPool.BLANK; }
public boolean getBoolean(String key) { boolean value = false; Object object = get(key); if (object instanceof Boolean) { value = ((Boolean)object).booleanValue(); } else { value = GetterUtil.getBoolean((String)object); } return value; }
protected boolean getBoolean( PollerRequest pollerRequest, String name, boolean defaultValue) { Map<String, String> parameterMap = pollerRequest.getParameterMap(); return GetterUtil.getBoolean(parameterMap.get(name), defaultValue); }
public static boolean getBoolean( Properties properties, HttpServletRequest request, String param, boolean defaultValue) { String propertiesValue = properties.getProperty(param, null); boolean getterUtilValue = GetterUtil.getBoolean( propertiesValue, defaultValue); return ParamUtil.get(request, param, getterUtilValue); }
private static boolean _isTransactionalCacheEnabled() { if (_transactionalCacheEnabled == null) { _transactionalCacheEnabled = GetterUtil.getBoolean( PropsUtil.get(PropsKeys.TRANSACTIONAL_CACHE_ENABLED)); } return _transactionalCacheEnabled; }
@Override public void init() throws PortletException { super.init(); addProcessActionSuccessMessage = GetterUtil.getBoolean( getInitParameter("add-process-action-success-action"), true); alwaysSendRedirect = GetterUtil.getBoolean( getInitParameter("always-send-redirect")); }
private boolean _isOverwrite(HttpServletRequest request) { String value = GetterUtil.getString(request.getHeader("Overwrite")); if (StringUtil.equalsIgnoreCase(value, "F") || !GetterUtil.getBoolean(value)) { return false; } return true; }
public BaseOpenSearchImpl( String openSearchURL, String openSearchDescriptionURL) { _openSearchURL = openSearchURL; _openSearchDescriptionURL = openSearchDescriptionURL; _enabled = GetterUtil.getBoolean( PropsUtil.get(ClassUtil.getClassName(this)), true); }
public static boolean getBoolean( PortletPreferences preferences, HttpServletRequest request, String param, boolean defaultValue) { String preferencesValue = preferences.getValue(param, null); boolean getterUtilValue = GetterUtil.getBoolean( preferencesValue, defaultValue); return ParamUtil.get(request, param, getterUtilValue); }
public static boolean getBoolean( UnicodeProperties properties, PortletRequest portletRequest, String param, boolean defaultValue) { String propertiesValue = properties.getProperty(param, null); boolean getterUtilValue = GetterUtil.getBoolean( propertiesValue, defaultValue); return ParamUtil.get(portletRequest, param, getterUtilValue); }
public static boolean getBoolean( PortletPreferences preferences, PortletRequest portletRequest, String param, boolean defaultValue) { String preferencesValue = preferences.getValue(param, null); boolean getterUtilValue = GetterUtil.getBoolean( preferencesValue, defaultValue); return ParamUtil.get(portletRequest, param, getterUtilValue); }
@Override public boolean isIndexerEnabled() { if (_indexerEnabled == null) { String className = getClassName(); String indexerEnabled = PropsUtil.get( PropsKeys.INDEXER_ENABLED, new com.liferay.portal.kernel.configuration.Filter(className)); _indexerEnabled = GetterUtil.getBoolean(indexerEnabled, true); return _indexerEnabled; } return _indexerEnabled; }