0

Is there an equivalent of command line PHP for Java servlets?

3
  • 2
    Not directly. What's the functional requirement then? Unit testing? Commented Jan 10, 2012 at 17:28
  • In Java, there is usually another way to do whatever you need to run this way. i.e. it supports it but you don't want to go there. Commented Jan 10, 2012 at 17:35
  • I just wanted a simple way to eyeball the HTML it generates. Commented Jun 27, 2015 at 16:57

1 Answer 1

1

Personally I would create a dedicated package for the business logic portion of your application, that way both a servlet and Java command line application can import the functionality. If you separate them well enough it will also vastly reduce maintenance etc.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.