This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func tableView(tableView: UITableView, heightForRowAtIndexPath indexPath: NSIndexPath) -> CGFloat { | |
bool hasImage = false; | |
for item in self.object.fields { | |
if String(item.type) == Constants.IMAGE { | |
hasImage = true | |
} | |
} | |
switch indexPath.section{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let name = "CualquierContenido|123" | |
let symbol = name.characters.index(of: "|")! | |
let afterSymbol = name.characters.index(after: symbol) | |
let value = String(name.characters.suffix(from: afterSymbol)) | |
print(value) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// ViewController.swift | |
// AlamofireImageSample | |
// | |
// Created by Daniel Alvarez on 11/15/16. | |
// Copyright © 2016 Daniel Alvarez. All rights reserved. | |
// https://github.com/Alamofire/AlamofireImage | |
// |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package tech.alvarez.ejemplowebview; | |
import android.net.Uri; | |
import android.support.customtabs.CustomTabsIntent; | |
import android.support.v4.content.ContextCompat; | |
import android.support.v7.app.AppCompatActivity; | |
import android.os.Bundle; | |
import android.view.View; | |
import android.webkit.WebView; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package tech.alvarez.ejemplopickers; | |
import android.app.DatePickerDialog; | |
import android.app.Dialog; | |
import android.app.TimePickerDialog; | |
import android.content.DialogInterface; | |
import android.support.annotation.NonNull; | |
import android.support.v4.app.DialogFragment; | |
import android.support.v7.app.AlertDialog; | |
import android.support.v7.app.AppCompatActivity; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package tech.alvarez.ejemplopickers; | |
import android.app.DatePickerDialog; | |
import android.app.Dialog; | |
import android.app.TimePickerDialog; | |
import android.support.annotation.NonNull; | |
import android.support.v4.app.DialogFragment; | |
import android.support.v7.app.AppCompatActivity; | |
import android.os.Bundle; | |
import android.text.format.DateFormat; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import android.os.Bundle; | |
import android.support.v7.app.AppCompatActivity; | |
import com.google.firebase.database.DataSnapshot; | |
import com.google.firebase.database.DatabaseError; | |
import com.google.firebase.database.DatabaseReference; | |
import com.google.firebase.database.FirebaseDatabase; | |
import com.google.firebase.database.ValueEventListener; | |
import java.util.List; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package tech.alvarez.listapersonas.activities; | |
import android.os.Bundle; | |
import android.support.v7.app.AppCompatActivity; | |
import android.support.v7.widget.LinearLayoutManager; | |
import android.support.v7.widget.RecyclerView; | |
import android.widget.Toast; | |
import tech.alvarez.listapersonas.R; | |
import tech.alvarez.listapersonas.adapters.OnItemClickListener; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package tech.alvarez; | |
import java.util.ArrayList; | |
public class EjemploArrayList { | |
public static void main(String[] args) { | |
ArrayList<Estudiante> l = new ArrayList<Estudiante>(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package tech.alvarez.formulario; | |
import android.os.Bundle; | |
import android.support.design.widget.TextInputLayout; | |
import android.support.v7.app.AppCompatActivity; | |
import android.util.Patterns; | |
import android.view.View; | |
import android.widget.EditText; | |
import android.widget.RadioButton; | |
import android.widget.Toast; |