public interface Insert extends BuildableQuery
Modifier and Type | Method and Description |
---|---|
Insert |
ifNotExists()
Adds an IF NOT EXISTS clause to this statement.
|
Insert |
usingTimestamp(BindMarker bindMarker)
Adds a USING TIMESTAMP clause to this statement with a bind marker.
|
Insert |
usingTimestamp(long timestamp)
Adds a USING TIMESTAMP clause to this statement with a literal value.
|
Insert |
usingTtl(BindMarker bindMarker)
Adds a
USING TTL clause to this statement with a bind marker. |
Insert |
usingTtl(int ttlInSeconds)
Adds a
USING TTL clause to this statement with a literal value. |
@NonNull Insert ifNotExists()
@NonNull Insert usingTimestamp(long timestamp)
If this method or usingTimestamp(BindMarker)
is called multiple times, the last
value is used.
@NonNull Insert usingTimestamp(@Nullable BindMarker bindMarker)
If this method or usingTimestamp(long)
is called multiple times, the last value is
used. Passing null
to this method removes any previous timestamp.
@NonNull Insert usingTtl(int ttlInSeconds)
USING TTL
clause to this statement with a literal value. Setting a value of
null
will remove the USING TTL
clause on this statement. Setting a value of
0
will insert the data with no TTL when the statement is executed, overriding any Table
TTL that might exist.
If this method or usingTtl(BindMarker)
is called multiple times, the value from
the last invocation is used.
ttlInSeconds
- Time, in seconds, the inserted data should live before expiring.@NonNull Insert usingTtl(@Nullable BindMarker bindMarker)
USING TTL
clause to this statement with a bind marker. Setting a value of null
will remove the USING TTL
clause on this statement. Binding a value of 0
will insert the data with no TTL when the statement is executed, overriding any Table TTL that
might exist.
If this method or usingTtl(int)
is called multiple times, the value from the last
invocation is used.
bindMarker
- A bind marker that is understood to be a value in seconds.Copyright © 2017–2020. All rights reserved.