Just declare it either as an interface, or a class that it sees that this class should implement the interface anyway. Depending on how you need it. but you need to specify instance variables like this.
private YourInterfaceName variablename; private ClassName variablename;
and then initiate them in the constructor.
Perhaps this tutorial will help you learn more about variables.
source share