Google IO 2015 – GCM 3.0

Google I/O 2015

Para los que aún no hayan visto aún esta edición, la 2015, entre las novedades, referente a GCM (Google Clud Messaging), en su versión 3.0, hay una serie de novedades que merecen ser nombradas:

Para no perderte las novedades, si aún no lo viste, haz clic en Google I/O 2015 – Google Cloud Messagin 3.0. Tenéis también la web https://developers.google.com/cloud-messaging en donde poder ver todo lo relativo a GCM.

Como siempre, poco a poco iré integrando estas novedades en la librería Android javocsoft-toolbox, para que podáis disfrutar de dichos cambios de una manera sencilla.

 

Os dejo los videos, a modo recopilatorio, del evento ya pasado.

Y aquí otras exposiciones sobre temas concretos:

 

Un saludo,

Hi all,

I am still finishing the Maps integration and other things to the JavocSoft Android Toolbox Library while preparing some documentation related to GCM and a few HowTos (you can read anyway the Wiki on GitHub) but meanwhile, i have added some useful animation methods that i would JavocSoft Android Toolbox Librarylike to share :).

The new stuff is:

  • Apply animations from one activity to another by using: animation_applyAnimationToActivityLoad().
  • Apply animations to a View by using new methods animation_getFromAnimResourceId() and animation_applyAnimationTo().
  • A set of predefined animations ready to use in your projects. Complete list:
    • Blinking: blink
    • Zooming: zoom_in.xml, zoom_out.xml, zoom_out_in.xml.
    • Curtain: curtain_up.xml , curtain_down.xml, curtain_down_and_bounce.xml, curtain_left_and_right.xml, curtain_right_and_left.xml,
    • Fade: fadein.xml, fadeout.xml,
    • Directions: left_in, left_out, right_in, right_out.
    • Pushing: push_down_in, push_down_out,
    • Rotate: rotate_left_and_right.xml, rotate_right_and_left.xml, rotate_left.xml, rotate_right.xml,
    • Sliding: slide_out.xml, slide_up.xml,
    • Others: bottom_in, move.

 

As always, I hope these changes could help you a bit more than before.

Do not forget to check the blog to get the Maps integration update!

More info and HowTo at https://github.com/javocsoft/javocsoft-toolbox/wiki.

github_icon

As always, library is available on GitHub

javocsoft-toolbox.

Bye.

JavocSoft 2015.

 

Hi all,

Finally i have finished with the last changes in JavocSoft Android Toolbox Library and it is ready on the GitHub repository!. As a brief:

  • There is more functionallity through a lot of new methods.
  • Notifications have been updated to last Android code 5.0+. NotificationCompat is used so now, all posibilities of a notification are implemented (actions, progress bar, priority, visibility and more).
  • GCM Module is updated with the new notifications posibilities allowing to customize more the notifications.

I am still preparing Google Maps v2 integration to put a map in your application with a few lines of code, i hope i can put more time in this to finish it.

JavocSoft Android Toolbox Library

