public final class Util extends Object
public static <K,V> Map.Entry<K,V> entry(K k, V v)
Map.Entry
with the given key and value.public static <K,V> PredicateEx<EventJournalMapEvent<K,V>> mapPutEvents()
Sources.mapJournal(java.lang.String, com.hazelcast.jet.pipeline.JournalInitialPosition, com.hazelcast.function.FunctionEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>, ? extends T>, com.hazelcast.function.PredicateEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>>)
and
Sources.remoteMapJournal(java.lang.String, com.hazelcast.client.config.ClientConfig, com.hazelcast.jet.pipeline.JournalInitialPosition, com.hazelcast.function.FunctionEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>, ? extends T>, com.hazelcast.function.PredicateEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>>)
that passes only
ADDED
and UPDATED
events.public static <K,V> PredicateEx<EventJournalCacheEvent<K,V>> cachePutEvents()
Sources.cacheJournal(java.lang.String, com.hazelcast.jet.pipeline.JournalInitialPosition, com.hazelcast.function.FunctionEx<? super com.hazelcast.cache.EventJournalCacheEvent<K, V>, ? extends T>, com.hazelcast.function.PredicateEx<? super com.hazelcast.cache.EventJournalCacheEvent<K, V>>)
and
Sources.remoteCacheJournal(java.lang.String, com.hazelcast.client.config.ClientConfig, com.hazelcast.jet.pipeline.JournalInitialPosition, com.hazelcast.function.FunctionEx<? super com.hazelcast.cache.EventJournalCacheEvent<K, V>, ? extends T>, com.hazelcast.function.PredicateEx<? super com.hazelcast.cache.EventJournalCacheEvent<K, V>>)
that passes only
CREATED
and UPDATED
events.public static <K,V> FunctionEx<EventJournalMapEvent<K,V>,Map.Entry<K,V>> mapEventToEntry()
EventJournalMapEvent
to a
Map.Entry
using the event's new value as a value.Sources.mapJournal(java.lang.String, com.hazelcast.jet.pipeline.JournalInitialPosition, com.hazelcast.function.FunctionEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>, ? extends T>, com.hazelcast.function.PredicateEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>>)
,
Sources.remoteMapJournal(java.lang.String, com.hazelcast.client.config.ClientConfig, com.hazelcast.jet.pipeline.JournalInitialPosition, com.hazelcast.function.FunctionEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>, ? extends T>, com.hazelcast.function.PredicateEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>>)
public static <K,V> FunctionEx<EventJournalMapEvent<K,V>,V> mapEventNewValue()
EventJournalMapEvent
.Sources.mapJournal(java.lang.String, com.hazelcast.jet.pipeline.JournalInitialPosition, com.hazelcast.function.FunctionEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>, ? extends T>, com.hazelcast.function.PredicateEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>>)
,
Sources.remoteMapJournal(java.lang.String, com.hazelcast.client.config.ClientConfig, com.hazelcast.jet.pipeline.JournalInitialPosition, com.hazelcast.function.FunctionEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>, ? extends T>, com.hazelcast.function.PredicateEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>>)
public static <K,V> FunctionEx<EventJournalCacheEvent<K,V>,Map.Entry<K,V>> cacheEventToEntry()
EventJournalCacheEvent
to a
Map.Entry
using the event's new value as a value.Sources.cacheJournal(java.lang.String, com.hazelcast.jet.pipeline.JournalInitialPosition, com.hazelcast.function.FunctionEx<? super com.hazelcast.cache.EventJournalCacheEvent<K, V>, ? extends T>, com.hazelcast.function.PredicateEx<? super com.hazelcast.cache.EventJournalCacheEvent<K, V>>)
,
Sources.remoteCacheJournal(java.lang.String, com.hazelcast.client.config.ClientConfig, com.hazelcast.jet.pipeline.JournalInitialPosition, com.hazelcast.function.FunctionEx<? super com.hazelcast.cache.EventJournalCacheEvent<K, V>, ? extends T>, com.hazelcast.function.PredicateEx<? super com.hazelcast.cache.EventJournalCacheEvent<K, V>>)
public static <K,V> FunctionEx<EventJournalCacheEvent<K,V>,V> cacheEventNewValue()
EventJournalCacheEvent
.Sources.mapJournal(java.lang.String, com.hazelcast.jet.pipeline.JournalInitialPosition, com.hazelcast.function.FunctionEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>, ? extends T>, com.hazelcast.function.PredicateEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>>)
,
Sources.remoteMapJournal(java.lang.String, com.hazelcast.client.config.ClientConfig, com.hazelcast.jet.pipeline.JournalInitialPosition, com.hazelcast.function.FunctionEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>, ? extends T>, com.hazelcast.function.PredicateEx<? super com.hazelcast.map.EventJournalMapEvent<K, V>>)
@Nonnull public static String idToString(long id)
long
job or execution ID to a string representation.
Currently it is an unsigned 16-digit hex number.public static long idFromString(String str)
idToString(long)
.
The method is lenient: if the string doesn't match the structure of the
ID generated by idToString
or if the string is null, it will
return -1.
public static Path getFilePathOfClasspathResource(String resourcePath)
Path
that corresponds to it. This works only for resources that represent
files or directories on the local file system (i.e., the class loader
returns a file:
URL).
For example, if you have a project directory src/main/resources/python
, the files in it will become classpath
resources with the "python"
path prefix. Calling getFilePathOfClasspathResource("python")
will return the full path to
the above directory in the project.
resourcePath
- the pathname of the classpath resourcePath
pointing to the project directory corresponding to the
pathnameCopyright © 2023 Hazelcast, Inc.. All rights reserved.