@Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((properties == null) ? 0 : properties.hashCode()); result = prime * result + ((propertySeparator == null) ? 0 : propertySeparator.hashCode()); result = prime * result + ((type == null) ? 0 : type.hashCode()); return result; }
/** * Get the {@link NonstopTimeoutBehaviorFactory} according to the active config * * @return the nonstopTimeoutBehaviorFactory */ public NonstopTimeoutBehaviorFactory getNonstopTimeoutBehaviorFactory() { switch (type) { case EXCEPTION: case NOOP: case LOCAL_READS: // no need to parse properties as not used (for now at least) return type.getTimeoutBehaviorFactory(null); case CUSTOM: return type.getTimeoutBehaviorFactory(extractProperties()); default: throw new CacheException("Unknown timeout behavior type - " + type); } }
private static void setupHibernateTimeoutBehavior(NonstopConfiguration nonstopConfig) { nonstopConfig.getTimeoutBehavior().setType(TimeoutBehaviorType.EXCEPTION.getTypeName()); }
private static void setupHibernateTimeoutBehavior(NonstopConfiguration nonstopConfig) { nonstopConfig.getTimeoutBehavior().setType(TimeoutBehaviorType.EXCEPTION.getTypeName()); }
/** * Set the type of timeout behavior * * @param type */ public void setType(String type) { if (!TimeoutBehaviorType.isValidTimeoutBehaviorType(type)) { throw new CacheException("Invalid value for timeoutBehavior type - '" + type + "'. Valid values are: '" + TimeoutBehaviorType.EXCEPTION.getTypeName() + "', '" + TimeoutBehaviorType.NOOP.getTypeName() + "', '" + TimeoutBehaviorType.LOCAL_READS.getTypeName()); } this.type = TimeoutBehaviorType.getTimeoutBehaviorTypeFromName(type); }
private static void setupHibernateTimeoutBehavior(NonstopConfiguration nonstopConfig) { nonstopConfig.getTimeoutBehavior().setType(TimeoutBehaviorType.EXCEPTION.getTypeName()); }
/** * Returns the type of timeout behavior configured * * @return the configured type */ public String getType() { return type.getTypeName(); }
/** * Set the type of timeout behavior * * @param type */ public void setType(String type) { if (!TimeoutBehaviorType.isValidTimeoutBehaviorType(type)) { throw new CacheException("Invalid value for timeoutBehavior type - '" + type + "'. Valid values are: '" + TimeoutBehaviorType.EXCEPTION.getTypeName() + "', '" + TimeoutBehaviorType.NOOP.getTypeName() + "', '" + TimeoutBehaviorType.LOCAL_READS.getTypeName()); } this.type = TimeoutBehaviorType.getTimeoutBehaviorTypeFromName(type); }
private static void setupHibernateTimeoutBehavior(NonstopConfiguration nonstopConfig) { nonstopConfig.getTimeoutBehavior().setType( TimeoutBehaviorType.EXCEPTION.getTypeName() ); } }
@Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((properties == null) ? 0 : properties.hashCode()); result = prime * result + ((propertySeparator == null) ? 0 : propertySeparator.hashCode()); result = prime * result + ((type == null) ? 0 : type.hashCode()); return result; }
/** * Set the type of timeout behavior * * @param type */ public void setType(String type) { if (!TimeoutBehaviorType.isValidTimeoutBehaviorType(type)) { throw new CacheException("Invalid value for timeoutBehavior type - '" + type + "'. Valid values are: '" + TimeoutBehaviorType.EXCEPTION.getTypeName() + "', '" + TimeoutBehaviorType.NOOP.getTypeName() + "', '" + TimeoutBehaviorType.LOCAL_READS.getTypeName()); } this.type = TimeoutBehaviorType.getTimeoutBehaviorTypeFromName(type); }
/** * Returns the type of timeout behavior configured * * @return the configured type */ public String getType() { return type.getTypeName(); }
@Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((properties == null) ? 0 : properties.hashCode()); result = prime * result + ((propertySeparator == null) ? 0 : propertySeparator.hashCode()); result = prime * result + ((type == null) ? 0 : type.hashCode()); return result; }
/** * Returns the type of timeout behavior configured * * @return the configured type */ public String getType() { return type.getTypeName(); }
private static void setupHibernateTimeoutBehavior(NonstopConfiguration nonstopConfig) { nonstopConfig.getTimeoutBehavior().setType(TimeoutBehaviorType.EXCEPTION.getTypeName()); }
/** * Set the type of timeout behavior * * @param type */ public void setType(String type) { if (!TimeoutBehaviorType.isValidTimeoutBehaviorType(type)) { throw new CacheException("Invalid value for timeoutBehavior type - '" + type + "'. Valid values are: '" + TimeoutBehaviorType.EXCEPTION.getTypeName() + "', '" + TimeoutBehaviorType.NOOP.getTypeName() + "', '" + TimeoutBehaviorType.LOCAL_READS.getTypeName()); } this.type = TimeoutBehaviorType.getTimeoutBehaviorTypeFromName(type); }
/** * Returns the type of timeout behavior configured * * @return the configured type */ public String getType() { return type.getTypeName(); }
@Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + ((properties == null) ? 0 : properties.hashCode()); result = prime * result + ((propertySeparator == null) ? 0 : propertySeparator.hashCode()); result = prime * result + ((type == null) ? 0 : type.hashCode()); return result; }
private static void setupHibernateTimeoutBehavior(NonstopConfiguration nonstopConfig) { nonstopConfig.getTimeoutBehavior().setType( TimeoutBehaviorType.EXCEPTION.getTypeName() ); } }