Package name & Class Name of facebook app

佐手、 提交于 2019-12-18 19:38:07

问题


Just a small confusion I want to ask while making a facebook app to implement share feature in my android app

Unique app Identifier used to open your app

  1. Package Name: Is it that unique identifier that I have written while creating the new facebook app at their developer console ? or Is it the package name of my android app ?

The Main Activity you want Facebook to launch

  1. Class Name: I have added a facebook share button in every fragment(class), so which class is the Main Activity that it want facebook to launch ? Or is it the main activity of my android app?

回答1:


See this screenshot from Facebook's getting started documentation.




回答2:


add Package name of your application in Package Name Field add Activity Name in Class Name Field. Like You have com.example.facebook as your package name . In that package you have many Activity but you want to use Facebook Code in FbExampleActivity then FbExampleActivity is your Class Name.




回答3:


I haven't tried yet, but it seems that these fields for deep link only. It is useful when you want Facebook to show ads linking to your app. In case users click on an ad:

  • if your app was installed on user's device (based on the package name you defined here), it will send an intent to your activity (base on class name you defined here). This activity will handle the intent.

  • Otherwise, it will go to your application on google play (again, base on the package name you define here)

deep link: https://developers.facebook.com/docs/app-ads/deep-linking

App Links on Android: https://developers.facebook.com/docs/applinks/android

In conclusion, if you are not going to integrate app links, just put your package and main activity here.



来源:https://stackoverflow.com/questions/24838476/package-name-class-name-of-facebook-app

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!