repo
stringlengths
7
58
path
stringlengths
12
218
func_name
stringlengths
3
140
original_string
stringlengths
73
34.1k
language
stringclasses
1 value
code
stringlengths
73
34.1k
code_tokens
list
docstring
stringlengths
3
16k
docstring_tokens
list
sha
stringlengths
40
40
url
stringlengths
105
339
partition
stringclasses
1 value
cache2k/cache2k
cache2k-spring/src/main/java/org/cache2k/extra/spring/SpringCache2kCacheManager.java
SpringCache2kCacheManager.getCache
@SuppressWarnings("unchecked") @Override public SpringCache2kCache getCache(final String name) { return name2cache.computeIfAbsent(name, n -> { if (!allowUnknownCache && !configuredCacheNames.contains(n)) { throw new IllegalArgumentException("Cache configuration missing for: " + n); } return buildAndWrap(Cache2kBuilder.forUnknownTypes().manager(manager).name(n)); }); }
java
@SuppressWarnings("unchecked") @Override public SpringCache2kCache getCache(final String name) { return name2cache.computeIfAbsent(name, n -> { if (!allowUnknownCache && !configuredCacheNames.contains(n)) { throw new IllegalArgumentException("Cache configuration missing for: " + n); } return buildAndWrap(Cache2kBuilder.forUnknownTypes().manager(manager).name(n)); }); }
[ "@", "SuppressWarnings", "(", "\"unchecked\"", ")", "@", "Override", "public", "SpringCache2kCache", "getCache", "(", "final", "String", "name", ")", "{", "return", "name2cache", ".", "computeIfAbsent", "(", "name", ",", "n", "->", "{", "if", "(", "!", "allo...
Returns an existing cache or retrieves and wraps a cache from cache2k.
[ "Returns", "an", "existing", "cache", "or", "retrieves", "and", "wraps", "a", "cache", "from", "cache2k", "." ]
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-spring/src/main/java/org/cache2k/extra/spring/SpringCache2kCacheManager.java#L98-L107
train
cache2k/cache2k
cache2k-spring/src/main/java/org/cache2k/extra/spring/SpringCache2kCacheManager.java
SpringCache2kCacheManager.getCacheNames
@Override public Collection<String> getCacheNames() { Set<String> cacheNames = new HashSet<>(); for (org.cache2k.Cache<?,?> cache : manager.getActiveCaches()) { cacheNames.add(cache.getName()); } cacheNames.addAll(configuredCacheNames); return Collections.unmodifiableSet(cacheNames); }
java
@Override public Collection<String> getCacheNames() { Set<String> cacheNames = new HashSet<>(); for (org.cache2k.Cache<?,?> cache : manager.getActiveCaches()) { cacheNames.add(cache.getName()); } cacheNames.addAll(configuredCacheNames); return Collections.unmodifiableSet(cacheNames); }
[ "@", "Override", "public", "Collection", "<", "String", ">", "getCacheNames", "(", ")", "{", "Set", "<", "String", ">", "cacheNames", "=", "new", "HashSet", "<>", "(", ")", ";", "for", "(", "org", ".", "cache2k", ".", "Cache", "<", "?", ",", "?", "...
Get a list of known caches. Depending on the configuration, caches may be created dynamically without providing a configuration for a specific cache name. Because of this combine the known names from configuration and activated caches.
[ "Get", "a", "list", "of", "known", "caches", ".", "Depending", "on", "the", "configuration", "caches", "may", "be", "created", "dynamically", "without", "providing", "a", "configuration", "for", "a", "specific", "cache", "name", ".", "Because", "of", "this", ...
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-spring/src/main/java/org/cache2k/extra/spring/SpringCache2kCacheManager.java#L165-L173
train
cache2k/cache2k
cache2k-jcache/src/main/java/org/cache2k/jcache/provider/generic/storeByValueSimulation/CopyCacheProxy.java
CopyCacheProxy.getConfiguration
@SuppressWarnings("unchecked") @Override public <C extends Configuration<K, T>> C getConfiguration(Class<C> clazz) { final C c = cache.getConfiguration(clazz); if (c instanceof CompleteConfiguration) { final CompleteConfiguration<K, T> cc = (CompleteConfiguration<K,T>) c; return (C) new CompleteConfiguration<K, T>() { @Override public Iterable<CacheEntryListenerConfiguration<K, T>> getCacheEntryListenerConfigurations() { return cc.getCacheEntryListenerConfigurations(); } @Override public boolean isReadThrough() { return cc.isReadThrough(); } @Override public boolean isWriteThrough() { return cc.isWriteThrough(); } @Override public boolean isStatisticsEnabled() { return cc.isStatisticsEnabled(); } @Override public boolean isManagementEnabled() { return cc.isManagementEnabled(); } @Override public Factory<CacheLoader<K, T>> getCacheLoaderFactory() { return cc.getCacheLoaderFactory(); } @Override public Factory<CacheWriter<? super K, ? super T>> getCacheWriterFactory() { return cc.getCacheWriterFactory(); } @Override public Factory<ExpiryPolicy> getExpiryPolicyFactory() { return cc.getExpiryPolicyFactory(); } @Override public Class<K> getKeyType() { return cc.getKeyType(); } @Override public Class<T> getValueType() { return cc.getValueType(); } @Override public boolean isStoreByValue() { return true; } }; } else if (c instanceof Configuration) { return (C) new Configuration<K, T>() { @Override public Class<K> getKeyType() { return c.getKeyType(); } @Override public Class<T> getValueType() { return c.getValueType(); } @Override public boolean isStoreByValue() { return true; } }; } return c; }
java
@SuppressWarnings("unchecked") @Override public <C extends Configuration<K, T>> C getConfiguration(Class<C> clazz) { final C c = cache.getConfiguration(clazz); if (c instanceof CompleteConfiguration) { final CompleteConfiguration<K, T> cc = (CompleteConfiguration<K,T>) c; return (C) new CompleteConfiguration<K, T>() { @Override public Iterable<CacheEntryListenerConfiguration<K, T>> getCacheEntryListenerConfigurations() { return cc.getCacheEntryListenerConfigurations(); } @Override public boolean isReadThrough() { return cc.isReadThrough(); } @Override public boolean isWriteThrough() { return cc.isWriteThrough(); } @Override public boolean isStatisticsEnabled() { return cc.isStatisticsEnabled(); } @Override public boolean isManagementEnabled() { return cc.isManagementEnabled(); } @Override public Factory<CacheLoader<K, T>> getCacheLoaderFactory() { return cc.getCacheLoaderFactory(); } @Override public Factory<CacheWriter<? super K, ? super T>> getCacheWriterFactory() { return cc.getCacheWriterFactory(); } @Override public Factory<ExpiryPolicy> getExpiryPolicyFactory() { return cc.getExpiryPolicyFactory(); } @Override public Class<K> getKeyType() { return cc.getKeyType(); } @Override public Class<T> getValueType() { return cc.getValueType(); } @Override public boolean isStoreByValue() { return true; } }; } else if (c instanceof Configuration) { return (C) new Configuration<K, T>() { @Override public Class<K> getKeyType() { return c.getKeyType(); } @Override public Class<T> getValueType() { return c.getValueType(); } @Override public boolean isStoreByValue() { return true; } }; } return c; }
[ "@", "SuppressWarnings", "(", "\"unchecked\"", ")", "@", "Override", "public", "<", "C", "extends", "Configuration", "<", "K", ",", "T", ">", ">", "C", "getConfiguration", "(", "Class", "<", "C", ">", "clazz", ")", "{", "final", "C", "c", "=", "cache",...
Delegates to the wrapped cache. Wrap configuration and return true on store by value
[ "Delegates", "to", "the", "wrapped", "cache", ".", "Wrap", "configuration", "and", "return", "true", "on", "store", "by", "value" ]
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-jcache/src/main/java/org/cache2k/jcache/provider/generic/storeByValueSimulation/CopyCacheProxy.java#L48-L129
train
cache2k/cache2k
cache2k-api/src/main/java/org/cache2k/configuration/Cache2kConfiguration.java
Cache2kConfiguration.of
public static <K,V> Cache2kConfiguration<K, V> of(CacheType<K> keyType, CacheType<V> valueType) { Cache2kConfiguration<K,V> c = new Cache2kConfiguration<K,V>(); c.setKeyType(keyType); c.setValueType(valueType); return c; }
java
public static <K,V> Cache2kConfiguration<K, V> of(CacheType<K> keyType, CacheType<V> valueType) { Cache2kConfiguration<K,V> c = new Cache2kConfiguration<K,V>(); c.setKeyType(keyType); c.setValueType(valueType); return c; }
[ "public", "static", "<", "K", ",", "V", ">", "Cache2kConfiguration", "<", "K", ",", "V", ">", "of", "(", "CacheType", "<", "K", ">", "keyType", ",", "CacheType", "<", "V", ">", "valueType", ")", "{", "Cache2kConfiguration", "<", "K", ",", "V", ">", ...
Construct a config instance setting the type parameters and returning a proper generic type. @see Cache2kBuilder#keyType(CacheType) @see Cache2kBuilder#valueType(CacheType)
[ "Construct", "a", "config", "instance", "setting", "the", "type", "parameters", "and", "returning", "a", "proper", "generic", "type", "." ]
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-api/src/main/java/org/cache2k/configuration/Cache2kConfiguration.java#L159-L164
train
cache2k/cache2k
cache2k-api/src/main/java/org/cache2k/configuration/Cache2kConfiguration.java
Cache2kConfiguration.getListeners
public CustomizationCollection<CacheEntryOperationListener<K,V>> getListeners() { if (listeners == null) { listeners = new DefaultCustomizationCollection<CacheEntryOperationListener<K, V>>(); } return listeners; }
java
public CustomizationCollection<CacheEntryOperationListener<K,V>> getListeners() { if (listeners == null) { listeners = new DefaultCustomizationCollection<CacheEntryOperationListener<K, V>>(); } return listeners; }
[ "public", "CustomizationCollection", "<", "CacheEntryOperationListener", "<", "K", ",", "V", ">", ">", "getListeners", "(", ")", "{", "if", "(", "listeners", "==", "null", ")", "{", "listeners", "=", "new", "DefaultCustomizationCollection", "<", "CacheEntryOperati...
A set of listeners. Listeners added in this collection will be executed in a synchronous mode, meaning, further processing for an entry will stall until a registered listener is executed. The expiry will be always executed asynchronously. <p>A listener can be added by adding it to the collection. Duplicate (in terms of equal objects) listeners will be ignored. @return Mutable collection of listeners
[ "A", "set", "of", "listeners", ".", "Listeners", "added", "in", "this", "collection", "will", "be", "executed", "in", "a", "synchronous", "mode", "meaning", "further", "processing", "for", "an", "entry", "will", "stall", "until", "a", "registered", "listener",...
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-api/src/main/java/org/cache2k/configuration/Cache2kConfiguration.java#L514-L519
train
cache2k/cache2k
cache2k-core/src/main/java/org/cache2k/core/util/TunableFactory.java
TunableFactory.reload
public static synchronized void reload() { map = new HashMap<Class<?>, Object>(); customProperties = loadFile(CUSTOM_TUNING_FILE_NAME); defaultProperties = loadFile(DEFAULT_TUNING_FILE_NAME); }
java
public static synchronized void reload() { map = new HashMap<Class<?>, Object>(); customProperties = loadFile(CUSTOM_TUNING_FILE_NAME); defaultProperties = loadFile(DEFAULT_TUNING_FILE_NAME); }
[ "public", "static", "synchronized", "void", "reload", "(", ")", "{", "map", "=", "new", "HashMap", "<", "Class", "<", "?", ">", ",", "Object", ">", "(", ")", ";", "customProperties", "=", "loadFile", "(", "CUSTOM_TUNING_FILE_NAME", ")", ";", "defaultProper...
Reload the tunable configuration from the system properties and the configuration file.
[ "Reload", "the", "tunable", "configuration", "from", "the", "system", "properties", "and", "the", "configuration", "file", "." ]
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-core/src/main/java/org/cache2k/core/util/TunableFactory.java#L61-L65
train
cache2k/cache2k
cache2k-core/src/main/java/org/cache2k/core/util/TunableFactory.java
TunableFactory.get
@SuppressWarnings("unchecked") public synchronized static <T extends TunableConstants> T get(Properties p, Class<T> c) { T cfg = getDefault(c); if (p != null && p.containsKey(TUNE_MARKER) && p.containsKey(cfg.getClass().getName() + ".tuning")) { cfg = (T) cfg.clone(); apply(p, cfg); } return cfg; }
java
@SuppressWarnings("unchecked") public synchronized static <T extends TunableConstants> T get(Properties p, Class<T> c) { T cfg = getDefault(c); if (p != null && p.containsKey(TUNE_MARKER) && p.containsKey(cfg.getClass().getName() + ".tuning")) { cfg = (T) cfg.clone(); apply(p, cfg); } return cfg; }
[ "@", "SuppressWarnings", "(", "\"unchecked\"", ")", "public", "synchronized", "static", "<", "T", "extends", "TunableConstants", ">", "T", "get", "(", "Properties", "p", ",", "Class", "<", "T", ">", "c", ")", "{", "T", "cfg", "=", "getDefault", "(", "c",...
Provide tuning object with initialized information from the properties file. @param p Properties from the execution context @param c Tunable class @param <T> type of requested tunable class @return Created and initialized object
[ "Provide", "tuning", "object", "with", "initialized", "information", "from", "the", "properties", "file", "." ]
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-core/src/main/java/org/cache2k/core/util/TunableFactory.java#L91-L101
train
cache2k/cache2k
cache2k-api/src/main/java/org/cache2k/configuration/ConfigurationSectionContainer.java
ConfigurationSectionContainer.add
public boolean add(ConfigurationSection section) { if (section instanceof SingletonConfigurationSection) { if (getSection(section.getClass()) != null) { throw new IllegalArgumentException("Section of same type already inserted: " + section.getClass().getName()); } } return sections.add(section); }
java
public boolean add(ConfigurationSection section) { if (section instanceof SingletonConfigurationSection) { if (getSection(section.getClass()) != null) { throw new IllegalArgumentException("Section of same type already inserted: " + section.getClass().getName()); } } return sections.add(section); }
[ "public", "boolean", "add", "(", "ConfigurationSection", "section", ")", "{", "if", "(", "section", "instanceof", "SingletonConfigurationSection", ")", "{", "if", "(", "getSection", "(", "section", ".", "getClass", "(", ")", ")", "!=", "null", ")", "{", "thr...
Add a new configuration section to the container. @throws IllegalArgumentException if same type is already present and a singleton @return always {@code true}
[ "Add", "a", "new", "configuration", "section", "to", "the", "container", "." ]
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-api/src/main/java/org/cache2k/configuration/ConfigurationSectionContainer.java#L47-L54
train
cache2k/cache2k
cache2k-api/src/main/java/org/cache2k/configuration/ConfigurationSectionContainer.java
ConfigurationSectionContainer.getSection
@SuppressWarnings("unchecked") public <T extends ConfigurationSection> T getSection(Class<T> sectionType) { for (ConfigurationSection s : sections) { if (sectionType.equals(s.getClass())) { return (T) s; } } return null; }
java
@SuppressWarnings("unchecked") public <T extends ConfigurationSection> T getSection(Class<T> sectionType) { for (ConfigurationSection s : sections) { if (sectionType.equals(s.getClass())) { return (T) s; } } return null; }
[ "@", "SuppressWarnings", "(", "\"unchecked\"", ")", "public", "<", "T", "extends", "ConfigurationSection", ">", "T", "getSection", "(", "Class", "<", "T", ">", "sectionType", ")", "{", "for", "(", "ConfigurationSection", "s", ":", "sections", ")", "{", "if",...
Retrieve a single section from the container.
[ "Retrieve", "a", "single", "section", "from", "the", "container", "." ]
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-api/src/main/java/org/cache2k/configuration/ConfigurationSectionContainer.java#L59-L67
train
cache2k/cache2k
cache2k-jcache/src/main/java/org/cache2k/jcache/provider/event/AsyncDispatcher.java
AsyncDispatcher.deliverAsyncEvent
void deliverAsyncEvent(final EntryEvent<K,V> _event) { if (asyncListenerByType.get(_event.getEventType()).isEmpty()) { return; } List<Listener<K,V>> _listeners = new ArrayList<Listener<K, V>>(asyncListenerByType.get(_event.getEventType())); if (_listeners.isEmpty()) { return; } K key = _event.getKey(); synchronized (getLockObject(key)) { Queue<EntryEvent<K,V>> q = keyQueue.get(key); if (q != null) { q.add(_event); return; } q = new LinkedList<EntryEvent<K, V>>(); keyQueue.put(key, q); } runAllListenersInParallel(_event, _listeners); }
java
void deliverAsyncEvent(final EntryEvent<K,V> _event) { if (asyncListenerByType.get(_event.getEventType()).isEmpty()) { return; } List<Listener<K,V>> _listeners = new ArrayList<Listener<K, V>>(asyncListenerByType.get(_event.getEventType())); if (_listeners.isEmpty()) { return; } K key = _event.getKey(); synchronized (getLockObject(key)) { Queue<EntryEvent<K,V>> q = keyQueue.get(key); if (q != null) { q.add(_event); return; } q = new LinkedList<EntryEvent<K, V>>(); keyQueue.put(key, q); } runAllListenersInParallel(_event, _listeners); }
[ "void", "deliverAsyncEvent", "(", "final", "EntryEvent", "<", "K", ",", "V", ">", "_event", ")", "{", "if", "(", "asyncListenerByType", ".", "get", "(", "_event", ".", "getEventType", "(", ")", ")", ".", "isEmpty", "(", ")", ")", "{", "return", ";", ...
If listeners are registered for this event type, run the listeners or queue the event, if already something is happening for this key.
[ "If", "listeners", "are", "registered", "for", "this", "event", "type", "run", "the", "listeners", "or", "queue", "the", "event", "if", "already", "something", "is", "happening", "for", "this", "key", "." ]
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-jcache/src/main/java/org/cache2k/jcache/provider/event/AsyncDispatcher.java#L118-L138
train
cache2k/cache2k
cache2k-jcache/src/main/java/org/cache2k/jcache/provider/event/AsyncDispatcher.java
AsyncDispatcher.runAllListenersInParallel
void runAllListenersInParallel(final EntryEvent<K, V> _event, List<Listener<K, V>> _listeners) { final AtomicInteger _countDown = new AtomicInteger(_listeners.size()); for (final Listener<K,V> l : _listeners) { Runnable r = new Runnable() { @Override public void run() { try { l.fire(_event); } catch (Throwable t) { t.printStackTrace(); } int _done = _countDown.decrementAndGet(); if (_done == 0) { runMoreOnKeyQueueOrStop(_event.getKey()); } } }; executor.execute(r); } }
java
void runAllListenersInParallel(final EntryEvent<K, V> _event, List<Listener<K, V>> _listeners) { final AtomicInteger _countDown = new AtomicInteger(_listeners.size()); for (final Listener<K,V> l : _listeners) { Runnable r = new Runnable() { @Override public void run() { try { l.fire(_event); } catch (Throwable t) { t.printStackTrace(); } int _done = _countDown.decrementAndGet(); if (_done == 0) { runMoreOnKeyQueueOrStop(_event.getKey()); } } }; executor.execute(r); } }
[ "void", "runAllListenersInParallel", "(", "final", "EntryEvent", "<", "K", ",", "V", ">", "_event", ",", "List", "<", "Listener", "<", "K", ",", "V", ">", ">", "_listeners", ")", "{", "final", "AtomicInteger", "_countDown", "=", "new", "AtomicInteger", "("...
Pass on runnables to the executor for all listeners. After each event is handled within the listener we check whether the event is processed by all listeners, by decrementing a countdown. In case the event is processed completely, we check whether more is queued up for this key meanwhile.
[ "Pass", "on", "runnables", "to", "the", "executor", "for", "all", "listeners", ".", "After", "each", "event", "is", "handled", "within", "the", "listener", "we", "check", "whether", "the", "event", "is", "processed", "by", "all", "listeners", "by", "decremen...
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-jcache/src/main/java/org/cache2k/jcache/provider/event/AsyncDispatcher.java#L146-L165
train
cache2k/cache2k
cache2k-jcache/src/main/java/org/cache2k/jcache/provider/event/AsyncDispatcher.java
AsyncDispatcher.runMoreOnKeyQueueOrStop
void runMoreOnKeyQueueOrStop(K key) { EntryEvent<K,V> _event; synchronized (getLockObject(key)) { Queue<EntryEvent<K,V>> q = keyQueue.get(key); if (q.isEmpty()) { keyQueue.remove(key); return; } _event = q.remove(); } List<Listener<K,V>> _listeners = new ArrayList<Listener<K, V>>(asyncListenerByType.get(_event.getEventType())); if (_listeners.isEmpty()) { runMoreOnKeyQueueOrStop(key); return; } runAllListenersInParallel(_event, _listeners); }
java
void runMoreOnKeyQueueOrStop(K key) { EntryEvent<K,V> _event; synchronized (getLockObject(key)) { Queue<EntryEvent<K,V>> q = keyQueue.get(key); if (q.isEmpty()) { keyQueue.remove(key); return; } _event = q.remove(); } List<Listener<K,V>> _listeners = new ArrayList<Listener<K, V>>(asyncListenerByType.get(_event.getEventType())); if (_listeners.isEmpty()) { runMoreOnKeyQueueOrStop(key); return; } runAllListenersInParallel(_event, _listeners); }
[ "void", "runMoreOnKeyQueueOrStop", "(", "K", "key", ")", "{", "EntryEvent", "<", "K", ",", "V", ">", "_event", ";", "synchronized", "(", "getLockObject", "(", "key", ")", ")", "{", "Queue", "<", "EntryEvent", "<", "K", ",", "V", ">", ">", "q", "=", ...
Check the event queue for this key and process the next event. If no more events are present remove the queue.
[ "Check", "the", "event", "queue", "for", "this", "key", "and", "process", "the", "next", "event", ".", "If", "no", "more", "events", "are", "present", "remove", "the", "queue", "." ]
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-jcache/src/main/java/org/cache2k/jcache/provider/event/AsyncDispatcher.java#L171-L188
train
cache2k/cache2k
cache2k-core/src/main/java/org/cache2k/core/AbstractEviction.java
AbstractEviction.calculateWeight
private long calculateWeight(final Entry e, final Object v) { long _weight; if (v instanceof ExceptionWrapper) { _weight = 1; } else { _weight = weigher.weigh(e.getKey(), v); } if (_weight < 0) { throw new IllegalArgumentException("weight must be positive."); } return _weight; }
java
private long calculateWeight(final Entry e, final Object v) { long _weight; if (v instanceof ExceptionWrapper) { _weight = 1; } else { _weight = weigher.weigh(e.getKey(), v); } if (_weight < 0) { throw new IllegalArgumentException("weight must be positive."); } return _weight; }
[ "private", "long", "calculateWeight", "(", "final", "Entry", "e", ",", "final", "Object", "v", ")", "{", "long", "_weight", ";", "if", "(", "v", "instanceof", "ExceptionWrapper", ")", "{", "_weight", "=", "1", ";", "}", "else", "{", "_weight", "=", "we...
Exceptions have the minimum weight.
[ "Exceptions", "have", "the", "minimum", "weight", "." ]
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-core/src/main/java/org/cache2k/core/AbstractEviction.java#L103-L114
train
cache2k/cache2k
cache2k-core/src/main/java/org/cache2k/core/AbstractEviction.java
AbstractEviction.updateWeight
@Override public void updateWeight(final Entry e) { if (!isWeigherPresent()) { return; } Entry[] _evictionChunk = null; synchronized (lock) { updateWeightInLock(e); _evictionChunk = fillEvictionChunk(); } evictChunk(_evictionChunk); int _processCount = 1; while (isEvictionNeeded() && _processCount > 0) { synchronized (lock) { _evictionChunk = fillEvictionChunk(); } _processCount = evictChunk(_evictionChunk); } }
java
@Override public void updateWeight(final Entry e) { if (!isWeigherPresent()) { return; } Entry[] _evictionChunk = null; synchronized (lock) { updateWeightInLock(e); _evictionChunk = fillEvictionChunk(); } evictChunk(_evictionChunk); int _processCount = 1; while (isEvictionNeeded() && _processCount > 0) { synchronized (lock) { _evictionChunk = fillEvictionChunk(); } _processCount = evictChunk(_evictionChunk); } }
[ "@", "Override", "public", "void", "updateWeight", "(", "final", "Entry", "e", ")", "{", "if", "(", "!", "isWeigherPresent", "(", ")", ")", "{", "return", ";", "}", "Entry", "[", "]", "_evictionChunk", "=", "null", ";", "synchronized", "(", "lock", ")"...
Update the weight in the entry and update the weight calculation in this eviction segment. Since the weight limit might be reached, try to evict until within limits again.
[ "Update", "the", "weight", "in", "the", "entry", "and", "update", "the", "weight", "calculation", "in", "this", "eviction", "segment", ".", "Since", "the", "weight", "limit", "might", "be", "reached", "try", "to", "evict", "until", "within", "limits", "again...
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-core/src/main/java/org/cache2k/core/AbstractEviction.java#L151-L169
train
cache2k/cache2k
cache2k-core/src/main/java/org/cache2k/core/AbstractEviction.java
AbstractEviction.reuseChunkArray
Entry[] reuseChunkArray() { Entry[] ea = evictChunkReuse; if (ea != null) { evictChunkReuse = null; } else { ea = new Entry[chunkSize]; } return ea; }
java
Entry[] reuseChunkArray() { Entry[] ea = evictChunkReuse; if (ea != null) { evictChunkReuse = null; } else { ea = new Entry[chunkSize]; } return ea; }
[ "Entry", "[", "]", "reuseChunkArray", "(", ")", "{", "Entry", "[", "]", "ea", "=", "evictChunkReuse", ";", "if", "(", "ea", "!=", "null", ")", "{", "evictChunkReuse", "=", "null", ";", "}", "else", "{", "ea", "=", "new", "Entry", "[", "chunkSize", ...
Safe GC overhead by reusing the chunk array.
[ "Safe", "GC", "overhead", "by", "reusing", "the", "chunk", "array", "." ]
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-core/src/main/java/org/cache2k/core/AbstractEviction.java#L172-L180
train
cache2k/cache2k
cache2k-core/src/main/java/org/cache2k/core/InternalCache2kBuilder.java
InternalCache2kBuilder.configureViaSettersDirect
@SuppressWarnings("unchecked") private void configureViaSettersDirect(HeapCache<K,V> c) { if (config.getLoader() != null) { Object obj = c.createCustomization(config.getLoader()); if (obj instanceof CacheLoader) { final CacheLoader<K,V> _loader = (CacheLoader) obj; c.setAdvancedLoader(new AdvancedCacheLoader<K, V>() { @Override public V load(final K key, final long currentTime, final CacheEntry<K, V> currentEntry) throws Exception { return _loader.load(key); } }); } else { final FunctionalCacheLoader<K,V> _loader = (FunctionalCacheLoader) obj; c.setAdvancedLoader(new AdvancedCacheLoader<K, V>() { @Override public V load(final K key, final long currentTime, final CacheEntry<K, V> currentEntry) throws Exception { return _loader.load(key); } }); } } if (config.getAdvancedLoader() != null) { final AdvancedCacheLoader<K,V> _loader = c.createCustomization(config.getAdvancedLoader()); AdvancedCacheLoader<K,V> _wrappedLoader = new WrappedAdvancedCacheLoader<K, V>(c, _loader); c.setAdvancedLoader(_wrappedLoader); } if (config.getExceptionPropagator() != null) { c.setExceptionPropagator(c.createCustomization(config.getExceptionPropagator())); } c.setCacheConfig(config); }
java
@SuppressWarnings("unchecked") private void configureViaSettersDirect(HeapCache<K,V> c) { if (config.getLoader() != null) { Object obj = c.createCustomization(config.getLoader()); if (obj instanceof CacheLoader) { final CacheLoader<K,V> _loader = (CacheLoader) obj; c.setAdvancedLoader(new AdvancedCacheLoader<K, V>() { @Override public V load(final K key, final long currentTime, final CacheEntry<K, V> currentEntry) throws Exception { return _loader.load(key); } }); } else { final FunctionalCacheLoader<K,V> _loader = (FunctionalCacheLoader) obj; c.setAdvancedLoader(new AdvancedCacheLoader<K, V>() { @Override public V load(final K key, final long currentTime, final CacheEntry<K, V> currentEntry) throws Exception { return _loader.load(key); } }); } } if (config.getAdvancedLoader() != null) { final AdvancedCacheLoader<K,V> _loader = c.createCustomization(config.getAdvancedLoader()); AdvancedCacheLoader<K,V> _wrappedLoader = new WrappedAdvancedCacheLoader<K, V>(c, _loader); c.setAdvancedLoader(_wrappedLoader); } if (config.getExceptionPropagator() != null) { c.setExceptionPropagator(c.createCustomization(config.getExceptionPropagator())); } c.setCacheConfig(config); }
[ "@", "SuppressWarnings", "(", "\"unchecked\"", ")", "private", "void", "configureViaSettersDirect", "(", "HeapCache", "<", "K", ",", "V", ">", "c", ")", "{", "if", "(", "config", ".", "getLoader", "(", ")", "!=", "null", ")", "{", "Object", "obj", "=", ...
The generic wiring code is not working on android. Explicitly call the wiring methods.
[ "The", "generic", "wiring", "code", "is", "not", "working", "on", "android", ".", "Explicitly", "call", "the", "wiring", "methods", "." ]
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-core/src/main/java/org/cache2k/core/InternalCache2kBuilder.java#L111-L142
train
cache2k/cache2k
cache2k-core/src/main/java/org/cache2k/core/InternalCache2kBuilder.java
InternalCache2kBuilder.constructEviction
private Eviction constructEviction(HeapCache hc, HeapCacheListener l, Cache2kConfiguration config) { final boolean _strictEviction = config.isStrictEviction(); final int _availableProcessors = Runtime.getRuntime().availableProcessors(); final boolean _boostConcurrency = config.isBoostConcurrency(); final long _maximumWeight = config.getMaximumWeight(); long _entryCapacity = config.getEntryCapacity(); if (_entryCapacity < 0 && _maximumWeight < 0) { _entryCapacity = 2000; } final int _segmentCountOverride = HeapCache.TUNABLE.segmentCountOverride; int _segmentCount = determineSegmentCount(_strictEviction, _availableProcessors, _boostConcurrency, _entryCapacity, _segmentCountOverride); Eviction[] _segments = new Eviction[_segmentCount]; long _maxSize = determineMaxSize(_entryCapacity, _segmentCount); long _maxWeight = determineMaxWeight(_maximumWeight, _segmentCount); final Weigher _weigher = (Weigher) hc.createCustomization(config.getWeigher()); for (int i = 0; i < _segments.length; i++) { Eviction ev = new ClockProPlusEviction(hc, l, _maxSize, _weigher, _maxWeight); _segments[i] = ev; } if (_segmentCount == 1) { return _segments[0]; } return new SegmentedEviction(_segments); }
java
private Eviction constructEviction(HeapCache hc, HeapCacheListener l, Cache2kConfiguration config) { final boolean _strictEviction = config.isStrictEviction(); final int _availableProcessors = Runtime.getRuntime().availableProcessors(); final boolean _boostConcurrency = config.isBoostConcurrency(); final long _maximumWeight = config.getMaximumWeight(); long _entryCapacity = config.getEntryCapacity(); if (_entryCapacity < 0 && _maximumWeight < 0) { _entryCapacity = 2000; } final int _segmentCountOverride = HeapCache.TUNABLE.segmentCountOverride; int _segmentCount = determineSegmentCount(_strictEviction, _availableProcessors, _boostConcurrency, _entryCapacity, _segmentCountOverride); Eviction[] _segments = new Eviction[_segmentCount]; long _maxSize = determineMaxSize(_entryCapacity, _segmentCount); long _maxWeight = determineMaxWeight(_maximumWeight, _segmentCount); final Weigher _weigher = (Weigher) hc.createCustomization(config.getWeigher()); for (int i = 0; i < _segments.length; i++) { Eviction ev = new ClockProPlusEviction(hc, l, _maxSize, _weigher, _maxWeight); _segments[i] = ev; } if (_segmentCount == 1) { return _segments[0]; } return new SegmentedEviction(_segments); }
[ "private", "Eviction", "constructEviction", "(", "HeapCache", "hc", ",", "HeapCacheListener", "l", ",", "Cache2kConfiguration", "config", ")", "{", "final", "boolean", "_strictEviction", "=", "config", ".", "isStrictEviction", "(", ")", ";", "final", "int", "_avai...
Construct segmented or queued eviction. For the moment hard coded. If capacity is at least 1000 we use 2 segments if 2 or more CPUs are available. Segmenting the eviction only improves for lots of concurrent inserts or evictions, there is no effect on read performance.
[ "Construct", "segmented", "or", "queued", "eviction", ".", "For", "the", "moment", "hard", "coded", ".", "If", "capacity", "is", "at", "least", "1000", "we", "use", "2", "segments", "if", "2", "or", "more", "CPUs", "are", "available", ".", "Segmenting", ...
3c9ccff12608c598c387ec50957089784cc4b618
https://github.com/cache2k/cache2k/blob/3c9ccff12608c598c387ec50957089784cc4b618/cache2k-core/src/main/java/org/cache2k/core/InternalCache2kBuilder.java#L366-L389
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setTitle
public void setTitle(final String TITLE) { if (null == title) { _title = TITLE; fireUpdateEvent(REDRAW_EVENT); } else { title.set(TITLE); } }
java
public void setTitle(final String TITLE) { if (null == title) { _title = TITLE; fireUpdateEvent(REDRAW_EVENT); } else { title.set(TITLE); } }
[ "public", "void", "setTitle", "(", "final", "String", "TITLE", ")", "{", "if", "(", "null", "==", "title", ")", "{", "_title", "=", "TITLE", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "title", ".", "set", "(", "TITLE", "...
Defines the title of the clock. The title could be used to show for example the current city or timezone @param TITLE
[ "Defines", "the", "title", "of", "the", "clock", ".", "The", "title", "could", "be", "used", "to", "show", "for", "example", "the", "current", "city", "or", "timezone" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L418-L425
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setText
public void setText(final String TEXT) { if (null == text) { _text = TEXT; fireUpdateEvent(REDRAW_EVENT); } else { text.set(TEXT); } }
java
public void setText(final String TEXT) { if (null == text) { _text = TEXT; fireUpdateEvent(REDRAW_EVENT); } else { text.set(TEXT); } }
[ "public", "void", "setText", "(", "final", "String", "TEXT", ")", "{", "if", "(", "null", "==", "text", ")", "{", "_text", "=", "TEXT", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "text", ".", "set", "(", "TEXT", ")", "...
Define the text for the clock. This text could be used for additional information. @param TEXT
[ "Define", "the", "text", "for", "the", "clock", ".", "This", "text", "could", "be", "used", "for", "additional", "information", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L449-L456
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setSectionsVisible
public void setSectionsVisible(final boolean VISIBLE) { if (null == sectionsVisible) { _sectionsVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { sectionsVisible.set(VISIBLE); } }
java
public void setSectionsVisible(final boolean VISIBLE) { if (null == sectionsVisible) { _sectionsVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { sectionsVisible.set(VISIBLE); } }
[ "public", "void", "setSectionsVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "sectionsVisible", ")", "{", "_sectionsVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "sectionsVi...
Defines if the sections should be drawn in the clock. @param VISIBLE
[ "Defines", "if", "the", "sections", "should", "be", "drawn", "in", "the", "clock", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L596-L603
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setHighlightSections
public void setHighlightSections(final boolean HIGHLIGHT) { if (null == highlightSections) { _highlightSections = HIGHLIGHT; fireUpdateEvent(REDRAW_EVENT); } else { highlightSections.set(HIGHLIGHT); } }
java
public void setHighlightSections(final boolean HIGHLIGHT) { if (null == highlightSections) { _highlightSections = HIGHLIGHT; fireUpdateEvent(REDRAW_EVENT); } else { highlightSections.set(HIGHLIGHT); } }
[ "public", "void", "setHighlightSections", "(", "final", "boolean", "HIGHLIGHT", ")", "{", "if", "(", "null", "==", "highlightSections", ")", "{", "_highlightSections", "=", "HIGHLIGHT", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "...
Defines if sections should be highlighted in case they contain the current time. @param HIGHLIGHT
[ "Defines", "if", "sections", "should", "be", "highlighted", "in", "case", "they", "contain", "the", "current", "time", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L626-L633
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setAreas
public void setAreas(final List<TimeSection> AREAS) { areas.setAll(AREAS); Collections.sort(areas, new TimeSectionComparator()); fireUpdateEvent(SECTION_EVENT); }
java
public void setAreas(final List<TimeSection> AREAS) { areas.setAll(AREAS); Collections.sort(areas, new TimeSectionComparator()); fireUpdateEvent(SECTION_EVENT); }
[ "public", "void", "setAreas", "(", "final", "List", "<", "TimeSection", ">", "AREAS", ")", "{", "areas", ".", "setAll", "(", "AREAS", ")", ";", "Collections", ".", "sort", "(", "areas", ",", "new", "TimeSectionComparator", "(", ")", ")", ";", "fireUpdate...
Sets the areas to the given list of TimeSection objects. The sections will be used to colorize areas with a special meaning. Areas in the Medusa library usually are more eye-catching than Sections. @param AREAS
[ "Sets", "the", "areas", "to", "the", "given", "list", "of", "TimeSection", "objects", ".", "The", "sections", "will", "be", "used", "to", "colorize", "areas", "with", "a", "special", "meaning", ".", "Areas", "in", "the", "Medusa", "library", "usually", "ar...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L660-L664
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.addArea
public void addArea(final TimeSection AREA) { if (null == AREA) return; areas.add(AREA); Collections.sort(areas, new TimeSectionComparator()); fireUpdateEvent(SECTION_EVENT); }
java
public void addArea(final TimeSection AREA) { if (null == AREA) return; areas.add(AREA); Collections.sort(areas, new TimeSectionComparator()); fireUpdateEvent(SECTION_EVENT); }
[ "public", "void", "addArea", "(", "final", "TimeSection", "AREA", ")", "{", "if", "(", "null", "==", "AREA", ")", "return", ";", "areas", ".", "add", "(", "AREA", ")", ";", "Collections", ".", "sort", "(", "areas", ",", "new", "TimeSectionComparator", ...
Adds the given TimeSection to the list of areas. Areas in the Medusa library usually are more eye-catching than Sections. @param AREA
[ "Adds", "the", "given", "TimeSection", "to", "the", "list", "of", "areas", ".", "Areas", "in", "the", "Medusa", "library", "usually", "are", "more", "eye", "-", "catching", "than", "Sections", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L679-L684
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.removeArea
public void removeArea(final TimeSection AREA) { if (null == AREA) return; areas.remove(AREA); Collections.sort(areas, new TimeSectionComparator()); fireUpdateEvent(SECTION_EVENT); }
java
public void removeArea(final TimeSection AREA) { if (null == AREA) return; areas.remove(AREA); Collections.sort(areas, new TimeSectionComparator()); fireUpdateEvent(SECTION_EVENT); }
[ "public", "void", "removeArea", "(", "final", "TimeSection", "AREA", ")", "{", "if", "(", "null", "==", "AREA", ")", "return", ";", "areas", ".", "remove", "(", "AREA", ")", ";", "Collections", ".", "sort", "(", "areas", ",", "new", "TimeSectionComparato...
Removes the given TimeSection from the list of areas. Areas in the Medusa library usually are more eye-catching than Sections. @param AREA
[ "Removes", "the", "given", "TimeSection", "from", "the", "list", "of", "areas", ".", "Areas", "in", "the", "Medusa", "library", "usually", "are", "more", "eye", "-", "catching", "than", "Sections", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L691-L696
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setAreasVisible
public void setAreasVisible(final boolean VISIBLE) { if (null == areasVisible) { _areasVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { areasVisible.set(VISIBLE); } }
java
public void setAreasVisible(final boolean VISIBLE) { if (null == areasVisible) { _areasVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { areasVisible.set(VISIBLE); } }
[ "public", "void", "setAreasVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "areasVisible", ")", "{", "_areasVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "areasVisible", "....
Defines if the areas should be drawn in the clock. @param VISIBLE
[ "Defines", "if", "the", "areas", "should", "be", "drawn", "in", "the", "clock", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L714-L721
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setHighlightAreas
public void setHighlightAreas(final boolean HIGHLIGHT) { if (null == highlightAreas) { _highlightAreas = HIGHLIGHT; fireUpdateEvent(REDRAW_EVENT); } else { highlightAreas.set(HIGHLIGHT); } }
java
public void setHighlightAreas(final boolean HIGHLIGHT) { if (null == highlightAreas) { _highlightAreas = HIGHLIGHT; fireUpdateEvent(REDRAW_EVENT); } else { highlightAreas.set(HIGHLIGHT); } }
[ "public", "void", "setHighlightAreas", "(", "final", "boolean", "HIGHLIGHT", ")", "{", "if", "(", "null", "==", "highlightAreas", ")", "{", "_highlightAreas", "=", "HIGHLIGHT", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "highlight...
Defines if areas should be highlighted in case they contain the current time. @param HIGHLIGHT
[ "Defines", "if", "areas", "should", "be", "highlighted", "in", "case", "they", "contain", "the", "current", "time", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L744-L751
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setTitleVisible
public void setTitleVisible(final boolean VISIBLE) { if (null == titleVisible) { _titleVisible = VISIBLE; fireUpdateEvent(VISIBILITY_EVENT); } else { titleVisible.set(VISIBLE); } }
java
public void setTitleVisible(final boolean VISIBLE) { if (null == titleVisible) { _titleVisible = VISIBLE; fireUpdateEvent(VISIBILITY_EVENT); } else { titleVisible.set(VISIBLE); } }
[ "public", "void", "setTitleVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "titleVisible", ")", "{", "_titleVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "VISIBILITY_EVENT", ")", ";", "}", "else", "{", "titleVisible", ...
Defines if the title of the clock will be drawn. @param VISIBLE
[ "Defines", "if", "the", "title", "of", "the", "clock", "will", "be", "drawn", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L903-L910
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setBackgroundPaint
public void setBackgroundPaint(final Paint PAINT) { if (null == backgroundPaint) { _backgroundPaint = PAINT; fireUpdateEvent(REDRAW_EVENT); } else { backgroundPaint.set(PAINT); } }
java
public void setBackgroundPaint(final Paint PAINT) { if (null == backgroundPaint) { _backgroundPaint = PAINT; fireUpdateEvent(REDRAW_EVENT); } else { backgroundPaint.set(PAINT); } }
[ "public", "void", "setBackgroundPaint", "(", "final", "Paint", "PAINT", ")", "{", "if", "(", "null", "==", "backgroundPaint", ")", "{", "_backgroundPaint", "=", "PAINT", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "backgroundPaint"...
Defines the Paint object that will be used to fill the clock background. This is usally a Color object. @param PAINT
[ "Defines", "the", "Paint", "object", "that", "will", "be", "used", "to", "fill", "the", "clock", "background", ".", "This", "is", "usally", "a", "Color", "object", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1092-L1099
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setBorderPaint
public void setBorderPaint(final Paint PAINT) { if (null == borderPaint) { _borderPaint = PAINT; fireUpdateEvent(REDRAW_EVENT); } else { borderPaint.set(PAINT); } }
java
public void setBorderPaint(final Paint PAINT) { if (null == borderPaint) { _borderPaint = PAINT; fireUpdateEvent(REDRAW_EVENT); } else { borderPaint.set(PAINT); } }
[ "public", "void", "setBorderPaint", "(", "final", "Paint", "PAINT", ")", "{", "if", "(", "null", "==", "borderPaint", ")", "{", "_borderPaint", "=", "PAINT", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "borderPaint", ".", "set"...
Defines the Paint object that will be used to draw the border of the clock. Usually this is a Color object. @param PAINT
[ "Defines", "the", "Paint", "object", "that", "will", "be", "used", "to", "draw", "the", "border", "of", "the", "clock", ".", "Usually", "this", "is", "a", "Color", "object", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1123-L1130
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setBorderWidth
public void setBorderWidth(final double WIDTH) { if (null == borderWidth) { _borderWidth = Helper.clamp(0.0, 50.0, WIDTH); fireUpdateEvent(REDRAW_EVENT); } else { borderWidth.set(WIDTH); } }
java
public void setBorderWidth(final double WIDTH) { if (null == borderWidth) { _borderWidth = Helper.clamp(0.0, 50.0, WIDTH); fireUpdateEvent(REDRAW_EVENT); } else { borderWidth.set(WIDTH); } }
[ "public", "void", "setBorderWidth", "(", "final", "double", "WIDTH", ")", "{", "if", "(", "null", "==", "borderWidth", ")", "{", "_borderWidth", "=", "Helper", ".", "clamp", "(", "0.0", ",", "50.0", ",", "WIDTH", ")", ";", "fireUpdateEvent", "(", "REDRAW...
Defines the width in pixels that will be used to draw the border of the clock. The value will be clamped between 0 and 50 pixels. @param WIDTH
[ "Defines", "the", "width", "in", "pixels", "that", "will", "be", "used", "to", "draw", "the", "border", "of", "the", "clock", ".", "The", "value", "will", "be", "clamped", "between", "0", "and", "50", "pixels", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1154-L1161
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setForegroundPaint
public void setForegroundPaint(final Paint PAINT) { if (null == foregroundPaint) { _foregroundPaint = PAINT; fireUpdateEvent(REDRAW_EVENT); } else { foregroundPaint.set(PAINT); } }
java
public void setForegroundPaint(final Paint PAINT) { if (null == foregroundPaint) { _foregroundPaint = PAINT; fireUpdateEvent(REDRAW_EVENT); } else { foregroundPaint.set(PAINT); } }
[ "public", "void", "setForegroundPaint", "(", "final", "Paint", "PAINT", ")", "{", "if", "(", "null", "==", "foregroundPaint", ")", "{", "_foregroundPaint", "=", "PAINT", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "foregroundPaint"...
Defines the Paint object that will be used to fill the foreground of the clock. This could be used to visualize glass effects etc. and is only rarely used. @param PAINT
[ "Defines", "the", "Paint", "object", "that", "will", "be", "used", "to", "fill", "the", "foreground", "of", "the", "clock", ".", "This", "could", "be", "used", "to", "visualize", "glass", "effects", "etc", ".", "and", "is", "only", "rarely", "used", "." ...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1188-L1195
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setTitleColor
public void setTitleColor(final Color COLOR) { if (null == titleColor) { _titleColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { titleColor.set(COLOR); } }
java
public void setTitleColor(final Color COLOR) { if (null == titleColor) { _titleColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { titleColor.set(COLOR); } }
[ "public", "void", "setTitleColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "titleColor", ")", "{", "_titleColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "titleColor", ".", "set", ...
Defines the color that will be used to colorize the title of the clock @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "title", "of", "the", "clock" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1217-L1224
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setTextColor
public void setTextColor(final Color COLOR) { if (null == textColor) { _textColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { textColor.set(COLOR); } }
java
public void setTextColor(final Color COLOR) { if (null == textColor) { _textColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { textColor.set(COLOR); } }
[ "public", "void", "setTextColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "textColor", ")", "{", "_textColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "textColor", ".", "set", "(",...
Defines the color that will be used to colorize the text of the clock. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "text", "of", "the", "clock", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1246-L1253
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setDateColor
public void setDateColor(final Color COLOR) { if (null == dateColor) { _dateColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { dateColor.set(COLOR); } }
java
public void setDateColor(final Color COLOR) { if (null == dateColor) { _dateColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { dateColor.set(COLOR); } }
[ "public", "void", "setDateColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "dateColor", ")", "{", "_dateColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "dateColor", ".", "set", "(",...
Defines the color that will be used to colorize the date of the clock @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "date", "of", "the", "clock" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1275-L1282
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setMinuteTickMarkColor
public void setMinuteTickMarkColor(final Color COLOR) { if (null == minuteTickMarkColor) { _minuteTickMarkColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { minuteTickMarkColor.set(COLOR); } }
java
public void setMinuteTickMarkColor(final Color COLOR) { if (null == minuteTickMarkColor) { _minuteTickMarkColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { minuteTickMarkColor.set(COLOR); } }
[ "public", "void", "setMinuteTickMarkColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "minuteTickMarkColor", ")", "{", "_minuteTickMarkColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "minu...
Defines the color that will be used to colorize the minute tickmarks of the clock. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "minute", "tickmarks", "of", "the", "clock", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1333-L1340
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setTickLabelColor
public void setTickLabelColor(final Color COLOR) { if (null == tickLabelColor) { _tickLabelColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { tickLabelColor.set(COLOR); } }
java
public void setTickLabelColor(final Color COLOR) { if (null == tickLabelColor) { _tickLabelColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { tickLabelColor.set(COLOR); } }
[ "public", "void", "setTickLabelColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "tickLabelColor", ")", "{", "_tickLabelColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "tickLabelColor", ...
Defines the color that will be used to colorize the ticklabels of the clock. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "ticklabels", "of", "the", "clock", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1362-L1369
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setTickLabelsVisible
public void setTickLabelsVisible(final boolean VISIBLE) { if (null == tickLabelsVisible) { _tickLabelsVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { tickLabelsVisible.set(VISIBLE); } }
java
public void setTickLabelsVisible(final boolean VISIBLE) { if (null == tickLabelsVisible) { _tickLabelsVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { tickLabelsVisible.set(VISIBLE); } }
[ "public", "void", "setTickLabelsVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "tickLabelsVisible", ")", "{", "_tickLabelsVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "tick...
Defines if the ticklabels will be drawn. @param VISIBLE
[ "Defines", "if", "the", "ticklabels", "will", "be", "drawn", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1476-L1483
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setSecondColor
public void setSecondColor(final Color COLOR) { if (null == secondColor) { _secondColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { secondColor.set(COLOR); } }
java
public void setSecondColor(final Color COLOR) { if (null == secondColor) { _secondColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { secondColor.set(COLOR); } }
[ "public", "void", "setSecondColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "secondColor", ")", "{", "_secondColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "secondColor", ".", "set"...
Defines the color that will be used to colorize the second hand of the clock @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "second", "hand", "of", "the", "clock" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1562-L1569
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setLcdCrystalEnabled
public void setLcdCrystalEnabled(final boolean ENABLED) { if (null == lcdCrystalEnabled) { _lcdCrystalEnabled = ENABLED; fireUpdateEvent(VISIBILITY_EVENT); } else { lcdCrystalEnabled.set(ENABLED); } }
java
public void setLcdCrystalEnabled(final boolean ENABLED) { if (null == lcdCrystalEnabled) { _lcdCrystalEnabled = ENABLED; fireUpdateEvent(VISIBILITY_EVENT); } else { lcdCrystalEnabled.set(ENABLED); } }
[ "public", "void", "setLcdCrystalEnabled", "(", "final", "boolean", "ENABLED", ")", "{", "if", "(", "null", "==", "lcdCrystalEnabled", ")", "{", "_lcdCrystalEnabled", "=", "ENABLED", ";", "fireUpdateEvent", "(", "VISIBILITY_EVENT", ")", ";", "}", "else", "{", "...
Defines if the crystal effect of the LCD display will be drawn. This feature could decrease the performance if you run it on embedded devices because it will calculate a bitmap image where each pixel will be calculated. @param ENABLED
[ "Defines", "if", "the", "crystal", "effect", "of", "the", "LCD", "display", "will", "be", "drawn", ".", "This", "feature", "could", "decrease", "the", "performance", "if", "you", "run", "it", "on", "embedded", "devices", "because", "it", "will", "calculate",...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1745-L1752
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setShadowsEnabled
public void setShadowsEnabled(final boolean ENABLED) { if (null == shadowsEnabled) { _shadowsEnabled = ENABLED; fireUpdateEvent(REDRAW_EVENT); } else { shadowsEnabled.set(ENABLED); } }
java
public void setShadowsEnabled(final boolean ENABLED) { if (null == shadowsEnabled) { _shadowsEnabled = ENABLED; fireUpdateEvent(REDRAW_EVENT); } else { shadowsEnabled.set(ENABLED); } }
[ "public", "void", "setShadowsEnabled", "(", "final", "boolean", "ENABLED", ")", "{", "if", "(", "null", "==", "shadowsEnabled", ")", "{", "_shadowsEnabled", "=", "ENABLED", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "shadowsEnable...
Defines if effects like shadows will be drawn. @param ENABLED
[ "Defines", "if", "effects", "like", "shadows", "will", "be", "drawn", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1773-L1780
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setLocale
public void setLocale(final Locale LOCALE) { if (null == locale) { _locale = LOCALE; fireUpdateEvent(REDRAW_EVENT); } else { locale.set(LOCALE); } }
java
public void setLocale(final Locale LOCALE) { if (null == locale) { _locale = LOCALE; fireUpdateEvent(REDRAW_EVENT); } else { locale.set(LOCALE); } }
[ "public", "void", "setLocale", "(", "final", "Locale", "LOCALE", ")", "{", "if", "(", "null", "==", "locale", ")", "{", "_locale", "=", "LOCALE", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "locale", ".", "set", "(", "LOCAL...
Defines the Locale that will be used to format the date in some ClockSkins. @param LOCALE
[ "Defines", "the", "Locale", "that", "will", "be", "used", "to", "format", "the", "date", "in", "some", "ClockSkins", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1836-L1843
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.setCustomFont
public void setCustomFont(final Font FONT) { if (null == customFont) { _customFont = FONT; fireUpdateEvent(RESIZE_EVENT); } else { customFont.set(FONT); } }
java
public void setCustomFont(final Font FONT) { if (null == customFont) { _customFont = FONT; fireUpdateEvent(RESIZE_EVENT); } else { customFont.set(FONT); } }
[ "public", "void", "setCustomFont", "(", "final", "Font", "FONT", ")", "{", "if", "(", "null", "==", "customFont", ")", "{", "_customFont", "=", "FONT", ";", "fireUpdateEvent", "(", "RESIZE_EVENT", ")", ";", "}", "else", "{", "customFont", ".", "set", "("...
Defines the custom font that can be used to render all text elements. To enable the custom font one has to set customFontEnabled = true @param FONT
[ "Defines", "the", "custom", "font", "that", "can", "be", "used", "to", "render", "all", "text", "elements", ".", "To", "enable", "the", "custom", "font", "one", "has", "to", "set", "customFontEnabled", "=", "true" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L1978-L1985
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Clock.java
Clock.checkAlarms
private void checkAlarms(final ZonedDateTime TIME) { alarmsToRemove.clear(); for (Alarm alarm : alarms) { final ZonedDateTime ALARM_TIME = alarm.getTime(); switch (alarm.getRepetition()) { case ONCE: if (TIME.isAfter(ALARM_TIME)) { if (alarm.isArmed()) { fireAlarmEvent(new AlarmEvent(Clock.this, alarm)); alarm.executeCommand(); } alarmsToRemove.add(alarm); } break; case HALF_HOURLY: if ((ALARM_TIME.getMinute() == TIME.getMinute() || ALARM_TIME.plusMinutes(30).getMinute() == TIME.getMinute()) && ALARM_TIME.getSecond() == TIME.getSecond()) { if (alarm.isArmed()) { fireAlarmEvent(new AlarmEvent(Clock.this, alarm)); alarm.executeCommand(); } } break; case HOURLY: if (ALARM_TIME.getMinute() == TIME.getMinute() && ALARM_TIME.getSecond() == TIME.getSecond()) { if (alarm.isArmed()) { fireAlarmEvent(new AlarmEvent(Clock.this, alarm)); alarm.executeCommand(); } } break; case DAILY: if (ALARM_TIME.getHour() == TIME.getHour() && ALARM_TIME.getMinute() == TIME.getMinute() && ALARM_TIME.getSecond() == TIME.getSecond()) { if (alarm.isArmed()) { fireAlarmEvent(new AlarmEvent(Clock.this, alarm)); alarm.executeCommand(); } } break; case WEEKLY: if (ALARM_TIME.getDayOfWeek() == TIME.getDayOfWeek() && ALARM_TIME.getHour() == TIME.getHour() && ALARM_TIME.getMinute() == TIME.getMinute() && ALARM_TIME.getSecond() == TIME.getSecond()) { if (alarm.isArmed()) { fireAlarmEvent(new AlarmEvent(Clock.this, alarm)); alarm.executeCommand(); } } break; } } for (Alarm alarm : alarmsToRemove) { removeAlarm(alarm); } }
java
private void checkAlarms(final ZonedDateTime TIME) { alarmsToRemove.clear(); for (Alarm alarm : alarms) { final ZonedDateTime ALARM_TIME = alarm.getTime(); switch (alarm.getRepetition()) { case ONCE: if (TIME.isAfter(ALARM_TIME)) { if (alarm.isArmed()) { fireAlarmEvent(new AlarmEvent(Clock.this, alarm)); alarm.executeCommand(); } alarmsToRemove.add(alarm); } break; case HALF_HOURLY: if ((ALARM_TIME.getMinute() == TIME.getMinute() || ALARM_TIME.plusMinutes(30).getMinute() == TIME.getMinute()) && ALARM_TIME.getSecond() == TIME.getSecond()) { if (alarm.isArmed()) { fireAlarmEvent(new AlarmEvent(Clock.this, alarm)); alarm.executeCommand(); } } break; case HOURLY: if (ALARM_TIME.getMinute() == TIME.getMinute() && ALARM_TIME.getSecond() == TIME.getSecond()) { if (alarm.isArmed()) { fireAlarmEvent(new AlarmEvent(Clock.this, alarm)); alarm.executeCommand(); } } break; case DAILY: if (ALARM_TIME.getHour() == TIME.getHour() && ALARM_TIME.getMinute() == TIME.getMinute() && ALARM_TIME.getSecond() == TIME.getSecond()) { if (alarm.isArmed()) { fireAlarmEvent(new AlarmEvent(Clock.this, alarm)); alarm.executeCommand(); } } break; case WEEKLY: if (ALARM_TIME.getDayOfWeek() == TIME.getDayOfWeek() && ALARM_TIME.getHour() == TIME.getHour() && ALARM_TIME.getMinute() == TIME.getMinute() && ALARM_TIME.getSecond() == TIME.getSecond()) { if (alarm.isArmed()) { fireAlarmEvent(new AlarmEvent(Clock.this, alarm)); alarm.executeCommand(); } } break; } } for (Alarm alarm : alarmsToRemove) { removeAlarm(alarm); } }
[ "private", "void", "checkAlarms", "(", "final", "ZonedDateTime", "TIME", ")", "{", "alarmsToRemove", ".", "clear", "(", ")", ";", "for", "(", "Alarm", "alarm", ":", "alarms", ")", "{", "final", "ZonedDateTime", "ALARM_TIME", "=", "alarm", ".", "getTime", "...
Calling this method will check the current time against all Alarm objects in alarms. The Alarm object will fire events in case the time is after the alarm time. @param TIME
[ "Calling", "this", "method", "will", "check", "the", "current", "time", "against", "all", "Alarm", "objects", "in", "alarms", ".", "The", "Alarm", "object", "will", "fire", "events", "in", "case", "the", "time", "is", "after", "the", "alarm", "time", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Clock.java#L2004-L2063
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMinValue
public void setMinValue(final double VALUE) { if (Status.RUNNING == timeline.getStatus()) { timeline.jumpTo(Duration.ONE); } if (null == minValue) { if (VALUE > getMaxValue()) { setMaxValue(VALUE); } _minValue = Helper.clamp(-Double.MAX_VALUE, getMaxValue(), VALUE); setRange(getMaxValue() - _minValue); if (Double.compare(originalMinValue, -Double.MAX_VALUE) == 0) originalMinValue = _minValue; if (isStartFromZero() && _minValue < 0) setValue(0); if (Double.compare(originalThreshold, getThreshold()) < 0) { setThreshold(Helper.clamp(_minValue, getMaxValue(), originalThreshold)); } updateFormatString(); fireUpdateEvent(RECALC_EVENT); if (!valueProperty().isBound()) Gauge.this.setValue(Helper.clamp(getMinValue(), getMaxValue(), Gauge.this.getValue())); } else { minValue.set(VALUE); } }
java
public void setMinValue(final double VALUE) { if (Status.RUNNING == timeline.getStatus()) { timeline.jumpTo(Duration.ONE); } if (null == minValue) { if (VALUE > getMaxValue()) { setMaxValue(VALUE); } _minValue = Helper.clamp(-Double.MAX_VALUE, getMaxValue(), VALUE); setRange(getMaxValue() - _minValue); if (Double.compare(originalMinValue, -Double.MAX_VALUE) == 0) originalMinValue = _minValue; if (isStartFromZero() && _minValue < 0) setValue(0); if (Double.compare(originalThreshold, getThreshold()) < 0) { setThreshold(Helper.clamp(_minValue, getMaxValue(), originalThreshold)); } updateFormatString(); fireUpdateEvent(RECALC_EVENT); if (!valueProperty().isBound()) Gauge.this.setValue(Helper.clamp(getMinValue(), getMaxValue(), Gauge.this.getValue())); } else { minValue.set(VALUE); } }
[ "public", "void", "setMinValue", "(", "final", "double", "VALUE", ")", "{", "if", "(", "Status", ".", "RUNNING", "==", "timeline", ".", "getStatus", "(", ")", ")", "{", "timeline", ".", "jumpTo", "(", "Duration", ".", "ONE", ")", ";", "}", "if", "(",...
Sets the minimum value of the gauge scale to the given value @param VALUE
[ "Sets", "the", "minimum", "value", "of", "the", "gauge", "scale", "to", "the", "given", "value" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L876-L891
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setSubTitle
public void setSubTitle(final String SUBTITLE) { if (null == subTitle) { _subTitle = SUBTITLE; fireUpdateEvent(VISIBILITY_EVENT); fireUpdateEvent(REDRAW_EVENT); } else { subTitle.set(SUBTITLE); } }
java
public void setSubTitle(final String SUBTITLE) { if (null == subTitle) { _subTitle = SUBTITLE; fireUpdateEvent(VISIBILITY_EVENT); fireUpdateEvent(REDRAW_EVENT); } else { subTitle.set(SUBTITLE); } }
[ "public", "void", "setSubTitle", "(", "final", "String", "SUBTITLE", ")", "{", "if", "(", "null", "==", "subTitle", ")", "{", "_subTitle", "=", "SUBTITLE", ";", "fireUpdateEvent", "(", "VISIBILITY_EVENT", ")", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ...
Sets the subtitle of the gauge. This subtitle will usually only be visible if it is not empty. @param SUBTITLE
[ "Sets", "the", "subtitle", "of", "the", "gauge", ".", "This", "subtitle", "will", "usually", "only", "be", "visible", "if", "it", "is", "not", "empty", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1083-L1091
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setAreas
public void setAreas(final List<Section> AREAS) { areas.setAll(AREAS); Collections.sort(areas, new SectionComparator()); fireUpdateEvent(SECTION_EVENT); }
java
public void setAreas(final List<Section> AREAS) { areas.setAll(AREAS); Collections.sort(areas, new SectionComparator()); fireUpdateEvent(SECTION_EVENT); }
[ "public", "void", "setAreas", "(", "final", "List", "<", "Section", ">", "AREAS", ")", "{", "areas", ".", "setAll", "(", "AREAS", ")", ";", "Collections", ".", "sort", "(", "areas", ",", "new", "SectionComparator", "(", ")", ")", ";", "fireUpdateEvent", ...
Sets the sections to the given list of Section objects. The sections will be used to colorize areas with a special meaning such as the red area in a rpm gauge. Areas in the Medusa library usually are more eye-catching than Sections. @param AREAS
[ "Sets", "the", "sections", "to", "the", "given", "list", "of", "Section", "objects", ".", "The", "sections", "will", "be", "used", "to", "colorize", "areas", "with", "a", "special", "meaning", "such", "as", "the", "red", "area", "in", "a", "rpm", "gauge"...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1310-L1314
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.addArea
public void addArea(final Section AREA) { if (null == AREA) return; areas.add(AREA); Collections.sort(areas, new SectionComparator()); fireUpdateEvent(SECTION_EVENT); }
java
public void addArea(final Section AREA) { if (null == AREA) return; areas.add(AREA); Collections.sort(areas, new SectionComparator()); fireUpdateEvent(SECTION_EVENT); }
[ "public", "void", "addArea", "(", "final", "Section", "AREA", ")", "{", "if", "(", "null", "==", "AREA", ")", "return", ";", "areas", ".", "add", "(", "AREA", ")", ";", "Collections", ".", "sort", "(", "areas", ",", "new", "SectionComparator", "(", "...
Adds the given Section to the list of areas. Areas in the Medusa library usually are more eye-catching than Sections. @param AREA
[ "Adds", "the", "given", "Section", "to", "the", "list", "of", "areas", ".", "Areas", "in", "the", "Medusa", "library", "usually", "are", "more", "eye", "-", "catching", "than", "Sections", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1332-L1337
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.removeArea
public void removeArea(final Section AREA) { if (null == AREA) return; areas.remove(AREA); Collections.sort(areas, new SectionComparator()); fireUpdateEvent(SECTION_EVENT); }
java
public void removeArea(final Section AREA) { if (null == AREA) return; areas.remove(AREA); Collections.sort(areas, new SectionComparator()); fireUpdateEvent(SECTION_EVENT); }
[ "public", "void", "removeArea", "(", "final", "Section", "AREA", ")", "{", "if", "(", "null", "==", "AREA", ")", "return", ";", "areas", ".", "remove", "(", "AREA", ")", ";", "Collections", ".", "sort", "(", "areas", ",", "new", "SectionComparator", "(...
Removes the given Section from the list of areas. Areas in the Medusa library usually are more eye-catching than Sections. @param AREA
[ "Removes", "the", "given", "Section", "from", "the", "list", "of", "areas", ".", "Areas", "in", "the", "Medusa", "library", "usually", "are", "more", "eye", "-", "catching", "than", "Sections", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1345-L1350
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setTickMarkSections
public void setTickMarkSections(final List<Section> SECTIONS) { tickMarkSections.setAll(SECTIONS); Collections.sort(tickMarkSections, new SectionComparator()); fireUpdateEvent(REDRAW_EVENT); }
java
public void setTickMarkSections(final List<Section> SECTIONS) { tickMarkSections.setAll(SECTIONS); Collections.sort(tickMarkSections, new SectionComparator()); fireUpdateEvent(REDRAW_EVENT); }
[ "public", "void", "setTickMarkSections", "(", "final", "List", "<", "Section", ">", "SECTIONS", ")", "{", "tickMarkSections", ".", "setAll", "(", "SECTIONS", ")", ";", "Collections", ".", "sort", "(", "tickMarkSections", ",", "new", "SectionComparator", "(", "...
Sets the tickmark sections to the given list of Section objects. @param SECTIONS
[ "Sets", "the", "tickmark", "sections", "to", "the", "given", "list", "of", "Section", "objects", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1372-L1376
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.addTickMarkSection
public void addTickMarkSection(final Section SECTION) { if (null == SECTION) return; tickMarkSections.add(SECTION); Collections.sort(tickMarkSections, new SectionComparator()); fireUpdateEvent(REDRAW_EVENT); }
java
public void addTickMarkSection(final Section SECTION) { if (null == SECTION) return; tickMarkSections.add(SECTION); Collections.sort(tickMarkSections, new SectionComparator()); fireUpdateEvent(REDRAW_EVENT); }
[ "public", "void", "addTickMarkSection", "(", "final", "Section", "SECTION", ")", "{", "if", "(", "null", "==", "SECTION", ")", "return", ";", "tickMarkSections", ".", "add", "(", "SECTION", ")", ";", "Collections", ".", "sort", "(", "tickMarkSections", ",", ...
Adds the given Section to the list of tickmark sections. @param SECTION
[ "Adds", "the", "given", "Section", "to", "the", "list", "of", "tickmark", "sections", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1388-L1393
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.removeTickMarkSection
public void removeTickMarkSection(final Section SECTION) { if (null == SECTION) return; tickMarkSections.remove(SECTION); Collections.sort(tickMarkSections, new SectionComparator()); fireUpdateEvent(REDRAW_EVENT); }
java
public void removeTickMarkSection(final Section SECTION) { if (null == SECTION) return; tickMarkSections.remove(SECTION); Collections.sort(tickMarkSections, new SectionComparator()); fireUpdateEvent(REDRAW_EVENT); }
[ "public", "void", "removeTickMarkSection", "(", "final", "Section", "SECTION", ")", "{", "if", "(", "null", "==", "SECTION", ")", "return", ";", "tickMarkSections", ".", "remove", "(", "SECTION", ")", ";", "Collections", ".", "sort", "(", "tickMarkSections", ...
Removes the given Section from the list of tickmark sections. @param SECTION
[ "Removes", "the", "given", "Section", "from", "the", "list", "of", "tickmark", "sections", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1399-L1404
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setTickLabelSections
public void setTickLabelSections(final List<Section> SECTIONS) { tickLabelSections.setAll(SECTIONS); Collections.sort(tickLabelSections, new SectionComparator()); fireUpdateEvent(REDRAW_EVENT); }
java
public void setTickLabelSections(final List<Section> SECTIONS) { tickLabelSections.setAll(SECTIONS); Collections.sort(tickLabelSections, new SectionComparator()); fireUpdateEvent(REDRAW_EVENT); }
[ "public", "void", "setTickLabelSections", "(", "final", "List", "<", "Section", ">", "SECTIONS", ")", "{", "tickLabelSections", ".", "setAll", "(", "SECTIONS", ")", ";", "Collections", ".", "sort", "(", "tickLabelSections", ",", "new", "SectionComparator", "(", ...
Sets the ticklabel sections to the given list of Section objects. @param SECTIONS
[ "Sets", "the", "ticklabel", "sections", "to", "the", "given", "list", "of", "Section", "objects", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1426-L1430
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.addTickLabelSection
public void addTickLabelSection(final Section SECTION) { if (null == SECTION) return; tickLabelSections.add(SECTION); Collections.sort(tickLabelSections, new SectionComparator()); fireUpdateEvent(REDRAW_EVENT); }
java
public void addTickLabelSection(final Section SECTION) { if (null == SECTION) return; tickLabelSections.add(SECTION); Collections.sort(tickLabelSections, new SectionComparator()); fireUpdateEvent(REDRAW_EVENT); }
[ "public", "void", "addTickLabelSection", "(", "final", "Section", "SECTION", ")", "{", "if", "(", "null", "==", "SECTION", ")", "return", ";", "tickLabelSections", ".", "add", "(", "SECTION", ")", ";", "Collections", ".", "sort", "(", "tickLabelSections", ",...
Adds the given Section to the list of ticklabel sections. @param SECTION
[ "Adds", "the", "given", "Section", "to", "the", "list", "of", "ticklabel", "sections", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1442-L1447
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.removeTickLabelSection
public void removeTickLabelSection(final Section SECTION) { if (null == SECTION) return; tickLabelSections.remove(SECTION); Collections.sort(tickLabelSections, new SectionComparator()); fireUpdateEvent(REDRAW_EVENT); }
java
public void removeTickLabelSection(final Section SECTION) { if (null == SECTION) return; tickLabelSections.remove(SECTION); Collections.sort(tickLabelSections, new SectionComparator()); fireUpdateEvent(REDRAW_EVENT); }
[ "public", "void", "removeTickLabelSection", "(", "final", "Section", "SECTION", ")", "{", "if", "(", "null", "==", "SECTION", ")", "return", ";", "tickLabelSections", ".", "remove", "(", "SECTION", ")", ";", "Collections", ".", "sort", "(", "tickLabelSections"...
Removes the given Section from the list of ticklabel sections. @param SECTION
[ "Removes", "the", "given", "Section", "from", "the", "list", "of", "ticklabel", "sections", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1453-L1458
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.addMarker
public void addMarker(final Marker MARKER) { if (null == MARKER) return; markers.add(MARKER); Collections.sort(markers, new MarkerComparator()); fireUpdateEvent(REDRAW_EVENT); }
java
public void addMarker(final Marker MARKER) { if (null == MARKER) return; markers.add(MARKER); Collections.sort(markers, new MarkerComparator()); fireUpdateEvent(REDRAW_EVENT); }
[ "public", "void", "addMarker", "(", "final", "Marker", "MARKER", ")", "{", "if", "(", "null", "==", "MARKER", ")", "return", ";", "markers", ".", "add", "(", "MARKER", ")", ";", "Collections", ".", "sort", "(", "markers", ",", "new", "MarkerComparator", ...
Adds the given Marker to the list of markers. @param MARKER
[ "Adds", "the", "given", "Marker", "to", "the", "list", "of", "markers", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1502-L1507
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.removeMarker
public void removeMarker(final Marker MARKER) { if (null == MARKER) return; markers.remove(MARKER); Collections.sort(markers, new MarkerComparator()); fireUpdateEvent(REDRAW_EVENT); }
java
public void removeMarker(final Marker MARKER) { if (null == MARKER) return; markers.remove(MARKER); Collections.sort(markers, new MarkerComparator()); fireUpdateEvent(REDRAW_EVENT); }
[ "public", "void", "removeMarker", "(", "final", "Marker", "MARKER", ")", "{", "if", "(", "null", "==", "MARKER", ")", "return", ";", "markers", ".", "remove", "(", "MARKER", ")", ";", "Collections", ".", "sort", "(", "markers", ",", "new", "MarkerCompara...
Removes the given Marker from the list of markers. @param MARKER
[ "Removes", "the", "given", "Marker", "from", "the", "list", "of", "markers", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1513-L1518
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setForegroundBaseColor
public void setForegroundBaseColor(final Color COLOR) { if (null == titleColor) { _titleColor = COLOR; } else { titleColor.set(COLOR); } if (null == subTitleColor) { _subTitleColor = COLOR; } else { subTitleColor.set(COLOR); } if (null == unitColor) { _unitColor = COLOR; } else { unitColor.set(COLOR); } if (null == valueColor) { _valueColor = COLOR; } else { valueColor.set(COLOR); } if (null == tickLabelColor) { _tickLabelColor = COLOR; } else { tickLabelColor.set(COLOR); } if (null == zeroColor) { _zeroColor = COLOR; } else { zeroColor.set(COLOR); } if (null == tickMarkColor) { _tickMarkColor = COLOR; } else { tickMarkColor.set(COLOR); } if (null == majorTickMarkColor) { _majorTickMarkColor = COLOR; } else { majorTickMarkColor.set(COLOR); } if (null == mediumTickMarkColor) { _mediumTickMarkColor = COLOR; } else { mediumTickMarkColor.set(COLOR); } if (null == minorTickMarkColor) { _minorTickMarkColor = COLOR; } else { minorTickMarkColor.set(COLOR); } fireUpdateEvent(REDRAW_EVENT); }
java
public void setForegroundBaseColor(final Color COLOR) { if (null == titleColor) { _titleColor = COLOR; } else { titleColor.set(COLOR); } if (null == subTitleColor) { _subTitleColor = COLOR; } else { subTitleColor.set(COLOR); } if (null == unitColor) { _unitColor = COLOR; } else { unitColor.set(COLOR); } if (null == valueColor) { _valueColor = COLOR; } else { valueColor.set(COLOR); } if (null == tickLabelColor) { _tickLabelColor = COLOR; } else { tickLabelColor.set(COLOR); } if (null == zeroColor) { _zeroColor = COLOR; } else { zeroColor.set(COLOR); } if (null == tickMarkColor) { _tickMarkColor = COLOR; } else { tickMarkColor.set(COLOR); } if (null == majorTickMarkColor) { _majorTickMarkColor = COLOR; } else { majorTickMarkColor.set(COLOR); } if (null == mediumTickMarkColor) { _mediumTickMarkColor = COLOR; } else { mediumTickMarkColor.set(COLOR); } if (null == minorTickMarkColor) { _minorTickMarkColor = COLOR; } else { minorTickMarkColor.set(COLOR); } fireUpdateEvent(REDRAW_EVENT); }
[ "public", "void", "setForegroundBaseColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "titleColor", ")", "{", "_titleColor", "=", "COLOR", ";", "}", "else", "{", "titleColor", ".", "set", "(", "COLOR", ")", ";", "}", "if", "(",...
A convenient method to set the color of foreground elements like title, subTitle, unit, value, tickLabel and tickMark to the given Color. @param COLOR
[ "A", "convenient", "method", "to", "set", "the", "color", "of", "foreground", "elements", "like", "title", "subTitle", "unit", "value", "tickLabel", "and", "tickMark", "to", "the", "given", "Color", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1536-L1548
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setZeroColor
public void setZeroColor(final Color COLOR) { if (null == zeroColor) { _zeroColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { zeroColor.set(COLOR); } }
java
public void setZeroColor(final Color COLOR) { if (null == zeroColor) { _zeroColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { zeroColor.set(COLOR); } }
[ "public", "void", "setZeroColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "zeroColor", ")", "{", "_zeroColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "zeroColor", ".", "set", "(",...
Defines the color that will be used to colorize the 0 tickmark and ticklabel when the gauge range has a negative min- and positive maxValue. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "0", "tickmark", "and", "ticklabel", "when", "the", "gauge", "range", "has", "a", "negative", "min", "-", "and", "positive", "maxValue", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L1639-L1646
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setKnobType
public void setKnobType(final KnobType TYPE) { if (null == knobType) { _knobType = null == TYPE ? KnobType.STANDARD : TYPE; fireUpdateEvent(RESIZE_EVENT); } else { knobType.set(TYPE); } }
java
public void setKnobType(final KnobType TYPE) { if (null == knobType) { _knobType = null == TYPE ? KnobType.STANDARD : TYPE; fireUpdateEvent(RESIZE_EVENT); } else { knobType.set(TYPE); } }
[ "public", "void", "setKnobType", "(", "final", "KnobType", "TYPE", ")", "{", "if", "(", "null", "==", "knobType", ")", "{", "_knobType", "=", "null", "==", "TYPE", "?", "KnobType", ".", "STANDARD", ":", "TYPE", ";", "fireUpdateEvent", "(", "RESIZE_EVENT", ...
Defines the type of knob that will be used in the radial gauges. The values are STANDARD, PLAIN, METAL and FLAT. @param TYPE
[ "Defines", "the", "type", "of", "knob", "that", "will", "be", "used", "in", "the", "radial", "gauges", ".", "The", "values", "are", "STANDARD", "PLAIN", "METAL", "and", "FLAT", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2017-L2024
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setKnobVisible
public void setKnobVisible(final boolean VISIBLE) { if (null == knobVisible) { _knobVisible = VISIBLE; fireUpdateEvent(VISIBILITY_EVENT); } else { knobVisible.set(VISIBLE); } }
java
public void setKnobVisible(final boolean VISIBLE) { if (null == knobVisible) { _knobVisible = VISIBLE; fireUpdateEvent(VISIBILITY_EVENT); } else { knobVisible.set(VISIBLE); } }
[ "public", "void", "setKnobVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "knobVisible", ")", "{", "_knobVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "VISIBILITY_EVENT", ")", ";", "}", "else", "{", "knobVisible", "....
Defines if the knob is visible. @param VISIBLE
[ "Defines", "if", "the", "knob", "is", "visible", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2105-L2112
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setAngleRange
public void setAngleRange(final double RANGE) { double tmpAngleRange = Helper.clamp(0.0, 360.0, RANGE); if (null == angleRange) { _angleRange = tmpAngleRange; setAngleStep(tmpAngleRange / getRange()); if (isAutoScale()) { calcAutoScale(); } fireUpdateEvent(RECALC_EVENT); } else { angleRange.set(tmpAngleRange); } }
java
public void setAngleRange(final double RANGE) { double tmpAngleRange = Helper.clamp(0.0, 360.0, RANGE); if (null == angleRange) { _angleRange = tmpAngleRange; setAngleStep(tmpAngleRange / getRange()); if (isAutoScale()) { calcAutoScale(); } fireUpdateEvent(RECALC_EVENT); } else { angleRange.set(tmpAngleRange); } }
[ "public", "void", "setAngleRange", "(", "final", "double", "RANGE", ")", "{", "double", "tmpAngleRange", "=", "Helper", ".", "clamp", "(", "0.0", ",", "360.0", ",", "RANGE", ")", ";", "if", "(", "null", "==", "angleRange", ")", "{", "_angleRange", "=", ...
Defines the angle range in degree that will be used to draw the scale of the radial gauge. The given range will be clamped in the range of 0 - 360 degrees. The range will start at the startAngle and will be drawn in the direction dependent on the scaleDirection. @param RANGE
[ "Defines", "the", "angle", "range", "in", "degree", "that", "will", "be", "used", "to", "draw", "the", "scale", "of", "the", "radial", "gauge", ".", "The", "given", "range", "will", "be", "clamped", "in", "the", "range", "of", "0", "-", "360", "degrees...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2235-L2245
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setBarEffectEnabled
public void setBarEffectEnabled(final boolean ENABLED) { if (null == barEffectEnabled) { _barEffectEnabled = ENABLED; fireUpdateEvent(VISIBILITY_EVENT); } else { barEffectEnabled.set(ENABLED); } }
java
public void setBarEffectEnabled(final boolean ENABLED) { if (null == barEffectEnabled) { _barEffectEnabled = ENABLED; fireUpdateEvent(VISIBILITY_EVENT); } else { barEffectEnabled.set(ENABLED); } }
[ "public", "void", "setBarEffectEnabled", "(", "final", "boolean", "ENABLED", ")", "{", "if", "(", "null", "==", "barEffectEnabled", ")", "{", "_barEffectEnabled", "=", "ENABLED", ";", "fireUpdateEvent", "(", "VISIBILITY_EVENT", ")", ";", "}", "else", "{", "bar...
Defines if the the highlight effect on the gauges like the LinearSkin bar will be drawn. If you would like to have a more flat style you should set this to false. @param ENABLED
[ "Defines", "if", "the", "the", "highlight", "effect", "on", "the", "gauges", "like", "the", "LinearSkin", "bar", "will", "be", "drawn", ".", "If", "you", "would", "like", "to", "have", "a", "more", "flat", "style", "you", "should", "set", "this", "to", ...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2392-L2399
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setScaleDirection
public void setScaleDirection(final ScaleDirection DIRECTION) { if (null == scaleDirection) { _scaleDirection = null == DIRECTION ? ScaleDirection.CLOCKWISE : DIRECTION; fireUpdateEvent(RECALC_EVENT); } else { scaleDirection.set(DIRECTION); } }
java
public void setScaleDirection(final ScaleDirection DIRECTION) { if (null == scaleDirection) { _scaleDirection = null == DIRECTION ? ScaleDirection.CLOCKWISE : DIRECTION; fireUpdateEvent(RECALC_EVENT); } else { scaleDirection.set(DIRECTION); } }
[ "public", "void", "setScaleDirection", "(", "final", "ScaleDirection", "DIRECTION", ")", "{", "if", "(", "null", "==", "scaleDirection", ")", "{", "_scaleDirection", "=", "null", "==", "DIRECTION", "?", "ScaleDirection", ".", "CLOCKWISE", ":", "DIRECTION", ";", ...
Defines the direction of the scale. The values are CLOCKWISE and COUNTER_CLOCKWISE. This property is needed to realize gauges like in QuarterSkin where the needle and knob should be placed on the upper right corner and the scale should start at the bottom. Here you need a counter-clockwise direction of the scale. @param DIRECTION
[ "Defines", "the", "direction", "of", "the", "scale", ".", "The", "values", "are", "CLOCKWISE", "and", "COUNTER_CLOCKWISE", ".", "This", "property", "is", "needed", "to", "realize", "gauges", "like", "in", "QuarterSkin", "where", "the", "needle", "and", "knob",...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2432-L2439
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setTickLabelOrientation
public void setTickLabelOrientation(final TickLabelOrientation ORIENTATION) { if (null == tickLabelOrientation) { _tickLabelOrientation = null == ORIENTATION ? TickLabelOrientation.HORIZONTAL : ORIENTATION; fireUpdateEvent(REDRAW_EVENT); } else { tickLabelOrientation.set(ORIENTATION); } }
java
public void setTickLabelOrientation(final TickLabelOrientation ORIENTATION) { if (null == tickLabelOrientation) { _tickLabelOrientation = null == ORIENTATION ? TickLabelOrientation.HORIZONTAL : ORIENTATION; fireUpdateEvent(REDRAW_EVENT); } else { tickLabelOrientation.set(ORIENTATION); } }
[ "public", "void", "setTickLabelOrientation", "(", "final", "TickLabelOrientation", "ORIENTATION", ")", "{", "if", "(", "null", "==", "tickLabelOrientation", ")", "{", "_tickLabelOrientation", "=", "null", "==", "ORIENTATION", "?", "TickLabelOrientation", ".", "HORIZON...
Defines the orientation of the ticklabels. The values are HORIZONTAL, ORTHOGONAL and TANGENT. Especially the ORTHOGONAL setting can be useful when using scales with big numbers. @param ORIENTATION
[ "Defines", "the", "orientation", "of", "the", "ticklabels", ".", "The", "values", "are", "HORIZONTAL", "ORTHOGONAL", "and", "TANGENT", ".", "Especially", "the", "ORTHOGONAL", "setting", "can", "be", "useful", "when", "using", "scales", "with", "big", "numbers", ...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2508-L2515
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setTickMarkColor
public void setTickMarkColor(final Color COLOR) { if (null == tickMarkColor) { _tickMarkColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { tickMarkColor.set(COLOR); } }
java
public void setTickMarkColor(final Color COLOR) { if (null == tickMarkColor) { _tickMarkColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { tickMarkColor.set(COLOR); } }
[ "public", "void", "setTickMarkColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "tickMarkColor", ")", "{", "_tickMarkColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "tickMarkColor", ".",...
Defines the color that will be used to colorize the tickmarks. This color will only be used if no tickmark section or major-, medium- and minorTickMarkColor is defined at the position of the tickmark. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "tickmarks", ".", "This", "color", "will", "only", "be", "used", "if", "no", "tickmark", "section", "or", "major", "-", "medium", "-", "and", "minorTickMarkColor", "is", "def...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2579-L2586
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMajorTickMarkColor
public void setMajorTickMarkColor(final Color COLOR) { if (null == majorTickMarkColor) { _majorTickMarkColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { majorTickMarkColor.set(COLOR); } }
java
public void setMajorTickMarkColor(final Color COLOR) { if (null == majorTickMarkColor) { _majorTickMarkColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { majorTickMarkColor.set(COLOR); } }
[ "public", "void", "setMajorTickMarkColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "majorTickMarkColor", ")", "{", "_majorTickMarkColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "majorTi...
Defines the color that will be used to colorize the major tickmarks. This color will only be used if no tickmark section is defined at the position of the tickmark. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "major", "tickmarks", ".", "This", "color", "will", "only", "be", "used", "if", "no", "tickmark", "section", "is", "defined", "at", "the", "position", "of", "the", "tickmark"...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2614-L2621
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMajorTickMarkLengthFactor
public void setMajorTickMarkLengthFactor(final double FACTOR) { if (null == majorTickMarkLengthFactor) { _majorTickMarkLengthFactor = Helper.clamp(0.0, 1.0, FACTOR); fireUpdateEvent(REDRAW_EVENT); } else { majorTickMarkLengthFactor.set(FACTOR); } }
java
public void setMajorTickMarkLengthFactor(final double FACTOR) { if (null == majorTickMarkLengthFactor) { _majorTickMarkLengthFactor = Helper.clamp(0.0, 1.0, FACTOR); fireUpdateEvent(REDRAW_EVENT); } else { majorTickMarkLengthFactor.set(FACTOR); } }
[ "public", "void", "setMajorTickMarkLengthFactor", "(", "final", "double", "FACTOR", ")", "{", "if", "(", "null", "==", "majorTickMarkLengthFactor", ")", "{", "_majorTickMarkLengthFactor", "=", "Helper", ".", "clamp", "(", "0.0", ",", "1.0", ",", "FACTOR", ")", ...
The factor defines the length of the major tick mark. It can be in the range from 0 - 1. @param FACTOR
[ "The", "factor", "defines", "the", "length", "of", "the", "major", "tick", "mark", ".", "It", "can", "be", "in", "the", "range", "from", "0", "-", "1", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2647-L2654
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMajorTickMarkWidthFactor
public void setMajorTickMarkWidthFactor(final double FACTOR) { if (null == majorTickMarkWidthFactor) { _majorTickMarkWidthFactor = Helper.clamp(0.0, 1.0, FACTOR); fireUpdateEvent(REDRAW_EVENT); } else { majorTickMarkWidthFactor.set(FACTOR); } }
java
public void setMajorTickMarkWidthFactor(final double FACTOR) { if (null == majorTickMarkWidthFactor) { _majorTickMarkWidthFactor = Helper.clamp(0.0, 1.0, FACTOR); fireUpdateEvent(REDRAW_EVENT); } else { majorTickMarkWidthFactor.set(FACTOR); } }
[ "public", "void", "setMajorTickMarkWidthFactor", "(", "final", "double", "FACTOR", ")", "{", "if", "(", "null", "==", "majorTickMarkWidthFactor", ")", "{", "_majorTickMarkWidthFactor", "=", "Helper", ".", "clamp", "(", "0.0", ",", "1.0", ",", "FACTOR", ")", ";...
The factor defines the width of the major tick mark. It can be in the range from 0 - 1. @param FACTOR
[ "The", "factor", "defines", "the", "width", "of", "the", "major", "tick", "mark", ".", "It", "can", "be", "in", "the", "range", "from", "0", "-", "1", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2683-L2690
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMediumTickMarkColor
public void setMediumTickMarkColor(final Color COLOR) { if (null == mediumTickMarkColor) { _mediumTickMarkColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { mediumTickMarkColor.set(COLOR); } }
java
public void setMediumTickMarkColor(final Color COLOR) { if (null == mediumTickMarkColor) { _mediumTickMarkColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { mediumTickMarkColor.set(COLOR); } }
[ "public", "void", "setMediumTickMarkColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "mediumTickMarkColor", ")", "{", "_mediumTickMarkColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "medi...
Defines the color that will be used to colorize the medium tickmarks. This color will only be used if no tickmark section is defined at the position of the tickmark. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "medium", "tickmarks", ".", "This", "color", "will", "only", "be", "used", "if", "no", "tickmark", "section", "is", "defined", "at", "the", "position", "of", "the", "tickmark...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2721-L2728
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMediumTickMarkLengthFactor
public void setMediumTickMarkLengthFactor(final double FACTOR) { if (null == mediumTickMarkLengthFactor) { _mediumTickMarkLengthFactor = Helper.clamp(0.0, 1.0, FACTOR); fireUpdateEvent(REDRAW_EVENT); } else { mediumTickMarkLengthFactor.set(FACTOR); } }
java
public void setMediumTickMarkLengthFactor(final double FACTOR) { if (null == mediumTickMarkLengthFactor) { _mediumTickMarkLengthFactor = Helper.clamp(0.0, 1.0, FACTOR); fireUpdateEvent(REDRAW_EVENT); } else { mediumTickMarkLengthFactor.set(FACTOR); } }
[ "public", "void", "setMediumTickMarkLengthFactor", "(", "final", "double", "FACTOR", ")", "{", "if", "(", "null", "==", "mediumTickMarkLengthFactor", ")", "{", "_mediumTickMarkLengthFactor", "=", "Helper", ".", "clamp", "(", "0.0", ",", "1.0", ",", "FACTOR", ")"...
The factor defines the length of the medium tick mark. It can be in the range from 0 - 1. @param FACTOR
[ "The", "factor", "defines", "the", "length", "of", "the", "medium", "tick", "mark", ".", "It", "can", "be", "in", "the", "range", "from", "0", "-", "1", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2754-L2761
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMediumTickMarkWidthFactor
public void setMediumTickMarkWidthFactor(final double FACTOR) { if (null == mediumTickMarkWidthFactor) { _mediumTickMarkWidthFactor = Helper.clamp(0.0, 1.0, FACTOR); fireUpdateEvent(REDRAW_EVENT); } else { mediumTickMarkWidthFactor.set(FACTOR); } }
java
public void setMediumTickMarkWidthFactor(final double FACTOR) { if (null == mediumTickMarkWidthFactor) { _mediumTickMarkWidthFactor = Helper.clamp(0.0, 1.0, FACTOR); fireUpdateEvent(REDRAW_EVENT); } else { mediumTickMarkWidthFactor.set(FACTOR); } }
[ "public", "void", "setMediumTickMarkWidthFactor", "(", "final", "double", "FACTOR", ")", "{", "if", "(", "null", "==", "mediumTickMarkWidthFactor", ")", "{", "_mediumTickMarkWidthFactor", "=", "Helper", ".", "clamp", "(", "0.0", ",", "1.0", ",", "FACTOR", ")", ...
The factor defines the width of the medium tick mark. It can be in the range from 0 - 1. @param FACTOR
[ "The", "factor", "defines", "the", "width", "of", "the", "medium", "tick", "mark", ".", "It", "can", "be", "in", "the", "range", "from", "0", "-", "1", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2790-L2797
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMinorTickMarkColor
public void setMinorTickMarkColor(final Color COLOR) { if (null == minorTickMarkColor) { _minorTickMarkColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { minorTickMarkColor.set(COLOR); } }
java
public void setMinorTickMarkColor(final Color COLOR) { if (null == minorTickMarkColor) { _minorTickMarkColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { minorTickMarkColor.set(COLOR); } }
[ "public", "void", "setMinorTickMarkColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "minorTickMarkColor", ")", "{", "_minorTickMarkColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "minorTi...
Defines the color that will be used to colorize the minor tickmarks. This color will only be used if no tickmark section is defined at the position of the tickmark. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "minor", "tickmarks", ".", "This", "color", "will", "only", "be", "used", "if", "no", "tickmark", "section", "is", "defined", "at", "the", "position", "of", "the", "tickmark"...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2828-L2835
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMinorTickMarkLengthFactor
public void setMinorTickMarkLengthFactor(final double FACTOR) { if (null == minorTickMarkLengthFactor) { _minorTickMarkLengthFactor = Helper.clamp(0.0, 1.0, FACTOR); fireUpdateEvent(REDRAW_EVENT); } else { minorTickMarkLengthFactor.set(FACTOR); } }
java
public void setMinorTickMarkLengthFactor(final double FACTOR) { if (null == minorTickMarkLengthFactor) { _minorTickMarkLengthFactor = Helper.clamp(0.0, 1.0, FACTOR); fireUpdateEvent(REDRAW_EVENT); } else { minorTickMarkLengthFactor.set(FACTOR); } }
[ "public", "void", "setMinorTickMarkLengthFactor", "(", "final", "double", "FACTOR", ")", "{", "if", "(", "null", "==", "minorTickMarkLengthFactor", ")", "{", "_minorTickMarkLengthFactor", "=", "Helper", ".", "clamp", "(", "0.0", ",", "1.0", ",", "FACTOR", ")", ...
The factor defines the length of the minor tick mark. It can be in the range from 0 - 1. @param FACTOR
[ "The", "factor", "defines", "the", "length", "of", "the", "minor", "tick", "mark", ".", "It", "can", "be", "in", "the", "range", "from", "0", "-", "1", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2861-L2868
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMinorTickMarkWidthFactor
public void setMinorTickMarkWidthFactor(final double FACTOR) { if (null == minorTickMarkWidthFactor) { _minorTickMarkWidthFactor = Helper.clamp(0.0, 1.0, FACTOR); fireUpdateEvent(REDRAW_EVENT); } else { minorTickMarkWidthFactor.set(FACTOR); } }
java
public void setMinorTickMarkWidthFactor(final double FACTOR) { if (null == minorTickMarkWidthFactor) { _minorTickMarkWidthFactor = Helper.clamp(0.0, 1.0, FACTOR); fireUpdateEvent(REDRAW_EVENT); } else { minorTickMarkWidthFactor.set(FACTOR); } }
[ "public", "void", "setMinorTickMarkWidthFactor", "(", "final", "double", "FACTOR", ")", "{", "if", "(", "null", "==", "minorTickMarkWidthFactor", ")", "{", "_minorTickMarkWidthFactor", "=", "Helper", ".", "clamp", "(", "0.0", ",", "1.0", ",", "FACTOR", ")", ";...
The factor defines the width of the minor tick mark. It can be in the range from 0 - 1. @param FACTOR
[ "The", "factor", "defines", "the", "width", "of", "the", "minor", "tick", "mark", ".", "It", "can", "be", "in", "the", "range", "from", "0", "-", "1", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2897-L2904
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMajorTickMarkType
public void setMajorTickMarkType(final TickMarkType TYPE) { if (null == majorTickMarkType) { _majorTickMarkType = null == TYPE ? TickMarkType.LINE : TYPE; fireUpdateEvent(REDRAW_EVENT); } else { majorTickMarkType.set(TYPE); } }
java
public void setMajorTickMarkType(final TickMarkType TYPE) { if (null == majorTickMarkType) { _majorTickMarkType = null == TYPE ? TickMarkType.LINE : TYPE; fireUpdateEvent(REDRAW_EVENT); } else { majorTickMarkType.set(TYPE); } }
[ "public", "void", "setMajorTickMarkType", "(", "final", "TickMarkType", "TYPE", ")", "{", "if", "(", "null", "==", "majorTickMarkType", ")", "{", "_majorTickMarkType", "=", "null", "==", "TYPE", "?", "TickMarkType", ".", "LINE", ":", "TYPE", ";", "fireUpdateEv...
Defines the shape that will be used to visualize the major tickmark. Values are LINE, DOT, TRAPEZOID, BOX, TICK_LABEL and PILL @param TYPE
[ "Defines", "the", "shape", "that", "will", "be", "used", "to", "visualize", "the", "major", "tickmark", ".", "Values", "are", "LINE", "DOT", "TRAPEZOID", "BOX", "TICK_LABEL", "and", "PILL" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2933-L2940
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMediumTickMarkType
public void setMediumTickMarkType(final TickMarkType TYPE) { if (null == mediumTickMarkType) { _mediumTickMarkType = null == TYPE ? TickMarkType.LINE : TYPE; fireUpdateEvent(REDRAW_EVENT); } else { mediumTickMarkType.set(TYPE); } }
java
public void setMediumTickMarkType(final TickMarkType TYPE) { if (null == mediumTickMarkType) { _mediumTickMarkType = null == TYPE ? TickMarkType.LINE : TYPE; fireUpdateEvent(REDRAW_EVENT); } else { mediumTickMarkType.set(TYPE); } }
[ "public", "void", "setMediumTickMarkType", "(", "final", "TickMarkType", "TYPE", ")", "{", "if", "(", "null", "==", "mediumTickMarkType", ")", "{", "_mediumTickMarkType", "=", "null", "==", "TYPE", "?", "TickMarkType", ".", "LINE", ":", "TYPE", ";", "fireUpdat...
Defines the shape that will be used to visualize the medium tickmark. Values are LINE, DOT, TRAPEZOID, BOX and PILL @param TYPE
[ "Defines", "the", "shape", "that", "will", "be", "used", "to", "visualize", "the", "medium", "tickmark", ".", "Values", "are", "LINE", "DOT", "TRAPEZOID", "BOX", "and", "PILL" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L2969-L2976
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMinorTickMarkType
public void setMinorTickMarkType(final TickMarkType TYPE) { if (null == minorTickMarkType) { _minorTickMarkType = null == TYPE ? TickMarkType.LINE : TYPE; fireUpdateEvent(REDRAW_EVENT); } else { minorTickMarkType.set(TYPE); } }
java
public void setMinorTickMarkType(final TickMarkType TYPE) { if (null == minorTickMarkType) { _minorTickMarkType = null == TYPE ? TickMarkType.LINE : TYPE; fireUpdateEvent(REDRAW_EVENT); } else { minorTickMarkType.set(TYPE); } }
[ "public", "void", "setMinorTickMarkType", "(", "final", "TickMarkType", "TYPE", ")", "{", "if", "(", "null", "==", "minorTickMarkType", ")", "{", "_minorTickMarkType", "=", "null", "==", "TYPE", "?", "TickMarkType", ".", "LINE", ":", "TYPE", ";", "fireUpdateEv...
Defines the shape that will be used to visualize the minor tickmark. Values are LINE, DOT, TRAPEZOID, BOX and PILL @param TYPE
[ "Defines", "the", "shape", "that", "will", "be", "used", "to", "visualize", "the", "minor", "tickmark", ".", "Values", "are", "LINE", "DOT", "TRAPEZOID", "BOX", "and", "PILL" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L3005-L3012
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setNeedleSize
public void setNeedleSize(final NeedleSize SIZE) { if (null == needleSize) { _needleSize = null == SIZE ? NeedleSize.STANDARD : SIZE; fireUpdateEvent(RESIZE_EVENT); } else { needleSize.set(SIZE); } }
java
public void setNeedleSize(final NeedleSize SIZE) { if (null == needleSize) { _needleSize = null == SIZE ? NeedleSize.STANDARD : SIZE; fireUpdateEvent(RESIZE_EVENT); } else { needleSize.set(SIZE); } }
[ "public", "void", "setNeedleSize", "(", "final", "NeedleSize", "SIZE", ")", "{", "if", "(", "null", "==", "needleSize", ")", "{", "_needleSize", "=", "null", "==", "SIZE", "?", "NeedleSize", ".", "STANDARD", ":", "SIZE", ";", "fireUpdateEvent", "(", "RESIZ...
Defines the thickness of the needle. The values are THIN, STANDARD and THICK @param SIZE
[ "Defines", "the", "thickness", "of", "the", "needle", ".", "The", "values", "are", "THIN", "STANDARD", "and", "THICK" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L3225-L3232
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setNeedleBehavior
public void setNeedleBehavior(final NeedleBehavior BEHAVIOR) { if (null == needleBehavior) { _needleBehavior = null == BEHAVIOR ? NeedleBehavior.STANDARD : BEHAVIOR; } else { needleBehavior.set(BEHAVIOR); } }
java
public void setNeedleBehavior(final NeedleBehavior BEHAVIOR) { if (null == needleBehavior) { _needleBehavior = null == BEHAVIOR ? NeedleBehavior.STANDARD : BEHAVIOR; } else { needleBehavior.set(BEHAVIOR); } }
[ "public", "void", "setNeedleBehavior", "(", "final", "NeedleBehavior", "BEHAVIOR", ")", "{", "if", "(", "null", "==", "needleBehavior", ")", "{", "_needleBehavior", "=", "null", "==", "BEHAVIOR", "?", "NeedleBehavior", ".", "STANDARD", ":", "BEHAVIOR", ";", "}...
Defines the behavior of the needle movement. The values are STANDARD and OPTIMIZED This is an experimental feature that only makes sense in gauges that use an angleRange of 360 degrees and where the needle should be able to use the shortest way to the target value. As an example one can think of a compass. If the value in a compass changes from 20 degrees to 290 degrees the needle will take the shortest way to the value, in this case this means it will rotate counter-clockwise. @param BEHAVIOR
[ "Defines", "the", "behavior", "of", "the", "needle", "movement", ".", "The", "values", "are", "STANDARD", "and", "OPTIMIZED", "This", "is", "an", "experimental", "feature", "that", "only", "makes", "sense", "in", "gauges", "that", "use", "an", "angleRange", ...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L3275-L3281
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setNeedleColor
public void setNeedleColor(final Color COLOR) { if (null == needleColor) { _needleColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { needleColor.set(COLOR); } }
java
public void setNeedleColor(final Color COLOR) { if (null == needleColor) { _needleColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { needleColor.set(COLOR); } }
[ "public", "void", "setNeedleColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "needleColor", ")", "{", "_needleColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "needleColor", ".", "set"...
Defines the color that will be used to colorize the needle of the radial gauges. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "needle", "of", "the", "radial", "gauges", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L3307-L3314
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setNeedleBorderColor
public void setNeedleBorderColor(final Color COLOR) { if (null == needleBorderColor) { _needleBorderColor = null == COLOR ? Color.TRANSPARENT : COLOR; fireUpdateEvent(REDRAW_EVENT); } else { needleBorderColor.set(COLOR); } }
java
public void setNeedleBorderColor(final Color COLOR) { if (null == needleBorderColor) { _needleBorderColor = null == COLOR ? Color.TRANSPARENT : COLOR; fireUpdateEvent(REDRAW_EVENT); } else { needleBorderColor.set(COLOR); } }
[ "public", "void", "setNeedleBorderColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "needleBorderColor", ")", "{", "_needleBorderColor", "=", "null", "==", "COLOR", "?", "Color", ".", "TRANSPARENT", ":", "COLOR", ";", "fireUpdateEvent"...
Defines the color that will be used to colorize the border of the needle. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "border", "of", "the", "needle", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L3338-L3345
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setBarBorderColor
public void setBarBorderColor(final Color COLOR) { if (null == barBorderColor) { _barBorderColor = null == COLOR ? Color.TRANSPARENT : COLOR; fireUpdateEvent(REDRAW_EVENT); } else { barBorderColor.set(COLOR); } }
java
public void setBarBorderColor(final Color COLOR) { if (null == barBorderColor) { _barBorderColor = null == COLOR ? Color.TRANSPARENT : COLOR; fireUpdateEvent(REDRAW_EVENT); } else { barBorderColor.set(COLOR); } }
[ "public", "void", "setBarBorderColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "barBorderColor", ")", "{", "_barBorderColor", "=", "null", "==", "COLOR", "?", "Color", ".", "TRANSPARENT", ":", "COLOR", ";", "fireUpdateEvent", "(", ...
Defines the color that will be used to colorize the border of the bar. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "border", "of", "the", "bar", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L3405-L3412
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setLcdFont
public void setLcdFont(final LcdFont FONT) { if (null == lcdFont) { _lcdFont = null == FONT ? LcdFont.DIGITAL_BOLD : FONT; fireUpdateEvent(RESIZE_EVENT); } else { lcdFont.set(FONT); } }
java
public void setLcdFont(final LcdFont FONT) { if (null == lcdFont) { _lcdFont = null == FONT ? LcdFont.DIGITAL_BOLD : FONT; fireUpdateEvent(RESIZE_EVENT); } else { lcdFont.set(FONT); } }
[ "public", "void", "setLcdFont", "(", "final", "LcdFont", "FONT", ")", "{", "if", "(", "null", "==", "lcdFont", ")", "{", "_lcdFont", "=", "null", "==", "FONT", "?", "LcdFont", ".", "DIGITAL_BOLD", ":", "FONT", ";", "fireUpdateEvent", "(", "RESIZE_EVENT", ...
Defines the font that will be used to visualize the LCD value if the gauge has a LCD display. The values are STANDARD, LCD, SLIM, DIGITAL_BOLD, ELEKTRA @param FONT
[ "Defines", "the", "font", "that", "will", "be", "used", "to", "visualize", "the", "LCD", "value", "if", "the", "gauge", "has", "a", "LCD", "display", ".", "The", "values", "are", "STANDARD", "LCD", "SLIM", "DIGITAL_BOLD", "ELEKTRA" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L3528-L3535
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setLedColor
public void setLedColor(final Color COLOR) { if (null == ledColor) { _ledColor = null == COLOR ? Color.RED : COLOR; fireUpdateEvent(REDRAW_EVENT); } else { ledColor.set(COLOR); } }
java
public void setLedColor(final Color COLOR) { if (null == ledColor) { _ledColor = null == COLOR ? Color.RED : COLOR; fireUpdateEvent(REDRAW_EVENT); } else { ledColor.set(COLOR); } }
[ "public", "void", "setLedColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "ledColor", ")", "{", "_ledColor", "=", "null", "==", "COLOR", "?", "Color", ".", "RED", ":", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ...
Defines the color that will be used to visualize the LED of the gauge if it has one. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "visualize", "the", "LED", "of", "the", "gauge", "if", "it", "has", "one", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L3564-L3571
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setSubTitleColor
public void setSubTitleColor(final Color COLOR) { if (null == subTitleColor) { _subTitleColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { subTitleColor.set(COLOR); } }
java
public void setSubTitleColor(final Color COLOR) { if (null == subTitleColor) { _subTitleColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { subTitleColor.set(COLOR); } }
[ "public", "void", "setSubTitleColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "subTitleColor", ")", "{", "_subTitleColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "subTitleColor", ".",...
Defines the color that will be used to colorize the subTitle of the gauge. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "subTitle", "of", "the", "gauge", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L3671-L3678
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setAverageColor
public void setAverageColor(final Color COLOR) { if (null == averageColor) { _averageColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { averageColor.set(COLOR); } }
java
public void setAverageColor(final Color COLOR) { if (null == averageColor) { _averageColor = COLOR; fireUpdateEvent(REDRAW_EVENT); } else { averageColor.set(COLOR); } }
[ "public", "void", "setAverageColor", "(", "final", "Color", "COLOR", ")", "{", "if", "(", "null", "==", "averageColor", ")", "{", "_averageColor", "=", "COLOR", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "averageColor", ".", "...
Defines the color that will be used to colorize the average indicator of the gauge. @param COLOR
[ "Defines", "the", "color", "that", "will", "be", "used", "to", "colorize", "the", "average", "indicator", "of", "the", "gauge", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L3803-L3810
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setAreaTextVisible
public void setAreaTextVisible(final boolean VISIBLE) { if (null == areaTextVisible) { _areaTextVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { areaTextVisible.set(VISIBLE); } }
java
public void setAreaTextVisible(final boolean VISIBLE) { if (null == areaTextVisible) { _areaTextVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { areaTextVisible.set(VISIBLE); } }
[ "public", "void", "setAreaTextVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "areaTextVisible", ")", "{", "_areaTextVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "areaTextVi...
Defines if the text of the areas should be drawn inside the areas. @param VISIBLE
[ "Defines", "if", "the", "text", "of", "the", "areas", "should", "be", "drawn", "inside", "the", "areas", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L4193-L4200
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setAreaIconsVisible
public void setAreaIconsVisible(final boolean VISIBLE) { if (null == areaIconsVisible) { _areaIconsVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { areaIconsVisible.set(VISIBLE); } }
java
public void setAreaIconsVisible(final boolean VISIBLE) { if (null == areaIconsVisible) { _areaIconsVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { areaIconsVisible.set(VISIBLE); } }
[ "public", "void", "setAreaIconsVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "areaIconsVisible", ")", "{", "_areaIconsVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", "areaIco...
Defines if the icon of the areas should be drawn inside the areas. @param VISIBLE
[ "Defines", "if", "the", "icon", "of", "the", "areas", "should", "be", "drawn", "inside", "the", "areas", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L4225-L4232
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setTickMarkSectionsVisible
public void setTickMarkSectionsVisible(final boolean VISIBLE) { if (null == tickMarkSectionsVisible) { _tickMarkSectionsVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { tickMarkSectionsVisible.set(VISIBLE); } }
java
public void setTickMarkSectionsVisible(final boolean VISIBLE) { if (null == tickMarkSectionsVisible) { _tickMarkSectionsVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { tickMarkSectionsVisible.set(VISIBLE); } }
[ "public", "void", "setTickMarkSectionsVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "tickMarkSectionsVisible", ")", "{", "_tickMarkSectionsVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "els...
Defines if the tickmark sections should be used to colorize the tickmarks. @param VISIBLE
[ "Defines", "if", "the", "tickmark", "sections", "should", "be", "used", "to", "colorize", "the", "tickmarks", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L4289-L4296
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setTickLabelSectionsVisible
public void setTickLabelSectionsVisible(final boolean VISIBLE) { if (null == tickLabelSectionsVisible) { _tickLabelSectionsVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { tickLabelSectionsVisible.set(VISIBLE); } }
java
public void setTickLabelSectionsVisible(final boolean VISIBLE) { if (null == tickLabelSectionsVisible) { _tickLabelSectionsVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { tickLabelSectionsVisible.set(VISIBLE); } }
[ "public", "void", "setTickLabelSectionsVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "tickLabelSectionsVisible", ")", "{", "_tickLabelSectionsVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "...
Defines if the ticklabel sections should be used to colorize the ticklabels. @param VISIBLE
[ "Defines", "if", "the", "ticklabel", "sections", "should", "be", "used", "to", "colorize", "the", "ticklabels", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L4321-L4328
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMarkersVisible
public void setMarkersVisible(final boolean VISIBLE) { if (null == markersVisible) { _markersVisible = VISIBLE; fireUpdateEvent(VISIBILITY_EVENT); } else { markersVisible.set(VISIBLE); } }
java
public void setMarkersVisible(final boolean VISIBLE) { if (null == markersVisible) { _markersVisible = VISIBLE; fireUpdateEvent(VISIBILITY_EVENT); } else { markersVisible.set(VISIBLE); } }
[ "public", "void", "setMarkersVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "markersVisible", ")", "{", "_markersVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "VISIBILITY_EVENT", ")", ";", "}", "else", "{", "markersVi...
Defines if the markers should be drawn @param VISIBLE
[ "Defines", "if", "the", "markers", "should", "be", "drawn" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L4351-L4358
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setOnlyFirstAndLastTickLabelVisible
public void setOnlyFirstAndLastTickLabelVisible(final boolean VISIBLE) { if (null == onlyFirstAndLastTickLabelVisible) { _onlyFirstAndLastTickLabelVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { onlyFirstAndLastTickLabelVisible.set(VISIBLE); } }
java
public void setOnlyFirstAndLastTickLabelVisible(final boolean VISIBLE) { if (null == onlyFirstAndLastTickLabelVisible) { _onlyFirstAndLastTickLabelVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { onlyFirstAndLastTickLabelVisible.set(VISIBLE); } }
[ "public", "void", "setOnlyFirstAndLastTickLabelVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "onlyFirstAndLastTickLabelVisible", ")", "{", "_onlyFirstAndLastTickLabelVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ...
Defines if only the first and the last ticklabel will be drawn. Sometimes this could be useful if a gauge should for example only should show 0 and 1000. @param VISIBLE
[ "Defines", "if", "only", "the", "first", "and", "the", "last", "ticklabel", "will", "be", "drawn", ".", "Sometimes", "this", "could", "be", "useful", "if", "a", "gauge", "should", "for", "example", "only", "should", "show", "0", "and", "1000", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L4417-L4424
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMajorTickMarksVisible
public void setMajorTickMarksVisible(final boolean VISIBLE) { if (null == majorTickMarksVisible) { _majorTickMarksVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { majorTickMarksVisible.set(VISIBLE); } }
java
public void setMajorTickMarksVisible(final boolean VISIBLE) { if (null == majorTickMarksVisible) { _majorTickMarksVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { majorTickMarksVisible.set(VISIBLE); } }
[ "public", "void", "setMajorTickMarksVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "majorTickMarksVisible", ")", "{", "_majorTickMarksVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", ...
Defines if the major tickmarks should be drawn If set to false and minorTickmarks == true, a minor tickmark will be drawn instead of the major tickmark. @param VISIBLE
[ "Defines", "if", "the", "major", "tickmarks", "should", "be", "drawn", "If", "set", "to", "false", "and", "minorTickmarks", "==", "true", "a", "minor", "tickmark", "will", "be", "drawn", "instead", "of", "the", "major", "tickmark", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L4451-L4458
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setMinorTickMarksVisible
public void setMinorTickMarksVisible(final boolean VISIBLE) { if (null == minorTickMarksVisible) { _minorTickMarksVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { minorTickMarksVisible.set(VISIBLE); } }
java
public void setMinorTickMarksVisible(final boolean VISIBLE) { if (null == minorTickMarksVisible) { _minorTickMarksVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { minorTickMarksVisible.set(VISIBLE); } }
[ "public", "void", "setMinorTickMarksVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "minorTickMarksVisible", ")", "{", "_minorTickMarksVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", ...
Defines if the minor tickmarks should be drawn @param VISIBLE
[ "Defines", "if", "the", "minor", "tickmarks", "should", "be", "drawn" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L4508-L4515
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setTickMarkRingVisible
public void setTickMarkRingVisible(final boolean VISIBLE) { if (null == tickMarkRingVisible) { _tickMarkRingVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { tickMarkRingVisible.set(VISIBLE); } }
java
public void setTickMarkRingVisible(final boolean VISIBLE) { if (null == tickMarkRingVisible) { _tickMarkRingVisible = VISIBLE; fireUpdateEvent(REDRAW_EVENT); } else { tickMarkRingVisible.set(VISIBLE); } }
[ "public", "void", "setTickMarkRingVisible", "(", "final", "boolean", "VISIBLE", ")", "{", "if", "(", "null", "==", "tickMarkRingVisible", ")", "{", "_tickMarkRingVisible", "=", "VISIBLE", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "else", "{", ...
Defines if an additional ring should be drawn that "connects" the tick marks. @param VISIBLE
[ "Defines", "if", "an", "additional", "ring", "should", "be", "drawn", "that", "connects", "the", "tick", "marks", "." ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L4539-L4546
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setOrientation
public void setOrientation(final Orientation ORIENTATION) { if (null == orientation) { _orientation = ORIENTATION; fireUpdateEvent(RESIZE_EVENT); } else { orientation.set(ORIENTATION); } }
java
public void setOrientation(final Orientation ORIENTATION) { if (null == orientation) { _orientation = ORIENTATION; fireUpdateEvent(RESIZE_EVENT); } else { orientation.set(ORIENTATION); } }
[ "public", "void", "setOrientation", "(", "final", "Orientation", "ORIENTATION", ")", "{", "if", "(", "null", "==", "orientation", ")", "{", "_orientation", "=", "ORIENTATION", ";", "fireUpdateEvent", "(", "RESIZE_EVENT", ")", ";", "}", "else", "{", "orientatio...
Defines the orientation of the control. This feature will only be used in the BulletChartSkin and LinearSkin. Values are HORIZONTAL and VERTICAL @param ORIENTATION
[ "Defines", "the", "orientation", "of", "the", "control", ".", "This", "feature", "will", "only", "be", "used", "in", "the", "BulletChartSkin", "and", "LinearSkin", ".", "Values", "are", "HORIZONTAL", "and", "VERTICAL" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L4811-L4818
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setCustomTickLabelsEnabled
public void setCustomTickLabelsEnabled(final boolean ENABLED) { if (null == customTickLabelsEnabled) { _customTickLabelsEnabled = ENABLED; fireUpdateEvent(REDRAW_EVENT); } else { customTickLabelsEnabled.set(ENABLED); } }
java
public void setCustomTickLabelsEnabled(final boolean ENABLED) { if (null == customTickLabelsEnabled) { _customTickLabelsEnabled = ENABLED; fireUpdateEvent(REDRAW_EVENT); } else { customTickLabelsEnabled.set(ENABLED); } }
[ "public", "void", "setCustomTickLabelsEnabled", "(", "final", "boolean", "ENABLED", ")", "{", "if", "(", "null", "==", "customTickLabelsEnabled", ")", "{", "_customTickLabelsEnabled", "=", "ENABLED", ";", "fireUpdateEvent", "(", "REDRAW_EVENT", ")", ";", "}", "els...
Defines if custom ticklabels should be used instead of the automatically calculated ones. This could be useful for gauges like a compass where you need "N", "E", "S" and "W" instead of numbers. @param ENABLED
[ "Defines", "if", "custom", "ticklabels", "should", "be", "used", "instead", "of", "the", "automatically", "calculated", "ones", ".", "This", "could", "be", "useful", "for", "gauges", "like", "a", "compass", "where", "you", "need", "N", "E", "S", "and", "W"...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L4925-L4932
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.addCustomTickLabel
public void addCustomTickLabel(final String TICK_LABEL) { if (null == TICK_LABEL) return; if (!customTickLabels.contains(TICK_LABEL)) customTickLabels.add(TICK_LABEL); fireUpdateEvent(REDRAW_EVENT); }
java
public void addCustomTickLabel(final String TICK_LABEL) { if (null == TICK_LABEL) return; if (!customTickLabels.contains(TICK_LABEL)) customTickLabels.add(TICK_LABEL); fireUpdateEvent(REDRAW_EVENT); }
[ "public", "void", "addCustomTickLabel", "(", "final", "String", "TICK_LABEL", ")", "{", "if", "(", "null", "==", "TICK_LABEL", ")", "return", ";", "if", "(", "!", "customTickLabels", ".", "contains", "(", "TICK_LABEL", ")", ")", "customTickLabels", ".", "add...
Adds the given String to the list of custom ticklabels @param TICK_LABEL
[ "Adds", "the", "given", "String", "to", "the", "list", "of", "custom", "ticklabels" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L4973-L4977
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.removeCustomTickLabel
public void removeCustomTickLabel(final String TICK_LABEL) { if (null == TICK_LABEL) return; if (customTickLabels.contains(TICK_LABEL)) customTickLabels.remove(TICK_LABEL); fireUpdateEvent(REDRAW_EVENT); }
java
public void removeCustomTickLabel(final String TICK_LABEL) { if (null == TICK_LABEL) return; if (customTickLabels.contains(TICK_LABEL)) customTickLabels.remove(TICK_LABEL); fireUpdateEvent(REDRAW_EVENT); }
[ "public", "void", "removeCustomTickLabel", "(", "final", "String", "TICK_LABEL", ")", "{", "if", "(", "null", "==", "TICK_LABEL", ")", "return", ";", "if", "(", "customTickLabels", ".", "contains", "(", "TICK_LABEL", ")", ")", "customTickLabels", ".", "remove"...
Removes the given String from the list of custom ticklabels @param TICK_LABEL
[ "Removes", "the", "given", "String", "from", "the", "list", "of", "custom", "ticklabels" ]
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L4983-L4987
train
HanSolo/Medusa
src/main/java/eu/hansolo/medusa/Gauge.java
Gauge.setCustomTickLabelFontSize
public void setCustomTickLabelFontSize(final double SIZE) { if (null == customTickLabelFontSize) { _customTickLabelFontSize = Helper.clamp(0.0, 72.0, SIZE); fireUpdateEvent(REDRAW_EVENT); } else { customTickLabelFontSize.set(SIZE); } }
java
public void setCustomTickLabelFontSize(final double SIZE) { if (null == customTickLabelFontSize) { _customTickLabelFontSize = Helper.clamp(0.0, 72.0, SIZE); fireUpdateEvent(REDRAW_EVENT); } else { customTickLabelFontSize.set(SIZE); } }
[ "public", "void", "setCustomTickLabelFontSize", "(", "final", "double", "SIZE", ")", "{", "if", "(", "null", "==", "customTickLabelFontSize", ")", "{", "_customTickLabelFontSize", "=", "Helper", ".", "clamp", "(", "0.0", ",", "72.0", ",", "SIZE", ")", ";", "...
Defines the custom font size. The default font size is 18px at a size of 250px. This value will be used to calculate the current font size for the ticklabels when scaling. @param SIZE
[ "Defines", "the", "custom", "font", "size", ".", "The", "default", "font", "size", "is", "18px", "at", "a", "size", "of", "250px", ".", "This", "value", "will", "be", "used", "to", "calculate", "the", "current", "font", "size", "for", "the", "ticklabels"...
1321e4925dcde659028d4b296e49e316494c114c
https://github.com/HanSolo/Medusa/blob/1321e4925dcde659028d4b296e49e316494c114c/src/main/java/eu/hansolo/medusa/Gauge.java#L5011-L5018
train