Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

import external Processing library - Reference Error #17

Open
loraxman opened this issue Jun 23, 2022 · 3 comments
Open

import external Processing library - Reference Error #17

loraxman opened this issue Jun 23, 2022 · 3 comments

Comments

@loraxman
Copy link

External libraries import but get ReferenceError: GetRequest is not defined when trying to instantiate an object.

See below for example:

import http.requests.*;
GetRequest get = new GetRequest("http://httprocessing.heroku.com");
get.send();
println("Reponse Content: " + get.getContent());
println("Reponse Content-Length Header: " + get.getHeader("Content-Length"));

PostRequest post = new PostRequest("http://httprocessing.heroku.com");
post.addData("name", "Rune");
post.send();
println("Reponse Content: " + post.getContent());
println("Reponse Content-Length Header: " + post.getHeader("Content-Length")

@loraxman
Copy link
Author

This seems to be caused by "processing-java" not knowing where libraries come from. Appears related to processing-java and external libraries

@loraxman
Copy link
Author

After digging in further into this repo, am I right to conclude that Calysto can ONLY run what is in the core for Processing JS?
In other words, it can't import the java base libraries for Processing since it is really only the Javascript core of Processing?

@dsblank
Copy link
Member

dsblank commented Jun 29, 2022

That is correct... this is only a wrapper around the JavaScript part.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants