Я совершенно отчаянно пытаюсь это сделать.Я начал новую работу, где мне дали приложение, созданное в Processing, и теперь мне нужно, чтобы оно вызывало простой index.html (https://west -4f2bc.firebaseapp.com ), но не открывал его в браузере..
Есть ли что-нибудь сделать?позже я собираюсь передать параметры добавления данных в URL, но теперь мне просто нужно вызвать их как есть, без открытия окна.
Пожалуйста, помогите мне ..... Я перепробовал много вариантов этогокод
import processing.net.*;
Client myClient;
void setup() {
// Connect to the local machine at port 10002.
// This example will not run if you haven't
// previously started a server on this port.
myClient = new Client(this, "west-4f2bc.firebaseapp.com", 80);
// Say hello
myClient.write("GET /\r\n");
}
void draw() {
}
Спасибо.
С этим я только получаю правду, поэтому он соединяется, но я получаю только 0.
import processing.net.*;
Client myClient;
int dataIn;
void setup() {
size(200, 200);
// Connect to the local machine at port 5204.
// This example will not run if you haven't
// previously started a server on this port.
myClient = new Client(this, "west-4f2bc.firebaseapp.com", 80);
println(myClient.active());
println(dataIn);
}
void draw() {
}
с этим я подключаюсь, но послеКлиент SocketException: Сокет закрыт
import processing.net.*;
Client myClient;
int dataIn;
void setup() {
Client client;
client = new Client(this, "west-4f2bc.firebaseapp.com", 80);
if (client.active()==true) {
println("connected");
// Make a HTTP request:
client.write("GET /call.html?id=ola&nome=artur\r\n");
client.write("\r\n");
client.stop();
} else {
// if you didn't get a connection to the server:
println("connection failed");
}
}