Skip to content

Instantly share code, notes, and snippets.

View HtetWaiYanLin's full-sized avatar
💭
Learning

Htet Wai Yan Lin HtetWaiYanLin

💭
Learning
  • Yangon, Myanmar
View GitHub Profile
@HtetWaiYanLin
HtetWaiYanLin / flutter.md
Created October 18, 2019 06:42 — forked from matteocrippa/flutter.md
Flutter Cheatsheet

Flutter

A quick cheatsheet of useful snippet for Flutter

Widget

A widget is the basic type of controller in Flutter Material. There are two type of basic Widget we can extend our classes: StatefulWidget or StatelessWidget.

Stateful

StatefulWidget are all the widget that interally have a dynamic value that can change during usage. It can receive an input value in the constructor or reference to functions. You need to create two classes like:

@HtetWaiYanLin
HtetWaiYanLin / ChangePassword.java
Created March 25, 2020 18:32 — forked from zach-klippenstein/ChangePassword.java
The keystore password on Java keystore files is utterly pointless. You can reset it without knowing it, as shown by this code. Note that private keys are still secure, as far as I know. The JKS implementation is copyright Casey Marshall (rsdio@metastatic.org), and the original source is available at http://metastatic.org/source/JKS.java. I've in…
import java.util.*;
import java.io.*;
import java.security.*;
public class ChangePassword
{
private final static JKS j = new JKS();
public static void main(String[] args) throws Exception
{
@HtetWaiYanLin
HtetWaiYanLin / HomePage.dart
Created December 2, 2020 12:32 — forked from carzacc/HomePage.dart
Flutter app for JWT tutorial
class HomePage extends StatelessWidget {
HomePage(this.jwt, this.payload);
factory HomePage.fromBase64(String jwt) =>
HomePage(
jwt,
json.decode(
ascii.decode(
base64.decode(base64.normalize(jwt.split(".")[1]))
)
@HtetWaiYanLin
HtetWaiYanLin / ConverterDateAndJavaTime.java
Created January 20, 2021 11:33 — forked from ammmze/ConverterDateAndJavaTime.java
opencsv HeaderColumnNameAndOrderMappingStrategy
package com.example.csv;
import com.opencsv.bean.ConverterDate;
import com.opencsv.exceptions.CsvDataTypeMismatchException;
import java.lang.reflect.InvocationTargetException;
import java.time.LocalDate;
import java.time.LocalTime;
import java.time.format.DateTimeFormatter;
import java.time.temporal.Temporal;
import java.util.Locale;