Skip to content

Instantly share code, notes, and snippets.

📱
Coding for mobile...

Jesse Lima jesselima

📱
Coding for mobile...
Block or report user

Report or block jesselima

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View RoundedBottomSheetDialogFragment.kt
package com.your.package
import android.app.Dialog
import android.os.Bundle
import com.your.package.R
import com.google.android.material.bottomsheet.BottomSheetDialog
import com.google.android.material.bottomsheet.BottomSheetDialogFragment
/**
* BottomSheetDialog fragment that uses a custom
View BaseDao.kt
/*
* Copyright (C) 2017 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
@jesselima
jesselima / BindingConversions.java
Last active Apr 17, 2019
It's a sample with binding adapters. Still need improvements and more samples.
View BindingConversions.java
package com.udacity.popularmovies.shared;
import android.graphics.drawable.Drawable;
import android.os.Build;
import android.util.Log;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;
import androidx.annotation.Nullable;
@jesselima
jesselima / BluetoothCallback.java
Created Mar 20, 2019 — forked from joinAero/BluetoothCallback.java
Android - The bluetooth listener and profile proxy.
View BluetoothCallback.java
package cc.cubone.turbo.core.bluetooth;
/**
* Interface definition for a callback to be invoked when bluetooth state changed.
*/
public interface BluetoothCallback {
/**
* Called when the bluetooth is off.
*/
@jesselima
jesselima / MyDiffUtil.java
Created Mar 12, 2019
Check a new list has new objects before update the old list.
View MyDiffUtil.java
package com.tetraandroid.diffutilexample.helper;
import android.support.v7.util.DiffUtil;
import com.tetraandroid.diffutilexample.http.apimodel.Result;
import java.util.List;
public class MyDiffUtil extends DiffUtil.Callback {
@jesselima
jesselima / FileReaderUtil.java
Created Jan 6, 2019
Read local json file and converts it to a String.
View FileReaderUtil.java
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.net.URISyntaxException;
import java.net.URL;
import java.util.Scanner;
/* How to use it:
1 - Create a ClassLoader instance
@jesselima
jesselima / DateUtils.java
Created Dec 28, 2018
Format String to String Dates
View DateUtils.java
package br.com.bank.bankapp.shared;
/**
* Created by jesse on 12/28/18.
* This is a part of the project BankApp.
*/
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Locale;
@jesselima
jesselima / README.md
Created Dec 10, 2018 — forked from CodingDoug/README.md
Example code from the video "Use async/await with TypeScript in Cloud Functions"
View README.md

Example code from the video "Use async/await with TypeScript in Cloud Functions"

This is the example code from my video about using async/await with Cloud Functions. I've placed it here in a gist so it's easier to compare the "before" and "after" states for each case.

Watch the video here

The code in this project is licensed under the Apache License 2.0.

Copyright 2018 Google LLC
View SquawkFirebaseInstanceIdService.java
/*
* Copyright (C) 2017 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
View DateUtils.java
package com.example.myapplication.utils;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Locale;
public final class DateUtils {
You can’t perform that action at this time.