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
public class PaymentFactory { | |
private static final Map<PaymentType, PaymentStrategy> strategies = new EnumMap<>(PaymentType.class); | |
static { | |
strategies.put(PaymentType.CREDIT_CARD, new CreditCardPayment()); | |
strategies.put(PaymentType.DEBIT_CARD, new DebitCardPayment()); | |
strategies.put(PaymentType.CRYPTO, new CryptoPayment()); | |
} | |
public static PaymentStrategy getPaymentStrategy(PaymentType paymentType) { |
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
----------------------------------------------------------------------------------------------------------------------------- | |
PROCEDIMENTOS PARA INSTALAÇÃO SAFENET5110 | |
Autor: Alex Ishida <[email protected]> | |
Data: 13/08/2021 | |
Versão: 1.0.0.0 | |
----------------------------------------------------------------------------------------------------------------------------- | |
PASSO 1, instale alguns pacotes disponíveis no repositório oficial do Ubuntu. | |
----------------------------------------------------------------------------------------------------------------------------- | |
sudo apt update |
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 com.google.gson.*; | |
import java.lang.reflect.Type; | |
import java.text.DateFormat; | |
import java.text.ParseException; | |
import java.text.SimpleDateFormat; | |
import java.util.Date; | |
import java.util.Locale; | |
import java.util.TimeZone; |