I want to develop a library with a new idea for Android applications but I have problem. How can I call the method after another method?
for example...
Toast.makeText(context, "", Toast.LENGTH_SHORT).show();
my codes
MyClass class
public class MyClass {
public static MyClass A(){
return A();
}
public static void show(){
}
MainActivity Class
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
//It's normal
MyClass.A();
//if he wrote like this I want tell him error
MyClass.show();
//I want like this
MyClass.A().show();
}