-
-
Save MiraLak/1d2bf2d8e28bff7a3a98 to your computer and use it in GitHub Desktop.
Accelerometer to Cassandra REST Api
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
@Table | |
public class Acceleration { | |
@PrimaryKey | |
@NotNull | |
private UserTimestamp user_timestamp; | |
@Column | |
@NotNull | |
private Double x; | |
@Column | |
@NotNull | |
private Double y; | |
@Column | |
@NotNull | |
private Double z; | |
public Acceleration(AccelerartionModel accelerationModel) { | |
user_timestamp = new UserTimestamp(); | |
user_timestamp.setUser_id("TEST_USER"); | |
user_timestamp.setTimestamp(accelerationModel.getTimestamp()); | |
x = accelerationModel.getX(); | |
y = accelerationModel.getY(); | |
z = accelerationModel.getZ(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment