Change Android Studio doclet version - android

I need to generate the javadoc for a Library in Android Studio.
The problem is that, when I start to create the doc, I see the following logs:
Constructing Javadoc information...
Standard Doclet version 1.8.0_31
Building tree for all the packages and classes...
[...]
1 error
javadoc: error - com.sun.tools.doclets.internal.toolkit.util.DocletAbortException: com.sun.tools.javac.code.Symbol$CompletionFailure: class file for java.lang.FunctionalInterface not found
I don't know exactly what is the problem. I think it is the doclet version (it takes by default 1.8.0_31); I tried to modify it but I did not succeed... any help?
I am using Mac OSX and Android Studio 1.2.2

Related

Xamarin Android: FreshChat SDK Implementation in xamarin forms giving exception

I have downloaded Android SDK 5.1.0 from url https://github.com/freshworks/freshchat-android/releases
of SDK Documentation:
https://support.freshchat.com/en/support/solutions/articles/50000000207-freshchat-android-sdk-integration-steps#4.1-Conversations
to implement it in xamarin.android project and this sdk is using handlers for click and some other events.
I converted this jar file into .dll using Xamarin Android Class Library. (jar build action is InputJar).
When I rebuild this class library project then no errors came and it released .dll successfully
Then I referenced this dll into my project and I rebuild it.
Here, I got some handler related issues that these handlers are not registered/missing in activity.
(1) error: package com.freshchat.consumer.sdk does not exist
com.freshchat.consumer.sdk.FreshchatWebViewListener
(2) error: package com.freshchat.consumer.sdk does not exist
com.freshchat.consumer.sdk.FreshchatUserInteractionListener
(3) error: package com.freshchat.consumer.sdk does not exist
com.freshchat.consumer.sdk.FreshchatActionListener
This is Android Class Library where I added sdk
Here, I referenced ClassLibrary .dll
handlers from sdk is appeared as a interface
MainActivity.cs
Errors when I rebuild
When I click on one of these error then it shows some definition in referenced sdk:
com.freshchat.consumer.sdk.FreshchatWebViewListener
Codewise I have not consumed sdk function in the mainactivity.
It looks like sdk is using some handlers which need to define in the MainActivity.cs
Am I defining in a wrong way or path is wrong for this sdk implementation.
Please suggest how to fix these errors while class library implementation.

GoogleMaps.LocationServices NuGet package says namespace could not be found

I am creating an android application using Xamarin on Visual Studio 2017. I am trying to use the NuGet package GoogleMaps.LocationServices using this guide (http://www.c-sharpcorner.com/blogs/find-latitude-and-longitude-using-c-sharp1). I have installed the package fine
But when I try to use the package on my code like the guide I following does I just get an error saying it can't find the namespace:
This means that I cannot create a GoogleLocationService() object which is what I need to do to create a Google Maps pin point using a list of location addresses.
Anyone got any idea why I'd be getting this error? Unsure if I just need to use a different namespace now as this guide was from 2013.
The GoogleMaps.LocationServices 1.2.1 NuGet package contains an assembly for .NET 4.0 and no other target frameworks. So it does not support Android projects. NuGet will not add a reference to the GoogleMaps.Gelocation assembly since it is in the lib/net40 directory so it not considered compatible.
Instead I would take a look at the Xamarin.GooglePlayServices.Location NuGet package.
Looking at the content of the NuGet package it has a content file GoogleMaps.LocationServices.readme.txt which seems to be why you can install it into a Android project. This GoogleMaps.LocationServices.readme.txt file is added to your project.
Ideally the NuGet package should have a readme.txt file in the root of the NuGet package and not add a file to the project. Such a readme.txt file would be automatically opened on installation by Visual Studio without the need to add anything to the project. Removing the content file would also prevent the NuGet package from being installed into an Android project, or any other unsupported project type.
The older GoogleMaps.LocationsServices 0.9.0 can be installed into an Android project but that seems to be because the NuGet package is not packaged correctly. The GoogleMaps.Gelocation assembly in this version of the NuGet package is in the lib directory and does not indicate any target framework so it is allowed in all project types, which does not seem to be correct.
It's hard to trace what a new signature of the methods are in 2017, but from my brief look if you change the version on a package to
0.9.0 and use namespace
using GoogleMaps.Geolocation;
The example should work.

Xamarin.Android 7.0 Build Errors

I am trying to update an older Xamarin.Android codebase. I was using a pre-API 21 target and now trying to update to API 24 (Android Nuget). I think I have resolved the majority of the compatibility issues, but one is troubling me. When I do a build I get the following error.
/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/Android/Xamarin.Android.Common.targets: Error: Tool exited with code: 10. Output: Error: Can't read [/Library/Frameworks/Xamarin.Android.framework/Versions/7.0.2-37/lib/xbuild-frameworks/MonoAndroid/v7.0/mono.android.jar] (Can't process class [android/app/ActivityTracker.class] (Unsupported class version number [52.0] (maximum 51.0, Java 1.7)))
After doing some Google searching I found that the majority of people who are having this issue are using Java 1.8, as am I. Apparently, the bundled version of ProGuard does not support Java 1.8 byte code. I have manually installed the latest version of ProGuard (5.3.1) over the packaged version in the folder below.
~/Library/Android/sdk/tools/proguard
Unfortunately I am still having the same error. I am also using the latest version of the following packages (see screenshot).
Does anyone have any idea how to resolve this build issue?
For this particular error message I had turned out the issue was I installed ProGuard in the wrong place. I originally installed ProGuard in ~/Library/Android/sdk/tools but instead needed to be in ~/Library/Developer/Xamarin/android-sdk-macosx/. This resolved that build error.
Just download the latest version of proguard from the this link;
Unzip the content to a folder called proguard;
Replace the folder ~/Library/Developer/Xamarin/android-sdk-macosx/tools/proguard with the folder from the previous step.

getting error during project creation using phonegap-2.5.0

i have installed android sdk and downloaded the latest version of phonegap 2.5.0 in fedora 18.
i am trying to create a project using the following command
./create ~/Desktop/android-project com.example.android android_project
am getting the following error.
which: no android in (/sbin:/bin:/usr/sbin:/usr/bin)
An unexpected error occurred: ANDROID_BIN="${ANDROID_BIN:=$( which android )}" exited with 1
need your valuable suggestions.
finally found the answer
After checking my .bash_profile paths, and a bunch of digging, I finally found the cause of the issue. If you open up the create file (phonegap-2.5.0/lib/android/bin/create), there is a line that lists ANDROID_BIN=”${ANDROID_BIN:=$( which android )}”. The “which android” is the cause of the issue (or at least it seemed to be in my case). If you replace this line with the full path to your android tools (as listed below) it should resolve the issue. My final line looked like this:
ANDROID_BIN=/Users/ktyacke/DEV/adt-bundle-mac-x86_64-20130219/sdk/tools/android
The message you have means the phonegap script cannot find the android binary, which is included in the SDK you downloaded. Add the binary's directory, as well as the android tool's directory, to your path defined in ~/.bash_profile or any other location you're initializing the shell's environment variables.

What could be causing the "OutputPath property is not set for project ProjectName.csproj" error in my MonoDevelop project

On Windows 7 (64 bit) with the Android SDK working perfectly with Eclipse - my first android application, using the first "Hello World" sample (found here - http://docs.xamarin.com/android/getting_started/hello_world - from Xamarin)
fails with the error "the OutputPath property who is not set for project NameProject.csproj".
I have tried re-runing the installation program from Xamarin and this error still occurs.
Could someone please suggest what may be causing this problem?
Thanks a lot.
the exact error:
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(9,9):
Error: The OutputPath property is not set for project 'helloWorld3.csproj'.
Please check to make sure that you have specified a valid combination of
Configuration and Platform for this project.
Configuration='Debug'
Platform='BPC'.
This error may also appear if some other project is trying to follow a
project-to-project reference to this project, this project has been
unloaded or is not included in the solution, and the referencing project
does not build using the same or an equivalent Configuration or Platform.
(helloWorld3)
I think we've seen this before. Your system manufacturer installed an environment variable called Platform onto your system. This breaks all msbuild based stuff, since msbuild automatically imports that as $(Platform), conflicting with the real $(Platform) that msbuild uses to compile.
Try removing the environment variable and try again.

Categories

Resources