delight-im / Android-DDP

[UNMAINTAINED] Meteor's Distributed Data Protocol (DDP) for clients on Android
Apache License 2.0
274 stars 54 forks source link

no method #8

Closed guoyoujin closed 9 years ago

guoyoujin commented 9 years ago

mMeteor.call("/auto", new ResultListener() {

        @Override
        public void onSuccess(String result) {
            Log.e("TAG", "result=========="+result);

        }

        @Override
        public void onError(String error, String reason, String details) {
            // TODO Auto-generated method stub
            Log.e("TAG", "error=========="+error);
            Log.e("TAG", "reason=========="+reason);
            Log.e("TAG", "details=========="+details);

        }
    });

why reason==========Method not found error==========404

ocram commented 9 years ago

Well, as the error message explains, you probably didn't implement the auto on the server. Did you?

Moreover, the slash at the beginning is only needed when accessing collections, e.g. mMeteor.call("/my-collection/count");.

So you might change your code to mMeteor.call("auto", ...); and implement the auto method on the server. There's an example for that as well.

Does that help?

guoyoujin commented 9 years ago

Yes, I follow the steps you implement this feature, thank you