How to implements fabric find friends

25 views Asked by At

how to implements fabric find fiends

i have successfully implemented uploading contacts and i got uploaded contacts numbers too .but i m unable to implement find friends and that's why i got nothing match contacts (where as i have registered users with application see implementation below) As i suspect ContactMatch(); never be called

codes

find.setOnClickListener(new View.OnClickListener() {
        @Override
        public void onClick(View view) {
            Digits.uploadContacts(CONTACT_UPLOAD_REQUEST);


        }
    });

    return view;

}

private static void ContactMatch() {

    //  progressDialog.show();


    Digits.findFriends(new ContactsCallback<Contacts>() {

        @Override
        public void success(Result<Contacts> result) {
            if (result.data.users != null) {
                Log.e("data", result.toString());
            }
        }

        @Override
        public void failure(TwitterException exception) {

            Log.e("failure", exception.toString());
        }
    });
}

public static class MyResultReceiver extends BroadcastReceiver {
    @Override
    public void onReceive(Context context, Intent intent) {
        if (ContactsUploadService.UPLOAD_COMPLETE.equals(intent.getAction())) {
            ContactsUploadResult result = intent
                    .getParcelableExtra(ContactsUploadService.UPLOAD_COMPLETE_EXTRA);
            if (result != null) {

            }

            Log.e("contacts", result.successCount + "");
            ContactMatch();

            // Post success notification
        } else {
            // Post failure notification
        }
    }
}


@Override
public void onActivityResult(int requestCode, int resultCode, Intent data) {
    if (requestCode == CONTACT_UPLOAD_REQUEST && resultCode == RESULT_CANCELED) {
    }
}
0

There are 0 answers