Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I am designing a JavaSE application that uses the webcam as an IP Cam.
This application has 2 modes
i. Live video stream
ii. Motion Detection Image Capture (When motion is detected it captures a frame and stores it)
I implemented this using JavaCV libraries.
How can I build a web interface to remotely switch between these two modes. And display the Video or Image on the web page.
Also how can I stream the live video to the webpage.
I plan on using PHP.
Any help would be appreciated. I wouldnt mind any links or tutorials.
You have 2 opinions
First you run the Webserver inside the Java Application (this causes no php)
Pros:
User Friendly
Simple if you use an embedded Servlet Container or similar like the Velocity processor
Cons:
Not easy to access from outside the network
Second you run a webserver somewhere in the internet and the Java Application Streams the Video to the Server
Pros:
Easy to access from the outside
PHP available
Cons:
You need to implement to things
For the streaming part, I have no good idea at the moment - maybe try something like vlcj.
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
Improve this question
We are well on our way to Dockerizing Domino. In fact, we have a Domino Docker running in IBM Cloud (bluemix) that replicates with on prem.
What we want to be able to do is automate the standing up of a Domino server.
In our script, we are thinking of calling a custom program we can build that will use either the C API or Java API to register a new server, deploy a XPages (JSF) application to it, and start the server, replicate over the common user directory (names.nsf) from the master server.
Currently, we started the Domino Container in CentOS in listener mode. We registered the server on prem, and copied over a bunch of files (server.id is one of them) and edited confirmation to manually configure it. We want to automate this process.
Any insights on how this can be better accomplished? any api references you can share to get us most of the way there?
Yes, this is possible. We have done this in Lotusscript using LS2CAPI.
As we are accesing API functions, this is also possible using Java. Not sure, if domino-jna already includes the needed Api calls, but this can be implemented. Take a look at github for Karsten Lehmann and domino-jna.
domino-jna can be used from XPages as well.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I need to write a utility program in JAVA that lets the user upload a file(spreadsheet etc.) and display it on the UI and later do some interaction on it and creates a template(flat file) out of it. It's more like mapping one format to another. Should I make a web-app or desktop app(standalone/thick client) for this scenario? What criteria let you decide between the two? I am new to desktop apps, so I am more leaning towards a very simple webapp deployed in tomcat. But I am willing to get my feet wets if it worth the effort to make a thick client instead.
Any tips?
I would decide based on 'who you want to be able to access it'. Also consider things like 'hosting costs' (there are free-tiers but someone can still upload to your endpoint unless you plan on securing it) and if its a webapp then the file will need to be uploaded to the server first before it can be read. (These are extra steps that wouldn't be required by a thick client (desktop) application which could just read directly from the local drive). If this is for a particular person then I think a thick client (desktop) application would be best suited just to avoid the extra hassle of uploading files, securing the web app (from people uploading to your endpoint), hosting fees, bandwidth costs etc. It seems like it would be the best option to write it with a thick client (desktop) application first as less steps are required and you can focus on writing just the load, mapping and display code.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I am not a Java pro. I need to enable my completed java applications to ONLINE-Versions. Kindly give me the simplest way.
I have tried to go the JSP and Servlet way, but seems exceedingly tiresome,there surely ought to be a direct way.
When you use a typical web application what do you think is happening? You're in a browser and it's displaying some pages. You click around and some server does some work, for example Amazon shows you a list of books you could buy, the server is passing data to the browser for it to display.
That's a big difference from your current Java Application where everything is happening in the same computer.
This split between the UI part of the application, in the Browser, and the server part that's doing the real business is one reason why Web programming is so different from simple Java programming.
Servlets and JSPs are the traditional Java way of doing things, but modern web apps make much greater use of JavaScript for all the UI and all the Java (or any other server technology) does is provide the data displayed by JavaScript.
Bottom line: Sorry, but there is a whole lot more to learn. My recommendation would be to grit your teeth and forget about what you've done so far and start studying JavaScript and HTML.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
Hiii
I already have a desktop application using swings and jframes,i have to create a web application of it,wherein the gui will be of jsp,what can be the most convenient approach to do this,so that i could use my already generated code(linked classes,their objects and functions) in my new project...Thanks in advance
You can not use this directly.
you will have to create new gui for that,
you can use jsp HTML java code but not j frame in web application.
It is not possible to reuse it the way you described. You will either have to rewrite GUI, or backend, or everything if decoupling one from the other is not possible.
If I desperately needed to reuse the GUI I would have introduced a network (via an RPC, say JAX-WS) in the least contended place (draw class collaboration diagram and partition it in two halves such that GUI is on the left, backend is on the right and the number of lines crossing the cut is minimal (aka Min Cut). The thin GUI can be exposed to the client via Java Web Start.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
Can you program external application from Java app.?
I know this is a wierd question but lately I really need to do it.
So the lets say I have "VLC" player or MPC or whatever it is, I want to be able to create a Java/C++ application or whatever it is to control the application such as play the video, pause the video and stuff.
If it possible please let me know and how.
It's certainly possible with VLC. Look here: http://wiki.videolan.org/Java_bindings as well as here: how to control VLC by java
For MPC, I don't know of any resources that can be used to do so. You can at least launch it to the best of my knowledge.
To start (execute) an external application you should use Runtime.getRuntime().exec(params);
or ProcessBuilder class.
http://docs.oracle.com/javase/7/docs/api/java/lang/ProcessBuilder.html
See Execute external program in java for more information.
To send key strokes to another application you could use the "Robot" class (http://docs.oracle.com/javase/6/docs/api/java/awt/Robot.html).
What is expected is to have access to interface to do these operations, you can get some references from http://caprica.github.io/vlcj/
This is java api for controlling the VLC instance embedded in AWT.
I have found this site that describes how to run external programms from java
http://www.rgagnon.com/javadetails/java-0014.html