How do I customize the Generate toString()
function of eclipse (source> Generate toString ()) to print the path of a class?
For example I have the following entity that prints:
package com.etc.model;
@Entity
@Table(name="CLIENTE")
public class Cliente implements Serializable {
private static final long serialVersionUID = 1L;
@Id
@GeneratedValue(strategy=GenerationType.IDENTITY)
@Column(name="ID")
private int id;
@Override
public String toString() {
return "Cliente [id=" + id + "]";
}
How do I configure generate toString () to exit with the full path? In case:
@Override
public String toString() {
return "com.etc.model.Cliente [id=" + id + "]";
}
I use the Neon.3 version
Thank you guys for the feedback, but I'll express myself better. I need to configure Generate ToString to generate the full path code (which is displayed in package) in the java class.
In the example shown above it generates showing the class name Client:
@Override
public String toString() {
return "Cliente [id=" + id + "]";
}
How to customize it to generate the code with the full path (the path is shown in the package line):
@Override
public String toString() {
return "com.etc.model.Cliente [id=" + id + "]";
}
See the full path with the name: com.etc.model.Customer It looks like I have to create a new format template, I have analyzed it through #