public boolean triggersAreEnabled() { return ((MondrianProperties) this).EnableTriggers.get(); }
/** * Sets the value of this boolean property. * * @return The previous value, or the default value if not set. */ public boolean set(boolean value) { String prevValue = setString(Boolean.toString(value)); if (prevValue == null) { prevValue = getDefaultValue(); if (prevValue == null) { return false; } } return toBoolean(prevValue); } }
/** * Retrieves the value of this boolean property. * * <p>Returns <code>true</code> if the property exists, and its value is * <code>1</code>, <code>true</code> or <code>yes</code>; returns <code> * false</code> otherwise. */ public boolean get() { return booleanValue(); }
/** * Retrieves the value of this boolean property. * * <p>Returns <code>true</code> if the property exists, and its value is * <code>1</code>, <code>true</code> or <code>yes</code>; returns <code> * false</code> otherwise. */ public boolean get(boolean defaultValue) { final String value = getInternal( Boolean.toString(defaultValue), false); if (value == null) { return defaultValue; } return toBoolean(value); }
final boolean advanced = Boolean.parseBoolean(advancedFlag); final boolean enableRowCount = MondrianProperties.instance().EnableTotalCount.booleanValue(); final int[] rowCountSlot = enableRowCount ? new int[]{0} : null; OlapConnection connection = null;
/** * Returns whether the use of a <code>MemoryMonitor</code> is enabled. * * @return <code>true</code> if enabled and <code>false</code> otherwise. */ protected boolean enabled() { return MondrianProperties.instance().MemoryMonitor.get(); }
/** * Generates a normalized form of a name, for use as a key into a map. * Returns the upper case name if * {@link MondrianProperties#CaseSensitive} is true, the name unchanged * otherwise. */ public static String normalizeName(String s) { return MondrianProperties.instance().CaseSensitive.get() ? s : s.toUpperCase(); }
/** * Creates a SqlQuery using a given dialect and inheriting the formatting * preferences from {@link MondrianProperties#GenerateFormattedSql} * property. * * @param dialect Dialect */ public SqlQuery(Dialect dialect) { this( dialect, MondrianProperties.instance().GenerateFormattedSql.get()); }
/** * Compares two names. * Takes into account the {@link MondrianProperties#CaseSensitive case * sensitive option}. * Names must not be null. */ public static int compareName(String s, String t) { boolean caseSensitive = MondrianProperties.instance().CaseSensitive.get(); return caseSensitive ? s.compareTo(t) : s.compareToIgnoreCase(t); }
boolean isCacheDisabled() { return MondrianProperties.instance().DisableCaching.get(); }
/** * Returns whether two names are equal. * Takes into account the * {@link MondrianProperties#CaseSensitive case sensitive option}. * Names may be null. */ public static boolean equalName(String s, String t) { if (s == null) { return t == null; } boolean caseSensitive = MondrianProperties.instance().CaseSensitive.get(); return caseSensitive ? s.equals(t) : s.equalsIgnoreCase(t); }
public static void setNativeNonEmptyValue() { enabled = MondrianProperties.instance().EnableNativeNonEmpty.get(); }
BuilderImpl( SchemaReader schemaReader, Cube cube, List<Hierarchy> hierarchyList) { this.schemaReader = schemaReader; this.cube = cube; this.hierarchyList = hierarchyList; final MondrianProperties props = MondrianProperties.instance(); final boolean load = ((RolapCube) cube).isLoadInProgress(); this.ignoreInvalid = (load ? props.IgnoreInvalidMembers.get() : props.IgnoreInvalidMembersDuringQuery.get()); }
/** * Compares two names. if case sensitive flag is false, * apply finer grain difference with case sensitive * Takes into account the {@link MondrianProperties#CaseSensitive case * sensitive option}. * Names must not be null. */ public static int caseSensitiveCompareName(String s, String t) { boolean caseSensitive = MondrianProperties.instance().CaseSensitive.get(); if (caseSensitive) { return s.compareTo(t); } else { int v = s.compareToIgnoreCase(t); // if ignore case returns 0 compare in a case sensitive manner // this was introduced to solve an issue with Member.equals() // and Member.compareTo() not agreeing with each other return v == 0 ? s.compareTo(t) : v; } }
/** * @return true if the relevant property for ignoring invalid members is * set to true for this query's environment (a different property is * checked depending on whether environment is schema load vs query * validation) */ public boolean ignoreInvalidMembers() { MondrianProperties props = MondrianProperties.instance(); final boolean load = ((RolapCube) getCube()).isLoadInProgress(); return !strictValidation && (load ? props.IgnoreInvalidMembers.get() : props.IgnoreInvalidMembersDuringQuery.get()); }
private boolean shouldExpandNonEmpty(Exp exp) { return MondrianProperties.instance().ExpandNonNative.get() // && !MondrianProperties.instance().EnableNativeCrossJoin.get() || isCheapSet(exp); }
public boolean put(SegmentHeader header, SegmentBody body) { if (MondrianProperties.instance().DisableCaching.get()) { return true; } for (SegmentCacheWorker worker : workers) { worker.put(header, body); } return true; }