Jump to content

help a brother out.. google api


Recommended Posts

Posted (edited)

How did you import the lib?

 

Jar? Maven? Gradle?

 

Edit: 

then right clicked gradle project in project explorer and exported as a jar, then imported that jar into my projects libraries.

Don't do that...

 

Google how to use gradle :p

 

Or just use maven:

<dependency>
    <groupId>com.google.maps</groupId>
    <artifactId>google-maps-services</artifactId>
    <version>(insert latest version)</version>
</dependency>

Maven is love.

Edited by Botre
  • Like 1
Posted

How did you import the lib?

 

Jar? Maven? Gradle?

 

Edit: 

then right clicked gradle project in project explorer and exported as a jar, then imported that jar into my projects libraries.

Don't do that...

 

Google how to use gradle :p

 

Or just use maven:

<dependency>
    <groupId>com.google.maps</groupId>
    <artifactId>google-maps-services</artifactId>
    <version>(insert latest version)</version>
</dependency>

Maven is love.

I used eclipse to build the gradle project, which then showed up in project explorer, which I then exported to a jar. Which is used in my project. Was this the wrong way to do it? Could you give me a example how I would do this?

Posted

I used eclipse to build the gradle project, which then showed up in project explorer, which I then exported to a jar. Which is used in my project. Was this the wrong way to do it? Could you give me a example how I would do this?

 

Yes it was the wrong way to do it, you can google Gradle if you want to learn more but I would deffo suggest Maven over Gradle:

 

Create new Maven project, open pom.xml, paste the dependency, done.

  • Like 1
Posted

Yes it was the wrong way to do it, you can google Gradle if you want to learn more but I would deffo suggest Maven over Gradle:

 

Create new Maven project, open pom.xml, paste the dependency, done.

Using maven, I added the dependency code you gave me but where do i put the google api project?

Posted

Using maven, I added the dependency code you gave me but where do i put the google api project?

 

Maven takes care of every thing.

 

Fill in pom.xml.

Optional (in case you don't have auto-update enabled for maven): Right-click project -> maven -> update project.

Maven will download everything that is required and add it to your project.

Start coding.

  • Like 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...