aloo
aloo

Reputation: 5389

JODA time in Java Appengine

Has anyone gotten JODA time classes to work on Google Appengine? I'm using 1.3.4 of the java sdk and I get the following error when trying:

java.lang.NoClassDefFoundError: com/google/appengine/repackaged/org/joda/time/DateTimeZone

I've imported it as well:

import com.google.appengine.repackaged.org.joda.time.DateTime;

Upvotes: 7

Views: 3107

Answers (2)

Romain Hippeau
Romain Hippeau

Reputation: 24375

The real purpose of repackaged classes is for Google to have a private set of classes that they can use and that do not conflict with any known packages. Repackaged classes are not meant to be used by the public and if you do, you do at your own risk. They could be yanked at any time.

You can download JODA and just include it as a dependency, there should be nothing to stop it from working. The names will nor clash with Google's because of the different package.

Upvotes: 13

Stevko
Stevko

Reputation: 4495

Lots of people love joda too.

I suggest placing the JODA package jar in your lib directory and importing it directly.

    import org.joda.time.DateTime;

Upvotes: 3

Related Questions