Postagens

File Java e caminhos para arquivo

public static void main(String[] args) throws IOException { // TODO Auto-generated method stub File arquivo = new File("C:\\programa-java\\exemplo-singleton\\FileLogger.java"); System.out.println("PATH - caminho onde se encontra o arquivo: " + arquivo.getPath()); System.out.println("AbsolutePath: " + arquivo.getAbsolutePath()); System.out.println("CanonicalFile: " + arquivo.getCanonicalFile()); System.out.println("ParentFile: " + arquivo.getParentFile()); }

Executando .jar no Java

package br.com.agente; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Teste2 { public static void main(String[] args) { // TODO Auto-generated method stub try { Process processo = Runtime.getRuntime().exec("java -jar bdi-java-0.0.1-SNAPSHOT-jar-with-dependencies.jar 'cam1Exemplo'"); if(processo.isAlive()) { System.out.println("Processo esta ativo..."); } System.out.println("Result:"); BufferedReader reader = new BufferedReader(new InputStreamReader(processo.getInputStream())); String line = ""; while ((line = reader.readLine()) != null) { System.out.println(line); } } catch (IOException e) { // TODO Auto-generated catch block System.out.println(e.getMessage()); } } }

Executar .bat no Java

package br.com.agente; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; public class Teste2 { public static void main(String[] args) { // TODO Auto-generated method stub try { Process processo = Runtime.getRuntime().exec("C:\\programa-java\\PluginDemo\\executa.bat"); if(processo.isAlive()) { System.out.println("Processo esta ativo..."); } System.out.println("Result:"); BufferedReader reader = new BufferedReader(new InputStreamReader(processo.getInputStream())); String line = ""; while ((line = reader.readLine()) != null) { System.out.println(line); } } catch (IOException e) { // TODO Auto-generated catch block System.out.println(e.getMessage()); } } }

Feliz Natal e ótimo Ano Novo

Imagem
A equipe lhe deseja ótimas festas  

Como revender produtos da gearbest

https://affiliate.gearbest.com/?invitecode=LWDMKUXQ

Novo golpe via whatsapp

https://youtu.be/EyWH0rupKvI

SPAMMER - Desconfiem

Hoje recebi no endereço de um cliente o e-mail de nicralfmip@outlook.com dizendo: You will make the payment by Bitcoin (if you don't know this, search 'how to buy bitcoin' in Google). BTC address: 16e9HdesiHmC1QEoZh8PStas95S6t7k1Yw [case-SeNSiTiVe copy & paste it] if you may be curious about going to the cops, good, this email cannot be traced back to me. I have taken care of my moves. i am also not looking to charge you a lot, i only want to be paid. You now have 48 hours to pay. i've a specific pixel in this email, and right now i know that you have read this mail. if i don't receive the BitCoins, i will certainly send your video to all of your contacts including members of your family, colleagues, etc. Nevertheless, if i receive the payment, i will destroy the video immediately. it's a nonnegotiable offer thus please don't waste my time and yours by responding to this e mail. if you want to have evidence, reply Yes! then i definitely will send out you...