This file contains 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
{ | |
"infoTributaria": { | |
"ambiente": 1, | |
"tipoEmision": 1, | |
"razonSocial": "PRUEBAS SERVICIO DE RENTAS INTERNAS", | |
"nombreComercial": "PRUEBAS SERVICIO DE RENTAS INTERNAS", | |
"ruc": "0000000000001", | |
"codDoc": "01", | |
"estab": "001", | |
"ptoEmi": "001", |
This file contains 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
ffmpeg -i a.eac3 a1.ac3 |
This file contains 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
private static int mod11(){ | |
String key = "41261533"; | |
int sum = 0, factor = 2, dv, keyL = key.length(); | |
for (int i = 0; i < keyL; i++) { | |
sum+=(key.charAt((keyL-1)-i) - '0') * factor; | |
factor = factor == 7 ? 2 : factor+1; | |
} | |
dv = 11 - (sum % 11); | |
if (dv < 10) | |
return dv; |
This file contains 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 static String encryptText(String text) | |
{ | |
AES256TextEncryptor aesEncryptor = new AES256TextEncryptor(); | |
aesEncryptor.setPassword(LabelUtils.MASTER_PASSWORD); | |
return aesEncryptor.encrypt(text); | |
} | |
public static String decrptText(String textEncrypted) | |
{ | |
try { | |
AES256TextEncryptor aesEncryptor = new AES256TextEncryptor(); |
This file contains 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 FirebaseRepository implements Serializable { | |
private static Firestore db; | |
private static synchronized void buildConnection() throws IOException { | |
ClassPathResource resJson = new ClassPathResource("META-INF/file.json"); | |
GoogleCredentials credentials = GoogleCredentials.fromStream(resJson.getInputStream()); | |
FirebaseOptions options = FirebaseOptions.builder() | |
.setCredentials(credentials) | |
.build(); | |
FirebaseApp.initializeApp(options); |
This file contains 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
private double xOffset = 0; | |
private double yOffset = 0; | |
@Override | |
public void start(Stage primaryStage) throws Exception{ | |
Parent root = FXMLLoader.load(getClass().getResource("ui/dashboard.fxml")); | |
root.getStylesheets().add(getClass().getResource("styles.css").toString()); | |
primaryStage.setTitle(LabelUtils.APP_NAME); | |
primaryStage.setScene(new Scene(root)); | |
primaryStage.setResizable(false); |