-2

I want to know what's the significance of gradle file in an aar. I just don't know how it work.Even I wonder whether it exsits in an aar or not. I'm confused how to get versionName in an aar.

gaomode
  • 156
  • 1
  • 11

1 Answers1

0

Gradle files are not embedded into your aar. There are files used at compilation time and not at runtime.

I'm confused how to get versionName in an aar.

What is your usecase ? What do you exactly want to do ?

Bruno
  • 3,872
  • 4
  • 20
  • 37
  • I want to build an aar which need to obtain versionName uploading to server. And now, I know gradle file won't be built in aar. So I have to create a static class file to storage versionName. All confuses me is that I do really know nothing about the significance of gradle file when build an aar. – gaomode Sep 11 '18 at 11:59
  • Are you talking about the `versionName' set in the gradle file ? If so, you must have a static class which retrieve it for you – Bruno Sep 11 '18 at 12:18
  • That's what I did. – gaomode Sep 14 '18 at 03:45