sujinwen
2017-07-26 9a09d6bbed781afdc171297ea368cfd1ac25952f
VisitFace/DemoForBsk/app/src/main/java/cn/com/basic/face/discern/query/item/SurveillanceQueryItem.java
@@ -3,9 +3,12 @@
import android.graphics.Bitmap;
import java.io.ByteArrayOutputStream;
import java.util.Date;
import android.net.Uri;
import android.util.Base64;
import cn.com.basic.face.util.NativeImg;
public class SurveillanceQueryItem {
@@ -39,6 +42,30 @@
    private String height;
   private Uri localUri;
   private boolean surveillancePhotoSelected;
   private NativeImg nativeImg;
   private Date createTime;
    public static long initialSelectId = 1;
    private long idForSelect;
   private String surveillancePhoto;
   private int stTrackId;
   private String visitorType;
   private String authentication;
    public SurveillanceQueryItem() {
        if (initialSelectId > 10000) {
            initialSelectId = 1;
        }
        idForSelect = initialSelectId;
        initialSelectId++;
    }
   /**
    * Get 人员主键
@@ -180,11 +207,12 @@
    }
    public String getBase64Image() {
      ByteArrayOutputStream byteArrayOutputStream = new ByteArrayOutputStream();
      bitmap.compress(Bitmap.CompressFormat.JPEG, 100, byteArrayOutputStream);
      byte[] imageBytes = byteArrayOutputStream.toByteArray();
      String encodedImage = Base64.encodeToString(imageBytes, Base64.DEFAULT);
        return encodedImage;
//      ByteArrayOutputStream byteArrayOutputStream = new ByteArrayOutputStream();
//      bitmap.compress(Bitmap.CompressFormat.JPEG, 100, byteArrayOutputStream);
//      byte[] imageBytes = byteArrayOutputStream.toByteArray();
//      String encodedImage = Base64.encodeToString(imageBytes, Base64.DEFAULT);
//        return encodedImage;
      return "";
    }
    public void setBase64Image(String base64Image) {
@@ -206,4 +234,68 @@
   public void setLocalUri(Uri localUri) {
      this.localUri = localUri;
   }
   public boolean isSurveillancePhotoSelected() {
      return surveillancePhotoSelected;
   }
   public void setSurveillancePhotoSelected(boolean surveillancePhotoSelected) {
      this.surveillancePhotoSelected = surveillancePhotoSelected;
   }
   public NativeImg getNativeImg() {
      return nativeImg;
   }
   public void setNativeImg(NativeImg nativeImg) {
      this.nativeImg = nativeImg;
   }
   public Date getCreateTime() {
      return createTime;
   }
   public void setCreateTime(Date createTime) {
      this.createTime = createTime;
   }
    public long getIdForSelect() {
        return idForSelect;
    }
    public void setIdForSelect(long idForSelect) {
        this.idForSelect = idForSelect;
    }
   public String getSurveillancePhoto() {
      return surveillancePhoto;
   }
   public void setSurveillancePhoto(String surveillancePhoto) {
      this.surveillancePhoto = surveillancePhoto;
   }
   public int getStTrackId() {
      return stTrackId;
   }
   public void setStTrackId(int stTrackId) {
      this.stTrackId = stTrackId;
   }
   public String getVisitorType() {
      return visitorType;
   }
   public void setVisitorType(String visitorType) {
      this.visitorType = visitorType;
   }
   public String getAuthentication() {
      return authentication;
   }
   public void setAuthentication(String authentication) {
      this.authentication = authentication;
   }
}