Android Room library error: Cannot find getter for field

Tags: ,



I get this error but I couldn’t find any solution. I tried many things but still I’m getting this code.

My code is: https://justpaste.it/4di3y

The error:

error: Cannot find getter for field. ( private Long fie_id )

How I can fix it?

Answer

Instead of

public Long getId() {
    return fie_id;
}

public void setId(Long id) {
    this.fie_id = id;
}

Do

public Long getFie_id() {
    return fie_id;
}

public void setFie_id(Long fie_id) {
    this.fie_id = fie_id;
}


Source: stackoverflow