摘录


You’re working on your Android application and realize you have a nice piece of reusable encapsulated logic you’d like to factor out into a library. You still want to be able to develop this library and your application in parallel, so they should be on disk together and somehow linked. So what’s the best way to accomplish this?

Like my previous post, this is a bit of a challenge because there’s no way to do this out of the box, so I’m capturing my learnings here.

Postcondition After this, you’ll have a second project (for the library) that will contain two modules: the library logic itself, and another for the examples. When you make a change to the library, you’ll need to republish it, and then refresh Gradle on the application side. Publishing will publish to a local Maven repository – no actual uploads will take place.

I won’t be covering how to take this and publish to a real repository – there’s plenty of those online already.

点评

NULL

原文

点击这里查看原文

其它

本帖内容由21QA云收藏工具自动生成,欢迎使用。

系统消息 若觉得内容不错,请点击左上角的"赞"图标,以优化网站的内容呈现。 另外,请及时验证注册邮箱,否则收不到21QA发出的红包。 官方Q群:250203055

asked 12 Jun, 17:46

%E8%B7%AF%E4%BA%BA%E7%94%B2's gravatar image

路人甲
131569615788

Be the first one to answer this question!
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link: [text](http://url.com/ "title")
  • image: ![alt](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×877
×91
×5

question asked: 12 Jun, 17:46

question was seen: 93 times

last updated: 12 Jun, 17:46

powered by O*S*Q*A

粤ICP备14040061号-1