forked from deephaven/deephaven-core
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support arbitrary types in partitioning columns (deephaven#885)
- Loading branch information
1 parent
764c41c
commit e0f2166
Showing
53 changed files
with
1,069 additions
and
387 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 12 additions & 9 deletions
21
DB/src/main/java/io/deephaven/db/v2/sources/regioned/ColumnRegion.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,37 +1,40 @@ | ||
package io.deephaven.db.v2.sources.regioned; | ||
|
||
import io.deephaven.db.v2.sources.Releasable; | ||
import io.deephaven.db.v2.sources.chunk.Attributes; | ||
import io.deephaven.db.v2.sources.chunk.Attributes.Any; | ||
import io.deephaven.db.v2.sources.chunk.WritableChunk; | ||
import io.deephaven.db.v2.sources.chunk.page.Page; | ||
import io.deephaven.util.annotations.FinalDefault; | ||
import org.jetbrains.annotations.NotNull; | ||
|
||
public interface ColumnRegion<ATTR extends Attributes.Any> extends Page<ATTR>, Releasable { | ||
public interface ColumnRegion<ATTR extends Any> extends Page<ATTR>, Releasable { | ||
|
||
long REGION_MASK = RegionedPageStore.REGION_MASK; | ||
|
||
@Override @FinalDefault | ||
@Override | ||
@FinalDefault | ||
default long mask() { | ||
return REGION_MASK; | ||
} | ||
|
||
@Override @FinalDefault | ||
@Override | ||
@FinalDefault | ||
default long firstRowOffset() { | ||
return 0; | ||
} | ||
|
||
abstract class Null<ATTR extends Attributes.Any> | ||
abstract class Null<ATTR extends Any> | ||
implements ColumnRegion<ATTR>, WithDefaultsForRepeatingValues<ATTR> { | ||
|
||
Null() {} | ||
Null() { | ||
} | ||
|
||
@Override | ||
public void fillChunkAppend(@NotNull FillContext context, @NotNull WritableChunk<? super ATTR> destination, int length) { | ||
int offset = destination.size(); | ||
public void fillChunkAppend(@NotNull final FillContext context, @NotNull final WritableChunk<? super ATTR> destination, final int length) { | ||
final int offset = destination.size(); | ||
|
||
destination.fillWithNullValue(offset, length); | ||
destination.setSize(offset + length); | ||
} | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.