12/05/2011

[Android] Third-party library

對一個開放式的作業系統,必須要了解如何在程式中加入網路上Third-party 所開發的library,即可大幅節省開發時間.
通常會提供 *.jar的library方式讓開發者下載與加入專案,請遵照下列方式即可:

  • Copy this .jar file.
  • In Eclipse, create a new folder directly underneath the main application folder (where src and gen are). Name the folder "lib" without the " ".
  • Right click this new folder, and paste the .jar file.
  • The library is now part of your project, but you must add it to the build path before you reference it.
  • Still in Eclipse, right click the .jar you added and select the "Build Path -- Add to Build Path" option.
  • It will now show up under Referenced Libraries. You are all set!

沒有留言:

張貼留言

請留言~一起討論吧~