AndroidAnnotations Eclipse configuration with ADT 23 - android-annotations

Since ADT 23, there seems to have no way to add Annotation Processor Factory Path to projects:
No "Annotation Processing" item in Poject>Properties>Java Compiler.
Does anyone know how to add androidannotations-X.X.X-api.jar to the annnotaions processing in the last Eclipse ADT?

This is a known problem of the ADT bundle, and will be fixed as of ADT 23.0.3. In the meantime, you can fix this by downloading a standard Eclipse distribution and installing the ADT plugin to that. Or if you want to use your existing ADT bundle, you can install the necessary JDT plugin as described here.
Also please note that you do not have to add the androidannotations-X.X.X-api.jar as you written in the OP. You have to add the androidannotations-X.X.X.jar to the annotation processing factories and androidannotations-X.X.X-api.jar to your classpath (libs).

i am using ADT23 with Eclipse Luna.
Go to your project properties and select Java Compiler and select you Compiler Compliance Level to 1.6.
Then your Annotation Processing option will be enable.
Create a folder compile-libs in your project, where your lib folder and paste jar file androidannotations-3.0.1.jar this location compile-libs\androidannotations-3.0.1.jar .
Add androidannotations-api-3.0.1.jar in your project libs\androidannotations-api-3.0.1.jar .
Finally, you must add both file path in your Factory Path.
e.g {Your Project}/compile-libs/androidannotations-3.0.1.jar and
{Your Project}/libs/androidannotations-api-3.0.1.jar

Related

nocache.js not found in Vaadin project

"Requested resource [/VAADIN/widgetsets/AppWidgetset/AppWidgetset.nocache.js] not found.." I get this when I'm including new addons, either from a JAR file or through Maven. Sometimes, if I've added the dependency in Maven, adding the JAR file as well to the build path fixes it, sometimes it's the other way around, other times compiling the widgetset and/or theme fixes it, and there are even times when nothing helps. This type of behavior seems to me more random than scientific.
I would love to know how to properly add dependencies to the project so that I can avoid this problem.
Select the UI project and goto Properties - Deployment Assembly. Check if you already have widgetset.jar file. If the widgetset.jar is missing then Click on Add -> Maven Project and select widgetset (make sure the jar file naming convention follows backend project like WEB-INF/lib/qqq-widgetset-1.0-SNAPSHOT.jar and WEB-INF/lib/qqq-backend-1.0-SNAPSHOT.jar)

Nuget package all sub project in a solution

I have a solution which contains more than one Project. Project structure is as below.
/root
A.sln
A.nuspec
/ProjectB
projectB.csprj
projectB.nuspec
/ProjectC
projectC.csprj
projectC.nuspec
I have a few question.
1- What happens if I run nuget pack A.nuspec in root folder. Is there a way package all Project in a solution.
2- When I send the code TFS, with "NuGet Packager" I can use a regex to packege all sub Project as shown below. Is there a way to use such a regex in local environment.
3- Is it possible to create a nupkg contain both sub Project.
4- Is it possible to create a nupkg contain more than one dll. Can I put all dependency of the Project into nupkg.
1- What happens if I run nuget pack A.nuspec in root folder. Is there a way package all Project in a solution.
I don't believe there is a way to package all project in a solution by using .nupsec. That because the process of creating a package always begins with creating a .nuspec package manifest file that describes your package contents. This manifest drives the creation of the package as well as its usage when installed into a project not solution. And the ID and Version must be unique in the .nupsec, so we could not use the unique ID and Version to specify multiple projects.
2- When I send the code TFS, with "NuGet Packager" I can use a regex to packege all sub Project as shown below. Is there a way to use such a regex in local environment.
The answer is NO. I have test it on my local machine, the wildcard is treated as Illegal characters in the command line.
3- Is it possible to create a nupkg contain both sub Project.
If I understand you correctly, you mean the sub Project is reference project? If yes, the answer is yes. You can use the the option "IncludeReferencedProjects" to include referenced projects either as dependencies or as part of the package. please refer to this document for detail.
4- Is it possible to create a nupkg contain more than one dll. Can I put all dependency of the Project into nupkg.
Of course you can. You can refer to another thread which I have answered for more detail. If you want to put all dependencies of the Project into nupkg, you can use the <dependencies> to include all dependencies in the .nuspec.
<dependencies>
<dependency id="Newtonsoft.Json" version="9.0" />
</dependencies>

JavaFXPorts and robovm-cocoatouch import

I’m trying to use JavaFXPorts and RoboVM-cocoatouch but I can’t use the native stuff from RoboVM like UIButton.
I have the following dependencies in my build.gradle file:
classpath 'org.javafxports:jfxmobile-plugin:1.0.0-b5'
classpath 'org.robovm:robovm-cocoatouch:1.0.0'
And I'm trying to import org.robovm.apple.uikit.* but eclipse can't find the Packages.
What I have to do that I can use JavaFXPorts and the native stuff from RoboVM?
The short answer:
you need to create a folder src/ios/java in which your iOS specific source files should be located. The source files within this folder automatically have the correct classpath set, so you can use the RoboVM classes there.
The long answer:
In addition to the default main source set, the jfxmobile plugin also adds a source set for every platform the plugin supports: android, ios and desktop. Each source set has a src/PLATFORM/java and src/PLATFORM/resources directory which contains the platform specific source files and resource files respectively.
Platform independent code must be written inside the folder src/main/java, while platform specific code must be written inside the matching platform sources folder. For instance, in your case, iOS code should be put inside the src/ios/java folder.
The plugin also makes sure that the dependencies are correctly configured for each source set. Also, when you are for instance generating your IPA, it will only contain the class files from the main and ios source sets.
For more information about the structure of a jfxmobile project, look at the Structure section on this webpage: http://javafxports.org/page/Setting_up
You can read more information about gradle source sets in the java plugin documentation: http://gradle.org/docs/current/userguide/java_plugin.html

Add a jar file to my Xamarin project

I am wanting to add the "universal-image-loader jar" file to my Xamarin project and am not sure what I need to do. I have had a look at this resource but would still like some help please: itexico.com/blog/bid/100447/Android-Wear-Developer-Preview-Using-Xamarin-Jar-Binding
Here is what I have done so far:
Downloaded https://github.com/nostra13/Android-Universal-Image-Loader
Created a folder called "Jars" in the root folder of my Xamarin project
I have added the "universal-image-loader-1.9.2-with-sources.jar" file to the "Jars" folder
I have set the build action to "embedded resource" for the "universal-image-loader-1.9.2-with-sources.jar" file
I have successfully build the project
I still cannot use the ImageLoaderobject in my application. I cannot resolve a ImageLoaderobject and am not sure what else I need to do.
May I please have some help?
Thanks in advance
I'd suggest you use Java Bindings Library for that.
What you need to do is to add a project to your solution of type "Android Java Bindings Library" you DON'T need to create Jars folder it is created in the new project by itself. Add your jars there. On your startup project click on references and add the java binding project you have just created as a reference. build it and try accessing your assembly either by adding it in the using section or by it's fully qualified name.
Good luck!

include a java-me jar with a blackberry application

I want to use the ksoap2-j2me-core-prev-2.1.2.jar file. But on use time application create a error
Module 'ksoap2-j2me-core-prev-2.1.2' not found
Any 3rd party jar has to be preverified using the SDK's preverify tool. Also, make sure that in Eclipse, you select the check box for the jar underneath the "Order and Export" tab when setting the build path (the same place where you add the jar)

Resources