I put here the detailed changes:

  • ToolBox, Notifications:
    • Finally, migrated to NotificationCompat builder 🙂
    • Now the notification title, ticker, content info and large icon can be customized.
    • Priority and visibility implemented, for Android 5.0+ API Level 21+.
    • Implemented big style expandable notification for Android 4.1+ (API Level 16+).
    • Implemented notification actions for Android 4.1+ (API Level 16+).
    • Implemented, for Android 4.0 API Level 14+, notification progress bar (determinate & indeterminate).
    • A new class ToolBox.NotificationProgressBarRunnable has to be extended to create your own long term process.
    • Implemented RemoteViews in notifications.
    • Method notification_generate is maintained for backwards compatibility (it uses also NotificationCompat).
    • New method notification_create that allow to customize completely a notification.
  • ToolBox, Added some more utility methods:
    • device_getOSCodename
    • device_getExtraInfo
    • application_packageName
    • application_packageInfo
    • application_nameInfo
    • application_certificates
    • random_HASH
    • random_UUID
    • random_getRandom
    • random_getSecureRandom
    • gson_linkedMapAsList
    • storage_readRawResource
    • storage_readAssetResource
    • media_getDrawableFromRaw
    • media_getBitmapFromResourceId
    • media_getBitmapFromAsset
    • media_getBitmapFromRaw
    • media_getBitmap (looks, in order, for the resource in Drawable -> Assets -> Raw -> URL)
    • Some media methods to get bytes from a resource image.
  • GCM Module now supports:
    • All ToolBox notification changes. Note: Priority is set to DEFAULT and visibility to PRIVATE.
    • Customization parameters (all these parameters should be set in the data object when delivering the notification to
      the devices in GCM) are:

      • notificationId
      • notStyle
      • title
      • message
      • ticker
      • contentInfo
      • bsTitle
      • bsContent
      • bsSummary
      • bsImage
      • bsInboxStyleContent
      • bsInboxStyleLineSeparator
      • bslargeIcon
  • Added a new TextView component (widget) that allows to show HTML tags.
  • Added a JSON Gson proccesor instance. It gives you a singleton with pre-configured gson processor for a normal process, and, if desired, the possibility of use an excluding “transient” attribute JSON processor and also one excluding properties without the Exposed annotation.
  • Added official PRNG Fix class to Android with API level minor or equal to 18 (Jelly Bean) for JCA or OpenSSL PRNG.
  • BUGFIX. In some devices (depending also of Android version) the flip effect runs laggy. Added a a new flipTransition method that allows to specify to check if the current device is one of reported laggy devices (like LG G3 or Nexus 5). In case is a laggy device, depending of the parameter “enableFadeForLaggyDevices” a fade effect is used as animation instead the desired flip or no effect is applied if set to FALSE.
  • BUGFIX. crypto_getHASH() function. Hash was not correctly generated.
  • BUGFIX. Fixed a bug that made the recived text not be showed correctly if character encoding was not latin.
  • BUGFIX. GCM. Fixed an issue with the event of Notification received. No context was returned. This could make an application to crash if used.
  • BUGFIX. Toolbox. Fixed device_getOSversion. Returned info was wrong.

As i said, these are a lot of changes because i have been implementing all notifications related stuff and quite busy at work so i could not publish until today. I think now the libreruy is more useful. I now that i still have to improve some points but i am already in it so have patiente.

As always, I hope these changes could help you a bit more than before.

 

Do not forget to check the blog to get the Maps integration update!

More info and HowTo at https://github.com/javocsoft/javocsoft-toolbox/wiki.

github_icon

As always, library is available on GitHub

javocsoft-toolbox.

Bye.

JavocSoft 2015.

Hi all,

There are changes in JavocSoft Android Toolbox Library ready on the GitHub repository!. There is a bit more functionallity to it and, i am preparing Google Maps v2 integration to put a map in your application with a few lines of code, i hope i finish this soon.

JavocSoft Android Toolbox Library

The changes are:

  • Added method to show GPS settings panel, “dialog_showGPSDisabledAlert()”
  • Added DENSITY_XXXHIGH to device_getResolutionType() or unknown if not recognized.
  • Added the method location_addressInfo() to get some latitude and longitude address information.
  • Now the method “dialog_showExitConformationDialog()” allows to select if move the activity to the stack or close it.
  • Added a method “backPressedAction()” to enable the functionallity of “Press again back to exit”.
  • Added AnimationFactory class, under animation package, from Ephraim Tekle, to perform animations in a easy way. I use it and i think is quite useful.
  • Added an ImageDownloader class, under net/image package, to download image URLs in background and show them in its ImageView.
  • Added the possibility of custom Toast messages, “toast_createCustomToast()”, default ones are horrible XD.
  • Added the possibility of a custom Toast when user press the back button to exit if function backPressedAction() is used.
  • Added the method location_distance to know the distance in meters from one Map point to other using the Haversine algorithm.
  • The “dialog_showToastAlert()” method now allows to choose between system default toast and a custom one.
  • Now the method “share_newSharingIntent()” allows to filter applications using more than one application filter.
  • On Interstitial Ad now user clicks on it can be cached.

