calling a service layer method to my presentation layer
- by Josepth Vodary
Ok I feel really dumb asking this but I seem to be missing something really simple here. I have the following code in a class in my service layer -
public Items getItems(String category, float amount, String color,
String type)
The code reads from a database and returns the results - I plan on placing it in a jframe. Nice and simple. But no matter how I call it from the jframe I get errors in eclipse that the code is wrong - either that their are illegal modifiers or such. So obviously I am calling it completely wrong, so my stupid question is how do you call that method into a jframe?
For example - if I try to call it this way:
public Items getItems();
I get told that getItems is an illegal parameter.
If I call this.. Items getItems(); I am told its undefined