Package com.illumon.iris.db.v2.utils
Class KeyedArrayBackedMutableTable
java.lang.Object
com.illumon.util.referencecounting.ReferenceCounted
com.illumon.iris.db.util.liveness.ReferenceCountedLivenessNode
com.illumon.iris.db.util.liveness.LivenessArtifact
com.illumon.iris.db.v2.BaseTable
com.illumon.iris.db.v2.QueryTable
com.illumon.iris.db.v2.UpdatableTable
com.illumon.iris.db.v2.utils.KeyedArrayBackedMutableTable
- All Implemented Interfaces:
com.fishlib.base.log.LogOutputAppendable
,LiveTable
,NotificationQueue.Dependency
,Deflatable<Table>
,Table
,LivenessManager
,LivenessNode
,LivenessReferent
,LongSizedDataStructure
,DynamicNode
,DynamicTable
,NotificationStepReceiver
,NotificationStepSource
,SystemicObject
,Serializable
,Runnable
An in-memory table that has keys for each row, which can be updated on the LTM.
This is used to implement in-memory editable table columns from web plugins.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class com.illumon.iris.db.v2.UpdatableTable
UpdatableTable.IndexChangeRecorder, UpdatableTable.Updater
Nested classes/interfaces inherited from class com.illumon.iris.db.v2.QueryTable
QueryTable.FilteredTable, QueryTable.MemoizableOperation, QueryTable.Operation
Nested classes/interfaces inherited from class com.illumon.iris.db.v2.BaseTable
BaseTable.CopyAttributeOperation, BaseTable.ListenerImpl, BaseTable.ShiftAwareListenerImpl, BaseTable.SwapListenerFactory<T extends SwapListenerBase>
Nested classes/interfaces inherited from interface com.illumon.iris.db.tables.Table
Table.AsOfMatchRule, Table.GroupStrategy, Table.RenameFunction
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final ObjectArraySource<?>[]
protected final com.illumon.iris.web.shared.data.InputTableDefinition
Fields inherited from class com.illumon.iris.db.v2.QueryTable
modifiedColumnSet, USE_CHUNKED_CROSS_JOIN, USE_UNTRACKED_LASTBY_FOR_AUTOMATED_FILTERS
Fields inherited from class com.illumon.iris.db.v2.BaseTable
attributes, definition, PRINT_SERIALIZED_UPDATE_OVERLAPS, sharedAttributes
Fields inherited from interface com.illumon.iris.db.v2.NotificationStepReceiver
NULL_NOTIFICATION_STEP
Fields inherited from interface com.illumon.iris.db.tables.Table
ACL_ATTRIBUTE, ADD_ONLY_TABLE_ATTRIBUTE, COLUMN_DESCRIPTIONS_ATTRIBUTE, COLUMN_RENDERERS_ATTRIBUTE, CUSTOM_ACTIONS_ATTRIBUTE, DO_NOT_MAKE_REMOTE_ATTRIBUTE, EMPTY_SOURCE_TABLE_ATTRIBUTE, FILTERABLE_COLUMNS_ATTRIBUTE, HIERARCHICAL_CHILDREN_TABLE_MAP_ATTRIBUTE, HIERARCHICAL_SOURCE_INFO_ATTRIBUTE, HIERARCHICAL_SOURCE_TABLE_ATTRIBUTE, INPUT_TABLE_ATTRIBUTE, KEY_COLUMNS_ATTRIBUTE, LAYOUT_HINTS_ATTRIBUTE, MERGED_TABLE_ATTRIBUTE, NON_DISPLAY_TABLE, PLUGIN_NAME, PREDEFINED_ROLLUP_ATTRIBUTE, PREEMPTIVE_VIEWPORT_TYPE, PREPARED_RLL_ATTRIBUTE, PREVIEW_PARENT_TABLE, REVERSE_LOOKUP_ATTRIBUTE, ROLLUP_LEAF_ATTRIBUTE, SNAPSHOT_VIEWPORT_TYPE, SORTABLE_COLUMNS_ATTRIBUTE, SORTED_COLUMNS_ATTRIBUTE, SYSTEMIC_TABLE_ATTRIBUTE, TABLE_DESCRIPTION_ATTRIBUTE, TOTALS_TABLE_ATTRIBUTE, TREE_TABLE_FILTER_REVERSE_LOOKUP_ATTRIBUTE, UNIQUE_KEYS_ATTRIBUTE, UNTRACKED_LASTBY_TABLE_ATTRIBUTE, VIEWPORT_TYPE_ATTRIBUTE, ZERO_LENGTH_TABLE_ARRAY
-
Method Summary
Modifier and TypeMethodDescriptionprotected String
static KeyedArrayBackedMutableTable
make
(TableDefinition definition, String... keyColumnNames) Create an empty KeyedArrayBackedMutableTable.static KeyedArrayBackedMutableTable
Create an empty KeyedArrayBackedMutableTable.static KeyedArrayBackedMutableTable
Create an empty KeyedArrayBackedMutableTable.static KeyedArrayBackedMutableTable
Create an empty KeyedArrayBackedMutableTable.protected static Map<String,
? extends ArrayBackedColumnSource<?>> makeColumnSourceMap
(TableDefinition definition) protected void
processPendingDelete
(Table table, UpdatableTable.IndexChangeRecorder indexChangeRecorder) protected void
processPendingTable
(Table table, boolean allowEdits, UpdatableTable.IndexChangeRecorder indexChangeRecorder, Consumer<String> errorNotifier) void
refresh()
Refresh this LiveTable.com.illumon.iris.db.v2.utils.BaseArrayBackedMutableTable
setDescription
(String newDescription) Methods inherited from class com.illumon.iris.db.v2.UpdatableTable
destroy, doNotifyListeners, refresh
Methods inherited from class com.illumon.iris.db.v2.QueryTable
absSumBy, aj, apply, applyToAllBy, avgBy, by, byExternal, copy, copy, countBy, disableParallelWhereForThread, disableWriteReplace, dropColumns, enableWriteReplace, exactJoin, firstBy, flatten, getColumn, getColumnSource, getColumnSourceMap, getColumnSources, getDataIndex, getIndex, getModifiedColumnSetForUpdates, getRecord, getSubTable, getSubTable, head, headBy, headPct, isFlat, join, lastBy, lazyUpdate, leftJoin, maxBy, medianBy, memoizeResult, minBy, naturalJoin, newModifiedColumnSet, newModifiedColumnSetIdentityTransformer, newModifiedColumnSetIdentityTransformer, newModifiedColumnSetTransformer, preemptiveSnapshotTable, preemptiveUpdatesTable, preemptiveUpdatesTable, raj, releaseCachedResources, renameColumns, reverse, rollup, select, selectDistinct, setDataIndexProvider, setFlat, setMemoizeResults, silent, size, slice, snapshot, snapshotHistory, snapshotIncremental, sort, stdBy, sumBy, tail, tailBy, tailPct, treeTable, ungroup, update, updateBy, updateView, validateSelect, varBy, view, wavgBy, where, whereIn, wouldMatch, wsumBy
Methods inherited from class com.illumon.iris.db.v2.BaseTable
addParentReference, append, awaitUpdate, awaitUpdate, clearSortingRestrictions, copyAttributes, copyAttributes, createSwapListenerIfRefreshing, getAttribute, getAttributeNames, getAttributes, getDefinition, getDescription, getLastNotificationStep, getNotificationQueue, hasAttribute, initializeWithSnapshot, isAddOnly, isAddOnly, isFailed, isRefreshing, isSystemicObject, layoutHints, listenForDirectUpdates, listenForUpdates, listenForUpdates, markSystemic, notifyListeners, notifyListenersOnError, removeDirectUpdateListener, removeUpdateListener, removeUpdateListener, restrictSortTo, satisfied, setAttribute, setColumnRenderers, setLastNotificationStep, setRefreshing, setTotalsTable, shouldCopyAttribute, toString, withColumnDescription, withKeys, withTableDescription, withUniqueKeys
Methods inherited from class com.illumon.iris.db.util.liveness.LivenessArtifact
manageWithCurrentScope, unmanage, unmanage
Methods inherited from class com.illumon.iris.db.util.liveness.ReferenceCountedLivenessNode
dropReference, getWeakReference, initializeTransientFieldsForLiveness, onReferenceCountAtZero, tryManage, tryRetainReference
Methods inherited from class com.illumon.util.referencecounting.ReferenceCounted
decrementReferenceCount, incrementReferenceCount, resetReferenceCount, tryDecrementReferenceCount, tryIncrementReferenceCount
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface com.illumon.iris.db.v2.DynamicTable
listenForUpdates, newModifiedColumnSetTransformer, newModifiedColumnSetTransformer, notifyListeners
Methods inherited from interface com.illumon.iris.db.util.liveness.LivenessManager
manage, tryManage
Methods inherited from interface com.illumon.iris.db.util.liveness.LivenessReferent
dropReference, getReferentDescription, getWeakReference, retainReference, tryRetainReference
Methods inherited from interface com.illumon.iris.db.util.LongSizedDataStructure
intSize, intSize
Methods inherited from interface com.illumon.iris.db.tables.Table
absSumBy, absSumBy, absSumBy, aj, aj, aj, aj, aj, applyToAllBy, applyToAllBy, applyToAllBy, avgBy, avgBy, avgBy, by, by, by, by, by, by, byExternal, byteColumnIterator, characterColumnIterator, close, coalesce, columnIterator, countBy, countBy, countBy, dateTimeColumnAsNanos, dateTimeColumnAsNanos, deflate, deflate, doubleColumnIterator, dropColumnFormats, dropColumns, exactJoin, exactJoin, exactJoin, exactJoin, firstBy, firstBy, firstBy, floatColumnIterator, formatColumns, formatColumnWhere, formatRowWhere, getAttributes, getColumn, getColumns, getColumnSource, getMeta, getViewPort, hasColumns, hasColumns, headBy, headBy, integerColumnIterator, isEmpty, isLive, join, join, join, join, join, join, join, join, join, lastBy, lastBy, lastBy, layoutHints, lazyUpdate, lazyUpdate, leftJoin, leftJoin, leftJoin, leftJoin, leftJoin, longColumnIterator, maxBy, maxBy, maxBy, medianBy, medianBy, medianBy, minBy, minBy, minBy, moveColumns, moveColumns, moveDownColumns, moveUpColumns, naturalJoin, naturalJoin, naturalJoin, naturalJoin, preemptiveSnapshotTable, raj, raj, raj, raj, raj, renameAllColumns, renameColumns, renameColumns, rollup, rollup, rollup, rollup, rollup, rollup, rollup, select, select, select, selectDistinct, selectDistinct, selectDistinct, shortColumnIterator, sizeForInstrumentation, snapshot, snapshotIncremental, sort, sort, sortDescending, sortDescending, stdBy, stdBy, stdBy, subscribeToPreemptiveUpdates, sumBy, sumBy, sumBy, supportsPreemptiveSubscription, tailBy, tailBy, ungroup, ungroup, ungroup, ungroupAllBut, update, update, updateBy, updateBy, updateBy, updateBy, updateBy, updateView, updateView, validateSelect, varBy, varBy, varBy, view, view, wavgBy, wavgBy, wavgBy, where, where, where, whereIn, whereIn, whereIn, whereNotIn, whereNotIn, whereOneOf, whereOneOf, whereOneOf, withColumnDescription, wouldMatch, wsumBy, wsumBy, wsumBy
-
Field Details
-
arrayValueSources
-
inputTableDefinition
protected final com.illumon.iris.web.shared.data.InputTableDefinition inputTableDefinition
-
-
Method Details
-
make
public static KeyedArrayBackedMutableTable make(@NotNull TableDefinition definition, String... keyColumnNames) Create an empty KeyedArrayBackedMutableTable.- Parameters:
definition
- the definition of the table to createkeyColumnNames
- the name of the key columns- Returns:
- an empty KeyedArrayBackedMutableTable with the given definition and key columns
-
make
public static KeyedArrayBackedMutableTable make(@NotNull TableDefinition definition, Map<String, Object[]> enumValues, String... keyColumnNames) Create an empty KeyedArrayBackedMutableTable.- Parameters:
definition
- the definition of the table to createenumValues
- a map of column names to enumeration valueskeyColumnNames
- the name of the key columns- Returns:
- an empty KeyedArrayBackedMutableTable with the given definition and key columns
-
make
Create an empty KeyedArrayBackedMutableTable. The initialTable is processed in order, so if there are duplicate keys only the last row is reflected in the output.- Parameters:
initialTable
- the initial values to copy into the KeyedArrayBackedMutableTablekeyColumnNames
- the name of the key columns- Returns:
- an empty KeyedArrayBackedMutableTable with the given definition and key columns
-
make
public static KeyedArrayBackedMutableTable make(Table initialTable, Map<String, Object[]> enumValues, String... keyColumnNames) Create an empty KeyedArrayBackedMutableTable. The initialTable is processed in order, so if there are duplicate keys only the last row is reflected in the output.- Parameters:
initialTable
- the initial values to copy into the KeyedArrayBackedMutableTableenumValues
- a map of column names to enumeration valueskeyColumnNames
- the name of the key columns- Returns:
- an empty KeyedArrayBackedMutableTable with the given definition and key columns
-
processPendingTable
protected void processPendingTable(Table table, boolean allowEdits, UpdatableTable.IndexChangeRecorder indexChangeRecorder, Consumer<String> errorNotifier) -
processPendingDelete
protected void processPendingDelete(Table table, UpdatableTable.IndexChangeRecorder indexChangeRecorder) -
getDefaultDescription
-
makeColumnSourceMap
protected static Map<String,? extends ArrayBackedColumnSource<?>> makeColumnSourceMap(TableDefinition definition) -
setDescription
public com.illumon.iris.db.v2.utils.BaseArrayBackedMutableTable setDescription(String newDescription) -
refresh
public void refresh()Description copied from interface:LiveTable
Refresh this LiveTable.- Specified by:
refresh
in interfaceLiveTable
- Overrides:
refresh
in classUpdatableTable
-