I hope these changes can help you a bit more.

Do not forget to check the blog to get the Maps integration update!

 

More info and HowTo at https://github.com/javocsoft/javocsoft-toolbox/wiki.

github_icon

As always, library is available on GitHub

javocsoft-toolbox.

 

Bye.

JavocSoft 2015.

Hi all,

There is a new JavocSoft Android Toolbox Library ready on the GitHub repository!. It has taken
quite long to get finally an updated and tested version but now is ready again. This version comes with some interesting updates like:

JavocSoft Android Toolbox Library

  • Google Play Services integration for Google Cloud Messaging (GCM), AdMob and
    Analytics
    (the GCM module has been rebuilt, maintaining the previous usage with some minor changes in usage).
  • CMTInfoHelper. This class allows to download automatically the CMT official short-numbers information. This will give you the possibility of knowing the owner company of a given short-number.
  • Facebook Login and Share fragments to easily integrate Facebook options into an application.
  • Google Analytics Campaign Measurement integration.
  • More utility methods to the Toolbox class.

With this update all implemented Google Play Services are very easy to set-up into your app. Give it a try to:

  • Improve your application by adding GCM, AdMob or Analytics functionalities.
  • Simplify your application code by using the utility methods of the Toolbox class.

More info and HowTo at https://github.com/javocsoft/javocsoft-toolbox/wiki.

github_icon

As always, library is available on GitHub

javocsoft-toolbox.

 

Bye.

JavocSoft 2014.

Hola,

Hay veces que a uno le apetece trastear para desconectar el curro, curiosear de manera tonta, enredando, implementando o integrando alguna cosa divertida, incluso aunque hacerlo no tenga utilidad real, solo porque te apetezca. En este caso me he topado con una API divertida, que sí, que las hay! XDD.

Concretamente he encontrado una con la que me he partido de risa, se trata de la API “The Internet Chuck Norris Database” cuyo site es http://www.icndb.com/api/.

API Chuck Norris - Integración

En el site te explican como integrarla, lo de siempre, una API RestFul con JSON. Puedes testear y ver algunas frases, hay un porrón de frases de temática geek, programación y variadas. Después de un ratillo al final me he dicho: “Vamos a integrar la API de Chuck Norris y ponerla para acompañar el blog con la sabiduría del poderoso  Chuck!” XDD

Para ponerla en el blog, es un WordPress, tan solo he instalado el PHP Code Widget, añadido un Widget de este tipo al sidebar con el código, sencillo, PHP que os dejo a continuación, por si queréis disponer de la sabiduría de Chuck en vuestro blog o página XDD.


<?php

$url="http://api.icndb.com/jokes/random";
$option_defaults = array(
 CURLOPT_HEADER => false,
 CURLOPT_RETURNTRANSFER => true,
 CURLOPT_TIMEOUT => 2
 );

if(!isset($handle)) $handle = curl_init();

$options = array(
 CURLOPT_URL => $url,
 CURLOPT_CUSTOMREQUEST => "GET"
 );
 curl_setopt_array($handle,($options + $option_defaults));
 $response = json_decode(curl_exec($handle),true);

 //print_r($response);
 $jokeText = $response['value']['joke'];

echo $jokeText;
?>

<br><br>
<font color="gray" size="1">Just for fun XD. Using <b>Chuck Norris API</b>. Integration <a href="http://www.icndb.com/api/">Notes</a>)</font>

Porque hay veces que hasta algo como una API puede hacerte soltar unas risas.

Se me ocurre que como ejercicio, a modo de entretenimiento, estaría bien integrar también la API de Google Traductor para mostrar las frases en el idioma que se quiera. Quizás otro día!

 

Ya sabéis, si encontráis alguna otra divertida, compartirlo con el resto!

Un saludo,