{"id":5201,"date":"2020-09-03T13:52:26","date_gmt":"2020-09-03T13:52:26","guid":{"rendered":"https:\/\/conexion-hr.com\/tu-aplicacion-android-de-java-a-kotlin-por-donde-empezar\/"},"modified":"2022-06-06T19:07:43","modified_gmt":"2022-06-06T19:07:43","slug":"tu-aplicacion-android-de-java-a-kotlin-por-donde-empezar","status":"publish","type":"post","link":"https:\/\/conexion-hr.com\/es\/tu-aplicacion-android-de-java-a-kotlin-por-donde-empezar\/","title":{"rendered":"Tu aplicaci\u00f3n Android de Java a Kotlin \u00bfPor d\u00f3nde empezar?"},"content":{"rendered":"<section class=\"\\&quot;fd\" fe=\"\" ff=\"\" fg=\"\" fh\\\"=\"\">\n<div class=\"\\&quot;n\" p\\\"=\"\">\n<div class=\"\\&quot;ab\" ac=\"\" ae=\"\" af=\"\" ag=\"\" fi=\"\" ai=\"\" aj\\\"=\"\">\n<p class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Ya es de p\u00fablico conocimiento que Kotlin es el lenguaje de programaci\u00f3n est\u00e1ndar para desarrollar en Android. Es totalmente retrocompatible con Java, fue reconocido por Google durante el evento Google I\/O 2017 y hoy en d\u00eda se presentan librer\u00edas en modo <em class=\"\\&quot;jv\\&quot;\">Kotlin first<\/em>,<em class=\"\\&quot;jv\\&quot;\">&nbsp;<\/em>es decir, permitiendo aprovechar las ventajas de este lenguaje.<\/p>\n<p id=\"\\&quot;241b\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Pero antes de llegar al punto de poder obtener el m\u00e1ximo provecho de Kotlin hay un camino que recorrer. Es necesario saber que a\u00fan hay muchos equipos de desarrollo manteniendo aplicaciones que ya llevan varios a\u00f1os de existencia y que, naturalmente, han sido escritas en Java. Entonces, si este es tu caso y te gustar\u00eda comenzar a convertir tu aplicaci\u00f3n a Kotlin, es esperable que tu inquietud sea:&nbsp;<strong class=\"\\&quot;iz\" jw\\\"=\"\">\u00bfPor d\u00f3nde empiezo?<\/strong><\/p>\n<p id=\"\\&quot;edaf\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Es importante que, para estar tomar la decisi\u00f3n sin miedo, sepas que:<\/p>\n<ul class=\"\\&quot;\\&quot;\">\n<li id=\"\\&quot;5daa\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" jx=\"\" jy=\"\" jz=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Kotlin es compatible con Java: Es decir, puedes comenzar convirtiendo algunas pocas clases y tu proyecto continuar\u00e1 funcionando. Es normal que en tus proyectos convivan ambos lenguajes.<\/li>\n<li id=\"\\&quot;3877\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" ka=\"\" jc=\"\" jd=\"\" je=\"\" kb=\"\" jg=\"\" jh=\"\" ji=\"\" kc=\"\" jk=\"\" jl=\"\" jm=\"\" kd=\"\" jo=\"\" jp=\"\" jq=\"\" ke=\"\" js=\"\" jt=\"\" ju=\"\" jx=\"\" jy=\"\" jz=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Para comenzar, no necesitas total conocimiento sobre el lenguaje. Android Studio contiene una herramienta de conversi\u00f3n autom\u00e1tica de Java a Kotlin que se ejecuta cuando pegas c\u00f3digo Java en un archivo&nbsp;<em class=\"\\&quot;jv\\&quot;\">.kt&nbsp;<\/em>o bien puedes ejecutar manualmente seleccionando cualquier archivo<em class=\"\\&quot;jv\\&quot;\">&nbsp;.java&nbsp;<\/em>y seleccionando&nbsp;<em class=\"\\&quot;jv\\&quot;\">Convert Java file to Kotlin file<\/em>. Es recomendable que reescribas tu c\u00f3digo a conciencia, pero si est\u00e1s en una etapa de aprendizaje, esto puede ayudarte con tus primeros pasos. Adicionalmente es posible que el c\u00f3digo generado requiera algunas modificaciones para su optimizaci\u00f3n.<\/li>\n<li id=\"\\&quot;2e4d\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" ka=\"\" jc=\"\" jd=\"\" je=\"\" kb=\"\" jg=\"\" jh=\"\" ji=\"\" kc=\"\" jk=\"\" jl=\"\" jm=\"\" kd=\"\" jo=\"\" jp=\"\" jq=\"\" ke=\"\" js=\"\" jt=\"\" ju=\"\" jx=\"\" jy=\"\" jz=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Para mantener el ritmo de aprendizaje y llevar a cabo definitivamente la migraci\u00f3n de tu proyecto a Kotlin, te recomiendo que cada vez que tengas que escribir una clase nueva, tomes como desaf\u00edo escribirla en Kotlin. Al principio puede resultarte complicado, pero recuerda que tus conocimientos de Java son totalmente aprovechables. Puede llevarte un tiempo acostumbrarte a la nueva sintaxis, pero como todo, es cuesti\u00f3n de pr\u00e1ctica.<\/li>\n<\/ul>\n<p id=\"\\&quot;1cb0\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">En este art\u00edculo aprender\u00e1s a migrar a Kotlin las clases m\u00e1s simples de tu proyecto, para familiarizarte con el lenguaje aplicado a tus clases m\u00e1s cortas y menos complejas.<\/p>\n<\/div>\n<\/div>\n<\/section>\n<hr class=\"\\&quot;kf\" gl=\"\" kg=\"\" kh=\"\" ki=\"\" kj=\"\" iq=\"\" kk=\"\" kl=\"\" km=\"\" kn=\"\" ko\\\"=\"\">\n<section class=\"\\&quot;fd\" fe=\"\" ff=\"\" fg=\"\" fh\\\"=\"\">\n<div class=\"\\&quot;n\" p\\\"=\"\">\n<div class=\"\\&quot;ab\" ac=\"\" ae=\"\" af=\"\" ag=\"\" fi=\"\" ai=\"\" aj\\\"=\"\">\n<h1 id=\"\\&quot;eccb\\&quot;\" class=\"\\&quot;kp\" kq=\"\" fl=\"\" au=\"\" av=\"\" kr=\"\" ks=\"\" kt=\"\" ku=\"\" kv=\"\" kw=\"\" kx=\"\" ky=\"\" kz=\"\" la=\"\" lb=\"\" lc=\"\" ld=\"\" le=\"\" lf=\"\" lg=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><span style=\"\\&quot;font-family:\" helvetica,=\"\" arial,=\"\" sans-serif;\\\"=\"\">Entidades o clases de modelo<\/span><\/h1>\n<p id=\"\\&quot;f8e4\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" lh=\"\" jc=\"\" jd=\"\" je=\"\" li=\"\" jg=\"\" jh=\"\" ji=\"\" lj=\"\" jk=\"\" jl=\"\" jm=\"\" lk=\"\" jo=\"\" jp=\"\" jq=\"\" ll=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Uno de los primeros cambios que puedes llevar a cabo, es migrar a Kotlin tus entidades de modelo y DTOs. Todas las clases que simplemente contengan sus atributos,&nbsp;<em class=\"\\&quot;jv\\&quot;\">getters<\/em>&nbsp;y&nbsp;<em class=\"\\&quot;jv\\&quot;\">setters&nbsp;<\/em>pueden ser f\u00e1cilmente convertidas a una&nbsp;<strong class=\"\\&quot;iz\" jw\\\"=\"\">data class<\/strong>.<\/p>\n<p id=\"\\&quot;0397\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Veamos un ejemplo. Si tenemos una clase con el siguiente formato:<\/p>\n<pre class=\"\\&quot;hx\" hy=\"\" hz=\"\" ia=\"\" ib=\"\" lm=\"\" ln=\"\" cj\\\"=\"\"><span id=\"\\&quot;06f3\\&quot;\" class=\"\\&quot;dv\" lo=\"\" kq=\"\" fl=\"\" lp=\"\" b=\"\" gm=\"\" lq=\"\" lr=\"\" r=\"\" ls\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><strong class=\"\\&quot;lp\" jw\\\"=\"\">public class <\/strong>Usuario <strong class=\"\\&quot;lp\" jw\\\"=\"\">implements<\/strong> Serializable {\n\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">private <\/strong>String <strong class=\"\\&quot;lp\" jw\\\"=\"\">nombre<\/strong>;\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">private <\/strong>Long <strong class=\"\\&quot;lp\" jw\\\"=\"\">id<\/strong>;\n    @SerializedName(\\\"urlAvatar\\\")\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">private <\/strong>String <strong class=\"\\&quot;lp\" jw\\\"=\"\">avatar<\/strong>;\n    \n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">public <\/strong>String getNombre() {\n        <strong class=\"\\&quot;lp\" jw\\\"=\"\">return nombre<\/strong>;\n    }\n\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">public void <\/strong>setNombre(String nombre) {\n        <strong class=\"\\&quot;lp\" jw\\\"=\"\">this<\/strong>.<strong class=\"\\&quot;lp\" jw\\\"=\"\">nombre <\/strong>= nombre;\n    }\n\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">public <\/strong>Long getId() {\n        <strong class=\"\\&quot;lp\" jw\\\"=\"\">return id<\/strong>;\n    }\n\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">public void <\/strong>setId(Long id) {\n        <strong class=\"\\&quot;lp\" jw\\\"=\"\">this<\/strong>.<strong class=\"\\&quot;lp\" jw\\\"=\"\">id <\/strong>= id;\n    }\n\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">public <\/strong>String getAvatar() {\n        <strong class=\"\\&quot;lp\" jw\\\"=\"\">return avatar<\/strong>;\n    }\n\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">public void <\/strong>setAvatar(String avatar) {\n        <strong class=\"\\&quot;lp\" jw\\\"=\"\">this<\/strong>.<strong class=\"\\&quot;lp\" jw\\\"=\"\">avatar <\/strong>= avatar;\n    }\n}<\/span><\/pre>\n<p id=\"\\&quot;b242\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">podemos convertirla a:<\/p>\n<pre class=\"\\&quot;hx\" hy=\"\" hz=\"\" ia=\"\" ib=\"\" lm=\"\" ln=\"\" cj\\\"=\"\"><span id=\"\\&quot;ff14\\&quot;\" class=\"\\&quot;dv\" lo=\"\" kq=\"\" fl=\"\" lp=\"\" b=\"\" gm=\"\" lq=\"\" lr=\"\" r=\"\" ls\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><strong class=\"\\&quot;lp\" jw\\\"=\"\">data class <\/strong>Usuario (\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">var nombre<\/strong>: String?,\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">var id<\/strong>: Long?, \n    @SerializedName(\\\"urlAvatar\\\") \n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">var avatar<\/strong>: String?) : Serializable<\/span><\/pre>\n<p id=\"\\&quot;eb30\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><strong class=\"\\&quot;iz\" jw\\\"=\"\">A saber:&nbsp;<\/strong>Kotlin introduce el concepto de&nbsp;<strong class=\"\\&quot;iz\" jw\\\"=\"\">data class<\/strong>. Es decir, clases que \u201cguardan\u201d datos. Los&nbsp;<em class=\"\\&quot;jv\\&quot;\">getter<\/em>&nbsp;y&nbsp;<em class=\"\\&quot;jv\\&quot;\">setters<\/em>&nbsp;son generados autom\u00e1ticamente. Pero no solamente eso: Adem\u00e1s genera autom\u00e1ticamente los m\u00e9todos&nbsp;<code class=\"\\&quot;el\" lt=\"\" lu=\"\" lv=\"\" lp=\"\" b\\\"=\"\">hashCode()<\/code>,&nbsp;<code class=\"\\&quot;el\" lt=\"\" lu=\"\" lv=\"\" lp=\"\" b\\\"=\"\">equals()<\/code><em class=\"\\&quot;jv\\&quot;\">,&nbsp;<\/em><code class=\"\\&quot;el\" lt=\"\" lu=\"\" lv=\"\" lp=\"\" b\\\"=\"\">toString()<\/code>&nbsp;y<em class=\"\\&quot;jv\\&quot;\">&nbsp;<\/em><code class=\"\\&quot;el\" lt=\"\" lu=\"\" lv=\"\" lp=\"\" b\\\"=\"\">copy()<\/code><em class=\"\\&quot;jv\\&quot;\">.<\/em><\/p>\n<p id=\"\\&quot;3a74\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">De esta forma, puedes comenzar convirtiendo, por ejemplo, las clases que modelan el&nbsp;<em class=\"\\&quot;jv\\&quot;\">body<\/em>&nbsp;de un&nbsp;<em class=\"\\&quot;jv\\&quot;\">request<\/em>&nbsp;o un&nbsp;<em class=\"\\&quot;jv\\&quot;\">response<\/em>.<\/p>\n<h1 id=\"\\&quot;24dd\\&quot;\" class=\"\\&quot;kp\" kq=\"\" fl=\"\" au=\"\" av=\"\" kr=\"\" lw=\"\" kt=\"\" ku=\"\" lx=\"\" kw=\"\" kx=\"\" ly=\"\" kz=\"\" la=\"\" lz=\"\" lc=\"\" ld=\"\" ma=\"\" lf=\"\" lg=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><span style=\"\\&quot;font-family:\" helvetica,=\"\" arial,=\"\" sans-serif;\\\"=\"\">Interfaces<\/span><\/h1>\n<p id=\"\\&quot;d232\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" lh=\"\" jc=\"\" jd=\"\" je=\"\" li=\"\" jg=\"\" jh=\"\" ji=\"\" lj=\"\" jk=\"\" jl=\"\" jm=\"\" lk=\"\" jo=\"\" jp=\"\" jq=\"\" ll=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Puedes comenzar la migraci\u00f3n en las partes de tu proyecto que contengan menos (o nada de) l\u00f3gica. Adem\u00e1s de las clases de modelo, puedes convertir las interfaces.<\/p>\n<p id=\"\\&quot;d20e\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Por ejemplo, partiendo de un ejemplo como el siguiente:<\/p>\n<pre class=\"\\&quot;hx\" hy=\"\" hz=\"\" ia=\"\" ib=\"\" lm=\"\" ln=\"\" cj\\\"=\"\"><span id=\"\\&quot;d64f\\&quot;\" class=\"\\&quot;dv\" lo=\"\" kq=\"\" fl=\"\" lp=\"\" b=\"\" gm=\"\" lq=\"\" lr=\"\" r=\"\" ls\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><strong class=\"\\&quot;lp\" jw\\\"=\"\">public interface <\/strong>RepositorioUsuarios {\n    List&lt;Usuario&gt; obtenerTodos();\n    Usuario obtener(Long id);\n    void guardar(Usuario usuario);\n}<\/span><\/pre>\n<p id=\"\\&quot;13df\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">podr\u00edamos convertirlo a:<\/p>\n<pre class=\"\\&quot;hx\" hy=\"\" hz=\"\" ia=\"\" ib=\"\" lm=\"\" ln=\"\" cj\\\"=\"\"><span id=\"\\&quot;6834\\&quot;\" class=\"\\&quot;dv\" lo=\"\" kq=\"\" fl=\"\" lp=\"\" b=\"\" gm=\"\" lq=\"\" lr=\"\" r=\"\" ls\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><strong class=\"\\&quot;lp\" jw\\\"=\"\">interface <\/strong>RepositorioUsuarios {\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">fun <\/strong>obtenerTodos(): List&lt;Usuario&gt;\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">fun <\/strong>obtener(id: Long?): Usuario?\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">fun <\/strong>guardar(usuario: Usuario)\n}<\/span><\/pre>\n<p id=\"\\&quot;c266\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><strong class=\"\\&quot;iz\" jw\\\"=\"\">A saber:&nbsp;<\/strong>Este es un ejemplo t\u00edpico en el cual la migraci\u00f3n no conlleva grandes modificaciones. Sin embargo, el concepto de interfaz en Kotlin difiere del de Java. Una gran diferencia es que en Kotlin las interfaces permiten incluir implementaci\u00f3n de sus funciones.<\/p>\n<h1 id=\"\\&quot;f955\\&quot;\" class=\"\\&quot;kp\" kq=\"\" fl=\"\" au=\"\" av=\"\" kr=\"\" lw=\"\" kt=\"\" ku=\"\" lx=\"\" kw=\"\" kx=\"\" ly=\"\" kz=\"\" la=\"\" lz=\"\" lc=\"\" ld=\"\" ma=\"\" lf=\"\" lg=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Singleton<\/h1>\n<p id=\"\\&quot;665b\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" lh=\"\" jc=\"\" jd=\"\" je=\"\" li=\"\" jg=\"\" jh=\"\" ji=\"\" lj=\"\" jk=\"\" jl=\"\" jm=\"\" lk=\"\" jo=\"\" jp=\"\" jq=\"\" ll=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Seguramente tu proyecto contiene alguna o varias clases&nbsp;<em class=\"\\&quot;jv\\&quot;\">util&nbsp;<\/em>o, por ejemplo, el cliente de networking, que pueden estar implementados siguiendo el patr\u00f3n de dise\u00f1o&nbsp;<em class=\"\\&quot;jv\\&quot;\">Singleton<\/em>. Kotlin ha facilitado la implementaci\u00f3n de este patr\u00f3n, permiti\u00e9ndonos definir una \u00fanica instancia de cierta clase.<\/p>\n<p id=\"\\&quot;35ea\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Supongamos que queremos migrar una clase como la siguiente:<\/p>\n<pre class=\"\\&quot;hx\" hy=\"\" hz=\"\" ia=\"\" ib=\"\" lm=\"\" ln=\"\" cj\\\"=\"\"><span id=\"\\&quot;e755\\&quot;\" class=\"\\&quot;dv\" lo=\"\" kq=\"\" fl=\"\" lp=\"\" b=\"\" gm=\"\" lq=\"\" lr=\"\" r=\"\" ls\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><strong class=\"\\&quot;lp\" jw\\\"=\"\">public class <\/strong>FechaUtil {\n\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">private static final <\/strong>FechaUtil <strong class=\"\\&quot;lp\" jw\\\"=\"\"><em class=\"\\&quot;jv\\&quot;\">instance <\/em><\/strong>= <strong class=\"\\&quot;lp\" jw\\\"=\"\">new <\/strong>FechaUtil();\n\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">private <\/strong>FechaUtil() {}\n\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">public static <\/strong>FechaUtil getInstance() {\n        <strong class=\"\\&quot;lp\" jw\\\"=\"\">return <em class=\"\\&quot;jv\\&quot;\">instance<\/em><\/strong>;\n    }\n\n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">public <\/strong>String format(Date date) {\n        <strong class=\"\\&quot;lp\" jw\\\"=\"\">return new <\/strong>SimpleDateFormat(<strong class=\"\\&quot;lp\" jw\\\"=\"\">\\\"dd\/MM\/yyyy\\\"<\/strong>).format(date);\n    }\n}<\/span><\/pre>\n<p id=\"\\&quot;a888\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Podr\u00edamos obtener una versi\u00f3n en Kotlin que quedar\u00eda de la siguiente forma:<\/p>\n<pre class=\"\\&quot;hx\" hy=\"\" hz=\"\" ia=\"\" ib=\"\" lm=\"\" ln=\"\" cj\\\"=\"\"><span id=\"\\&quot;9f3e\\&quot;\" class=\"\\&quot;dv\" lo=\"\" kq=\"\" fl=\"\" lp=\"\" b=\"\" gm=\"\" lq=\"\" lr=\"\" r=\"\" ls\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><strong class=\"\\&quot;lp\" jw\\\"=\"\">object <\/strong>FechaUtil {\n    \n    <strong class=\"\\&quot;lp\" jw\\\"=\"\">fun <\/strong>format(date: Date) = \n         SimpleDateFormat(<strong class=\"\\&quot;lp\" jw\\\"=\"\">\\\"dd\/MM\/yyyy\\\"<\/strong>).format(date)\n}<\/span><\/pre>\n<p id=\"\\&quot;4858\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><strong class=\"\\&quot;iz\" jw\\\"=\"\">A saber:<\/strong>&nbsp;Kotlin introduce el concepto de&nbsp;<code class=\"\\&quot;el\" lt=\"\" lu=\"\" lv=\"\" lp=\"\" b\\\"=\"\"><strong class=\"\\&quot;iz\" jw\\\"=\"\">object<\/strong><\/code><strong class=\"\\&quot;iz\" jw\\\"=\"\">&nbsp;<\/strong>que permite definir una \u00fanica implementaci\u00f3n de un objeto que ser\u00e1 accesible desde todo el proyecto, como una \u00fanica instancia. Es decir, siguiendo el patr\u00f3n de dise\u00f1o&nbsp;<em class=\"\\&quot;jv\\&quot;\">Singleton<\/em>.<\/p>\n<\/div>\n<\/div>\n<\/section>\n<hr class=\"\\&quot;kf\" gl=\"\" kg=\"\" kh=\"\" ki=\"\" kj=\"\" iq=\"\" kk=\"\" kl=\"\" km=\"\" kn=\"\" ko\\\"=\"\">\n<section class=\"\\&quot;fd\" fe=\"\" ff=\"\" fg=\"\" fh\\\"=\"\">\n<div class=\"\\&quot;n\" p\\\"=\"\">\n<div class=\"\\&quot;ab\" ac=\"\" ae=\"\" af=\"\" ag=\"\" fi=\"\" ai=\"\" aj\\\"=\"\">\n<p id=\"\\&quot;f3c2\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Los anteriores ejemplos han sido algunos consejos de cambios f\u00e1ciles que podemos realizar, en l\u00edneas generales, r\u00e1pidamente como para comenzar a introducir c\u00f3digo Kotlin en nuestro proyecto. \u00a1Desde luego que hay mucho m\u00e1s por hacer!. Algunas consideraciones que puedes tener en cuenta para dar algunos pasos m\u00e1s son:<\/p>\n<ul class=\"\\&quot;\\&quot;\">\n<li id=\"\\&quot;968e\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" jx=\"\" jy=\"\" jz=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Convirtiendo nuestras actividades o fragmentos a Kotlin, podemos deshacernos de los molestos&nbsp;<code class=\"\\&quot;el\" lt=\"\" lu=\"\" lv=\"\" lp=\"\" b\\\"=\"\">findViewById()<\/code><em class=\"\\&quot;jv\\&quot;\">&nbsp;<\/em>o<em class=\"\\&quot;jv\\&quot;\">,&nbsp;<\/em>si la utilizas, de la librer\u00eda<em class=\"\\&quot;jv\\&quot;\">&nbsp;Butterknife&nbsp;<\/em>y acceder a los&nbsp;<em class=\"\\&quot;jv\\&quot;\">Views<\/em>&nbsp;de tu layout directamente por&nbsp;<code class=\"\\&quot;el\" lt=\"\" lu=\"\" lv=\"\" lp=\"\" b\\\"=\"\">id<\/code>. Ver\u00e1s que se importar\u00e1 autom\u00e1ticamente:<\/li>\n<\/ul>\n<pre class=\"\\&quot;hx\" hy=\"\" hz=\"\" ia=\"\" ib=\"\" lm=\"\" ln=\"\" cj\\\"=\"\"><span id=\"\\&quot;d0d4\\&quot;\" class=\"\\&quot;dv\" lo=\"\" kq=\"\" fl=\"\" lp=\"\" b=\"\" gm=\"\" lq=\"\" lr=\"\" r=\"\" ls\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><strong class=\"\\&quot;lp\" jw\\\"=\"\">import <\/strong>kotlinx.android.synthetic.main.actividad_login.*<\/span><\/pre>\n<ul class=\"\\&quot;\\&quot;\">\n<li id=\"\\&quot;881b\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" jx=\"\" jy=\"\" jz=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Convertir tus adapters (de&nbsp;<em class=\"\\&quot;jv\\&quot;\">RecyclerView<\/em>&nbsp;o&nbsp;<em class=\"\\&quot;jv\\&quot;\">ViewPagers<\/em>, por ejemplo) deber\u00eda resultarte relativamente sencillo, ya que usualmente en esas clases encontramos c\u00f3digo&nbsp;<em class=\"\\&quot;jv\\&quot;\">boilerplate&nbsp;<\/em>que Kotlin puede ayudarte a escribir en menos l\u00edneas.<\/li>\n<li id=\"\\&quot;0fc0\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" ka=\"\" jc=\"\" jd=\"\" je=\"\" kb=\"\" jg=\"\" jh=\"\" ji=\"\" kc=\"\" jk=\"\" jl=\"\" jm=\"\" kd=\"\" jo=\"\" jp=\"\" jq=\"\" ke=\"\" js=\"\" jt=\"\" ju=\"\" jx=\"\" jy=\"\" jz=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Haciendo uso de la librer\u00eda&nbsp;<em class=\"\\&quot;jv\\&quot;\">Android KTX<\/em>&nbsp;(<em class=\"\\&quot;jv\\&quot;\">Kotlin extensions<\/em>) puedes lograr mejoras en la claridad de tu c\u00f3digo. Por ejemplo, veamos c\u00f3mo podemos cambiar la visibilidad de un View desde Java:<\/li>\n<\/ul>\n<pre class=\"\\&quot;hx\" hy=\"\" hz=\"\" ia=\"\" ib=\"\" lm=\"\" ln=\"\" cj\\\"=\"\"><span id=\"\\&quot;16f9\\&quot;\" class=\"\\&quot;dv\" lo=\"\" kq=\"\" fl=\"\" lp=\"\" b=\"\" gm=\"\" lq=\"\" lr=\"\" r=\"\" ls\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">opcion1.setVisibility(View.<strong class=\"\\&quot;lp\" jw\\\"=\"\"><em class=\"\\&quot;jv\\&quot;\">VISIBLE<\/em><\/strong>)<\/span><\/pre>\n<p id=\"\\&quot;1997\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">y c\u00f3mo podemos reducir la expresi\u00f3n gracias a KTX:<\/p>\n<pre class=\"\\&quot;hx\" hy=\"\" hz=\"\" ia=\"\" ib=\"\" lm=\"\" ln=\"\" cj\\\"=\"\"><span id=\"\\&quot;d2c9\\&quot;\" class=\"\\&quot;dv\" lo=\"\" kq=\"\" fl=\"\" lp=\"\" b=\"\" gm=\"\" lq=\"\" lr=\"\" r=\"\" ls\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">opcion1.isVisible = <strong class=\"\\&quot;lp\" jw\\\"=\"\">true<\/strong><\/span><\/pre>\n<p id=\"\\&quot;49f2\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" jb=\"\" jc=\"\" jd=\"\" je=\"\" jf=\"\" jg=\"\" jh=\"\" ji=\"\" jj=\"\" jk=\"\" jl=\"\" jm=\"\" jn=\"\" jo=\"\" jp=\"\" jq=\"\" jr=\"\" js=\"\" jt=\"\" ju=\"\" fd=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\">Espero que estos consejos te hayan servido como motivaci\u00f3n para iniciar la migraci\u00f3n de tu proyecto. \u00a1Realmente vale la pena!<\/p>\n<\/div>\n<\/div>\n<\/section>\n<hr class=\"\\&quot;kf\" gl=\"\" kg=\"\" kh=\"\" ki=\"\" kj=\"\" iq=\"\" kk=\"\" kl=\"\" km=\"\" kn=\"\" ko\\\"=\"\">\n<section class=\"\\&quot;fd\" fe=\"\" ff=\"\" fg=\"\" fh\\\"=\"\">\n<div class=\"\\&quot;n\" p\\\"=\"\">\n<div class=\"\\&quot;ab\" ac=\"\" ae=\"\" af=\"\" ag=\"\" fi=\"\" ai=\"\" aj\\\"=\"\">\n<h1 id=\"\\&quot;4dc7\\&quot;\" class=\"\\&quot;kp\" kq=\"\" fl=\"\" au=\"\" av=\"\" kr=\"\" ks=\"\" kt=\"\" ku=\"\" kv=\"\" kw=\"\" kx=\"\" ky=\"\" kz=\"\" la=\"\" lb=\"\" lc=\"\" ld=\"\" le=\"\" lf=\"\" lg=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><span style=\"\\&quot;font-family:\" helvetica,=\"\" arial,=\"\" sans-serif;\\\"=\"\">Enlaces de inter\u00e9s<\/span><\/h1>\n<ul class=\"\\&quot;\\&quot;\">\n<li id=\"\\&quot;0ab1\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" lh=\"\" jc=\"\" jd=\"\" je=\"\" li=\"\" jg=\"\" jh=\"\" ji=\"\" lj=\"\" jk=\"\" jl=\"\" jm=\"\" lk=\"\" jo=\"\" jp=\"\" jq=\"\" ll=\"\" js=\"\" jt=\"\" ju=\"\" jx=\"\" jy=\"\" jz=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><span style=\"\\&quot;font-family:\" helvetica,=\"\" arial,=\"\" sans-serif;\\\"=\"\"><a class=\"\\&quot;dz\" hj=\"\" it=\"\" iu=\"\" iv=\"\" iw\\\"=\"\" href=\"\/es\/\\&quot;https:\/\/kotlinlang.org\/docs\/reference\/data-classes.html\\&quot;\/\" target=\"\\&quot;_blank\\&quot;\" rel=\"\\&quot;noopener\" nofollow=\"\" noreferrer\\\"=\"\">Documentaci\u00f3n oficial: Kotlin Data Class<\/a><\/span><\/li>\n<li id=\"\\&quot;18de\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" ka=\"\" jc=\"\" jd=\"\" je=\"\" kb=\"\" jg=\"\" jh=\"\" ji=\"\" kc=\"\" jk=\"\" jl=\"\" jm=\"\" kd=\"\" jo=\"\" jp=\"\" jq=\"\" ke=\"\" js=\"\" jt=\"\" ju=\"\" jx=\"\" jy=\"\" jz=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><span style=\"\\&quot;font-family:\" helvetica,=\"\" arial,=\"\" sans-serif;\\\"=\"\"><a class=\"\\&quot;dz\" hj=\"\" it=\"\" iu=\"\" iv=\"\" iw\\\"=\"\" href=\"\/es\/\\&quot;https:\/\/kotlinlang.org\/docs\/reference\/interfaces.html\\&quot;\/\" target=\"\\&quot;_blank\\&quot;\" rel=\"\\&quot;noopener\" nofollow=\"\" noreferrer\\\"=\"\">Documentaci\u00f3n oficial: Kotlin interfaces<\/a><\/span><\/li>\n<li id=\"\\&quot;442e\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" ka=\"\" jc=\"\" jd=\"\" je=\"\" kb=\"\" jg=\"\" jh=\"\" ji=\"\" kc=\"\" jk=\"\" jl=\"\" jm=\"\" kd=\"\" jo=\"\" jp=\"\" jq=\"\" ke=\"\" js=\"\" jt=\"\" ju=\"\" jx=\"\" jy=\"\" jz=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><span style=\"\\&quot;font-family:\" helvetica,=\"\" arial,=\"\" sans-serif;\\\"=\"\"><a class=\"\\&quot;dz\" hj=\"\" it=\"\" iu=\"\" iv=\"\" iw\\\"=\"\" href=\"\/es\/\\&quot;https:\/\/kotlinlang.org\/docs\/reference\/object-declarations.html\\&quot;\/\" target=\"\\&quot;_blank\\&quot;\" rel=\"\\&quot;noopener\" nofollow=\"\" noreferrer\\\"=\"\">Documentaci\u00f3n oficial: Kotlin objects<\/a><\/span><\/li>\n<li id=\"\\&quot;e5da\\&quot;\" class=\"\\&quot;ix\" iy=\"\" fl=\"\" iz=\"\" b=\"\" ja=\"\" ka=\"\" jc=\"\" jd=\"\" je=\"\" kb=\"\" jg=\"\" jh=\"\" ji=\"\" kc=\"\" jk=\"\" jl=\"\" jm=\"\" kd=\"\" jo=\"\" jp=\"\" jq=\"\" ke=\"\" js=\"\" jt=\"\" ju=\"\" jx=\"\" jy=\"\" jz=\"\" dv\\\"=\"\" data-selectable-paragraph=\"\\&quot;\\&quot;\"><span style=\"\\&quot;font-family:\" helvetica,=\"\" arial,=\"\" sans-serif;\\\"=\"\"><a class=\"\\&quot;dz\" hj=\"\" it=\"\" iu=\"\" iv=\"\" iw\\\"=\"\" href=\"\/es\/\\&quot;https:\/\/developer.android.com\/kotlin\/ktx\\&quot;\/\" target=\"\\&quot;_blank\\&quot;\" rel=\"\\&quot;noopener\" nofollow=\"\" noreferrer\\\"=\"\">Android KTX: Kotlin Extensions<\/a> <\/span><\/li>\n<\/ul>\n<hr>\n<p><span style=\"\\&quot;font-family:\" georgia,=\"\" palatino,=\"\" serif;=\"\" font-size:=\"\" 12pt;\\\"=\"\"><strong>Sobre la autora:<\/strong> <i><span style=\"\\&quot;font-weight:\" 400;\\\"=\"\">Mi nombre es Maribel Maisano. Soy Ingeniera en Computaci\u00f3n y me especializo en el desarrollo de aplicaciones Android. Soy co-organizadora y WTM Ambassador en GDG&amp;WTM Buenos Aires. <\/span><\/i><\/span><\/p>\n<p><span style=\"\\&quot;font-family:\" georgia,=\"\" palatino,=\"\" serif;=\"\" font-size:=\"\" 12pt;\\\"=\"\"><i><span style=\"\\&quot;font-weight:\" 400;\\\"=\"\">Linkedin: <\/span><\/i><a href=\"\/es\/\\&quot;https:\/\/www.linkedin.com\/in\/maribelmai\/\\&quot;\/\"><i><span style=\"\\&quot;font-weight:\" 400;\\\"=\"\">https:\/\/www.linkedin.com\/in\/maribelmai\/<\/span><\/i><\/a><i> <\/i><\/span><\/p>\n<p><span style=\"\\&quot;font-family:\" georgia,=\"\" palatino,=\"\" serif;=\"\" font-size:=\"\" 12pt;\\\"=\"\"><i><span style=\"\\&quot;font-weight:\" 400;\\\"=\"\">Twitter: https:\/\/twitter.com\/maribelmai<\/span><\/i><\/span><\/p>\n<\/div>\n<\/div>\n<\/section>","protected":false},"excerpt":{"rendered":"<p>Ya es de p\u00fablico conocimiento que Kotlin es el lenguaje de programaci\u00f3n est\u00e1ndar para desarrollar en Android. Es totalmente retrocompatible con Java, fue reconocido por Google durante el evento Google I\/O 2017 y hoy en d\u00eda se presentan librer\u00edas en modo Kotlin first,&nbsp;es decir, permitiendo aprovechar las ventajas de este lenguaje. \u00bfPor d\u00f3nde empiezo? Kotlin [&hellip;]<\/p>\n","protected":false},"author":6,"featured_media":7661,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"_joinchat":[],"footnotes":""},"categories":[63],"tags":[],"class_list":["post-5201","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-call-for-papers"],"_links":{"self":[{"href":"https:\/\/conexion-hr.com\/es\/wp-json\/wp\/v2\/posts\/5201","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/conexion-hr.com\/es\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/conexion-hr.com\/es\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/conexion-hr.com\/es\/wp-json\/wp\/v2\/users\/6"}],"replies":[{"embeddable":true,"href":"https:\/\/conexion-hr.com\/es\/wp-json\/wp\/v2\/comments?post=5201"}],"version-history":[{"count":0,"href":"https:\/\/conexion-hr.com\/es\/wp-json\/wp\/v2\/posts\/5201\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/conexion-hr.com\/es\/wp-json\/wp\/v2\/media\/7661"}],"wp:attachment":[{"href":"https:\/\/conexion-hr.com\/es\/wp-json\/wp\/v2\/media?parent=5201"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/conexion-hr.com\/es\/wp-json\/wp\/v2\/categories?post=5201"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/conexion-hr.com\/es\/wp-json\/wp\/v2\/tags?post=5201"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}