59 lines
1.6 KiB
Java
59 lines
1.6 KiB
Java
package com.example.myapplication.model;
|
|
|
|
import androidx.room.Entity;
|
|
import androidx.room.PrimaryKey;
|
|
|
|
|
|
@Entity(tableName = "images")
|
|
public class ImageEntity {
|
|
@PrimaryKey(autoGenerate = true)
|
|
public int id;
|
|
public String path;
|
|
public long time;
|
|
public double latitude;
|
|
public double longitude;
|
|
public double altitude;
|
|
public String user;
|
|
public String audioPath;
|
|
public int blade;
|
|
public String unit;
|
|
public String unitName;
|
|
public String project;
|
|
public boolean b;
|
|
public String temperature="0"; // 温度
|
|
public String humidity="0"; // 湿度
|
|
public String weather="0"; // 天气状况
|
|
public String imageSource="-1";
|
|
public String partid;
|
|
public ImageEntity(String path, long time, double latitude, double longitude, double altitude, String user, String audioPath, String project, String unit, int blade, boolean b,String unitName,String temperature,String humidity,String weather,String imageSource,String partid) {
|
|
|
|
this.path = path;
|
|
this.time = time;
|
|
this.latitude = latitude;
|
|
this.longitude = longitude;
|
|
this.altitude = altitude;
|
|
this.user = user;
|
|
this.audioPath = audioPath;
|
|
this.project=project;
|
|
this.unit=unit;
|
|
this.blade=blade;
|
|
this.b=b;
|
|
this.weather=weather;
|
|
this.temperature=temperature;
|
|
this.humidity=humidity;
|
|
this.unitName=unitName;
|
|
this.imageSource=imageSource;
|
|
this.partid=partid;
|
|
}
|
|
|
|
|
|
|
|
// 构造方法
|
|
|
|
|
|
|
|
}
|
|
|
|
// ImageDao.java
|
|
|